Skip to main content
Closed for Voting

Ability to customize Ticket Properties

Related products:Freshdesk
  • June 15, 2016
  • 4 replies
  • 31 views

In the current state, the Ticket Properties fields are auto-created from ticket fields. It would be great if we could choose which of those fields are shown in particular Group's tickets (or at least be able to rearrange so that most commonly used/important fields are moved to the top).


Thanks!

4 replies

You can create a custom app for that. Example:
<script>
  jQuery(document).on('ticket_view_loaded', function() {
    var group_customization = function() {
      var ticket_group_id = jQuery('#helpdesk_ticket_group_id').val();
      var group_description = '';
      // Show the 'Source' and 'Type' fields of the 'Ticket properties' section of the right sidebar:
      jQuery('.dropdown.default_source.field').show();
      jQuery('.dropdown_blank.default_ticket_type.field').show();
      if (ticket_group_id) {
        group_description = 'Group: ID is [' + ticket_group_id + ']';
      } else {
        group_description = 'Group: None';
      }
      switch (ticket_group_id) {
        case '14000060314':
          group_description = 'Group: QA';
          // Hide the 'Source' field of the 'Ticket properties' section of the right sidebar:
          jQuery('.dropdown.default_source.field').hide();
          break;
        case '14000060315':
          group_description = 'Group: Sales';
          // Hide the 'Type' field of the 'Ticket properties' section of the right sidebar:
          jQuery('.dropdown_blank.default_ticket_type.field').hide();
          break;
      }
      console.log(group_description);
    };
    jQuery(document).on('sidebar_loaded', group_customization);
    jQuery(document).on('change', '#helpdesk_ticket_group_id', group_customization);
  });
</script>

 

 


  • Community Debut
  • October 20, 2016

@thanos what will this do exactly?


Dear Philip,

the comments explain most of the functionality.

- You start by making sure that the fields you wish to manipulate ( 'Source' and 'Type' in this case ) start at a "show" state.
- Then you check what the group ID is for the group that the ticket is assigned to ( if it is assigned to a group, obviously ).
- Depending on the group ID, you hide some field(s)

The console.log statement is there to help you figure out what the group IDs for your groups are and it should be commented out once you are done.

Unfortunately, this is far from a plug-and-play thing as you have to discover what the group IDs of your groups are, what the element handles are and modify it to suit your needs.

 


aravind.sundararajan
Skilled Expert
Forum|alt.badge.img+12

Hello,


Dynamic forms allow you to customise the ticket form and display relevant fields based on the user's input. This can be built upon the default type field or any custom dropdown field. 


Cheers!