How do you add a custom variable to the watch list

Connie5
Kilo Contributor

I have created a custom variable on a catalog item called "Contact Name" and I would like to add this contact name variable to the watch list so that the person (referenced from the sys_user table) is notified throughout the lifecycle of the request item and will be notified when a task is updated/closed/etc.

any best practices?

2 REPLIES 2

Rahamath
Tera Expert

Hey Connie,

 

Syntax :  current.variables.<variable_name>

current.watch_list = current.variables.contact_name 


Here Contact_name is catalog variable.

Thanks
Rahamath

Connie5
Kilo Contributor

Thank you Rahamath!

So do I create a new syntax by going to 

  1. Navigate to System Definition > Syntax Editor Macros.
  2. Click New or select the macro to edit.
  3. Define the macro details with the fields listed in the table below.

Name = Add Contact Name to Watch List

Comments = Add Contact Name to Watch List

Text = current.variables.<variable_name>
current.watch_list = current.variables.contact_name 

 

How do I tie this to the variable set created that has the contact_name variable and ensure it does it for all the catalog items that has that variable set?