Put name in outbound Email from ServiceCat form

johnrob18
Giga Guru

I have a servicecatalog form that captures a name by picking from sys.user.

 

I need to put that name into a task Email.

 

I have these steps in my flow - when the Email is produced from the second step, the name come out in long code

johnrob18_0-1723041830050.png

johnrob18_1-1723042010768.png

 

 

 

6 REPLIES 6

Alp Utku
Mega Sage

If you are familiar with flow designer scripting, you could use below script on task description field. You basically need to use getDisplayValue() method to get display value of the name shown instead of sys_id

 

 

var name = fd_data.trigger.request_item.variables.<variable_name_of_the_name_field>.getDisplayValue();

var reg = fd_data.trigger.request_item.variables.<variable_name_of_the_name_field>;

// repeat this as long as you need for other variables to be shown on task description field

return name + \n + region; 

// use "+" add more variable information on description and "/n" for having new line on description field

 

Thanks, so where would the script be put?

johnrob18_0-1723053204828.png

 

 

Please click on </> button which opens up script editor

Hi - i have added the code to the script editor

johnrob18_0-1723100078164.png

do i need to change the decsription code already in place?

johnrob18_1-1723100188659.png