flow designer if else condition help

RudhraKAM
Tera Guru

Can someone help me how to achieve this, we have a user-defined table in which we have a field called state when that record is created we have a trigger on that table which should create an incident, when creating incident we need to set the state to whatever the record on the user-defined table. The user-defined state value and name are different , how to achieve this ?

 

if u_usertable_state = assigned then  create the incident in assigned state ( can we write any script for this ) 

find_real_file.png

1 ACCEPTED SOLUTION

Here you go..
 
var ans;
var stat = fd_data.trigger.current.u_usertable_state;
if(stat == '1')
{
ans = '2';
}
else if(stat == '2')
{
ans = '3';
}
return ans;

View solution in original post

7 REPLIES 7

Can you share the screenshot of the flow and error message?

sorry my bad , missed something and above code is working correctly 

Thanks for the update Rudhra.