3. Set the state to "Awaiting Change" when a Change is created from the incident using the existing "Create Normal Change" and "Create Emergency Change" UI actions.

anilkumar8
Tera Contributor

3. Set the state to "Awaiting Change" when a Change is created from the incident using the existing "Create Normal Change" and "Create Emergency Change" UI actions.

16 REPLIES 16

JC Presley
Tera Contributor

use the value not the lable "Awaiting Change"

 

changeRequest.setValue("state", value );

 

 

value is whatever value you gave that state = Awaiting Change when you set it up (ie. 1, 3, 5, ect.) you can look it up in Show Choice List.  If you forgot to put a value in for that state, you might want to go in there and update it to a value. 

Sam94
Tera Contributor

I had a similar issue and can confirm that what was advised in this comment worked. 

flordelyn_v_ani
Tera Contributor

Hi Anil,

You can insert the below code in the Create Normal Change and Create Emergency Change UI Action just after the line "changeRequest.insert();"

current.setValue('state',4); 
current.update();

NOTE:

You can replace the value 4 with whatever value you use for the Awaiting change state.

Hope this helps. 

Thank you!

Hi  flordelyn,

 

Thanks for sharing this worked for me..

 

Hello Flordelyn,

Thanks for sharing. It worked for me.