Dropdown autoselect

  • 20 December 2018
  • 2 replies
  • 54 views

hi guys,


i create different portals, but each portal has is own assigned pod, i need that when the user go to the Archers pod for example, the portal automatically  select the Archers pod in the dropdown.


image

 i already try different javascript and jquery codes, but i don't manage to make that the drop down select the archers value



this is the snipped of the code

$(".helpdesk_ticket_custom_field_cf_team_portal_assign_group_manually_523171 > option[value='Archers']").prop('selected',true);



thx


This topic has been closed for comments

2 replies

hi Aravind,


thank you for your help, it works :)


Userlevel 4
Badge +12

Hello,


Thanks for posting this on our community. You could add the snippet to the new ticket page layout of the specific portal. Please try using the one specified below instead of your existing code:


jQuery("#helpdesk_ticket_custom_field_cf_team_portal_assign_group_manually_523171").val("Archers");



Cheers!