The CreatorCon Call for Content is officially open! Get started here.

Auto-populate variables within variable set on catalog item

Averyy
Tera Contributor

I am working on auto-populating all catalog item variables based on the user..

All variables are within two variable sets per screenshots below...

 

I want to populate the "Device name" and "organization" variable based on what ever user is selected in the "on behalf of" variable.

As of now it is referencing the "Requested by" variable on screenshot 2 using simple basic conditions. I was thinking if I switched out the sysID for the "on behalf of" sysID but that did not work...

Device name is referencing a computer table 

 

1. Catalog item view from Service Portal

2. Variable set -> "Device Name" variable -> Type Specification Tab

3. Variable set "Peo Requestor information" -> "On behlf of" variable'

4. Variable set "Peo Software Request " -> "Device name", "organization " variable 

1.

Averyy_6-1699900806709.png

 

2.

Averyy_3-1699900393023.png

3.

Averyy_4-1699900420292.png

4.

Averyy_5-1699900680874.png

 

 

 

 

 

6 REPLIES 6

Brad Bowman
Kilo Patron
Kilo Patron

If you are on the Utah version or later, use the auto populate feature

https://www.servicenow.com/community/developer-articles/auto-populate-a-variable-based-on-a-referenc... 

Since the 'dependent' (on behalf of) and target (device name, org) variables are in variable sets, you won't see on behalf of as an option when trying to set the dependent of device name, but I'm working on something that should correct that oversight, so let me know if this is what you want to do.

Yes , a possible solution would be great