how to place a variable inside a variable set

sohan_snow
Tera Contributor

Hi All,

I need to place an extra variable inside a variable set applicable ONLY for 1 catalog item. For other catalog items that uses the same variable set, this extra variable should not be displayed.

I tried keeping the order of the extra variable 'd' as 150 (order of variable 'a' and 'b' is 100 and 150 respectively ) . however, the variable 'd' was displayed below the last variable 'c' instead displaying below variable 'a'

find_real_file.png

Thanks in advance

1 ACCEPTED SOLUTION

Geoffrey2
ServiceNow Employee
ServiceNow Employee
  1. Place Variable d inside the Variable Set where you want it.
  2. Create a Catalog UI Policy on the Variable Set that hides Variable d by default (no condition).   Leave Order at 100. Make sure you can't see the Varaible on any Catalogue Item.
  3. Create a new Catalog UI Policy on the 1 Catalogue Item where you want to see it. Show Variable d. Set the Order to 110 (or anything over 100).
    Verify that you can see Variable d only on the Catalogue Item you want.

View solution in original post

12 REPLIES 12

so the only way around would be to create the variable in the VS and then display it ONLY for the intended Catalog item


PriyaRanji
Tera Guru

Hi Sohan,



Good Day



Variable sets allow you to group variables together, and share this group between multiple catalog items and order guides.



Changes made to a variable set affect all items that use the variable set, allowing you to change the set once, then apply the changes to all items using that set.



Step 1 : Create a variable set



Step 2 : create as much variable you need in that variable set



Hope it helps you out.



Thanks,


Priyanka R


adityaghosh
Tera Guru

yes, you can use the g_form.setDisplay, g_form.setVisisble to hide/show this variable