[ForYourInformation -46] Ticket raised by My Asset Widget can be configured with a particular template

[ForYourInformation -46] Ticket raised by My Asset Widget can be configured with a particular template

Introduction:

Users can raise an incident ticket for their assets through [Home page >> My Assets]. The user needs to click on the "Report an issue" button to raise a ticket for the particular asset, on clicking the button user will be taken to incidents list pages. Users can select the appropriate template to submit the ticket. 


Scenario:

One of our customer requirements was to show a particular incident template (which has the pre-filled fields ) instead of listing all templates while clicking the "Report an issue" button. So that users need not get baffled on choosing the appropriate template from the list. 

Solution:

The following script was provided to fulfill the requirement.


setTimeout(function(){

jQuery("#sdphome-Assets-placeholder  button").attr("onclick","location.href='/WorkOrder.do?woMode=newWO&reqTemplate=52'"); 

},1000);


Note:
The particular template URL had to be updated on the above-given script.
Login ServiceDesk Plus as a user, open the particular template and copy the URL and replace it on the highlighted part of the script


setTimeout(function(){

jQuery("#sdphome-Assets-placeholder  button").attr("onclick","location.href='/WorkOrder.do?woMode=newWO&reqTemplate=901'"); 

},1000); 


Steps to follow:

1. Configure the script using Page Script [Admin tab >> Page Scripts]



2. Select Event as All, select Applies to All Users.


Points to Remember:

1. Make sure the particular template is enabled for all users.



I hope this article was helpful! 

Our previous article was on - Canceling a request

              New to ADManager Plus?

                New to ADSelfService Plus?