Record Producer change Priority

juliochacon23
Tera Expert

How I would like to setup a record producer to allow a user to change the priority based on their response to a question.

I created a variable in the Record Producer with Question: How urgent is your issue.   The variable is mapped to a filed in the incident table called "How Urgent"   This contains the below choices
Affecting only me

Affecting only my department

Affecting all users.

The idea is when a user selects one of the choices above the priority on the incident is changed based on their response.

I crated an assignment rule that has the response in the condition.   I think I need to put a script in the assignment rule to make this work.   Any help?screen1.PNG

Thanks

1 ACCEPTED SOLUTION

Hi Julio,



Initially my impression was that you have just created a variable on record producer and not doing any mapping on incident field.


With screenshots provided, I see that you have also created field on incident table.



Now if that is the case, you can either decide urgency or impact based on the choices since priority is driven by combination of both.



If you would have not used this mapping techniquie, then we might have done something like below in record producer script section



if(producer.'your variable name'.getDisplayValue() == 'Affecting all users')


{


    current.impact = 1;


    current.urgency = 1;


}


else if(producer.'your variable name'.getDisplayValue() == 'Affecting only me)


{



    current.impact = 1;


    current.urgency = 3;


}


View solution in original post

9 REPLIES 9

Forgot to add the choices from the How urgent field in the incident table.screenshot5.JPG


Hi Julio,



Initially my impression was that you have just created a variable on record producer and not doing any mapping on incident field.


With screenshots provided, I see that you have also created field on incident table.



Now if that is the case, you can either decide urgency or impact based on the choices since priority is driven by combination of both.



If you would have not used this mapping techniquie, then we might have done something like below in record producer script section



if(producer.'your variable name'.getDisplayValue() == 'Affecting all users')


{


    current.impact = 1;


    current.urgency = 1;


}


else if(producer.'your variable name'.getDisplayValue() == 'Affecting only me)


{



    current.impact = 1;


    current.urgency = 3;


}


Hi @Deepak Ingale1 ,
in HRSD there is record producer form and in that I have set one urgency field to user select the priority and mapped that field to priority field in HR cases table but after selecting priority as HIGH and submit the form then it always set priority as LOW in HR case that agent receive 
I have checed the template there is nothing about it and BR, client script 
then why it is always setting as LOW priority

Hi Julio,



If I understand your question correctly then you want to set the priority of the field based on the response to a question from record producer. If yes, then the priority is decided based on the impact and urgency field and you cannot set away directly.


Instead you have to set the impact and urgency and then priority will be auto populated.



Please let me know if you have any questions.


Gurpreet07
Mega Sage

If the priority is completely dependent on 'How urgent' field , then why don't you just rename the field to priority (You could keep the label 'How Urgent') and then fill the choice values in accordance with priority list .. Like


      Choice Label                                                                                                     Value


Affecting only me                                                                                                       3  


Affecting only my department                                                                 2


Affecting all users.                                                                                                       1