How to access parent catalog variable from inside a variable of a variable set

hoathong99
Tera Contributor

I am making a catalog item, in which, there is a u_choosen_group and a multi row variable set member_lists which contain a variable u_remove_member.

hoathong99_1-1755252712203.png

hoathong99_2-1755252732616.png

 

 

When add new item to the list
I need u_remove_member to be a reference type the only show that of selected u_choosen_group.
(if I choose HR admin group, only that of HR admin group is available for selection)
If u_remove_member is an outer variables, I can set advanced reference qualifier  to 
javascript:'group='+current.u_choosen_group;
and it works fine, but inside the variable set, current is difference and it no longer work.
I tried something like javascript:'group='+current.parent.u_choosen_group; but it doesn't work

hoathong99_3-1755252809734.png

 

1 ACCEPTED SOLUTION

Swapna Abburi
Mega Sage
Mega Sage

Hi @hoathong99 

Two things. Firstly, you can go with simple list collector instead of MRVS if it is just one variable in your MRVS. Which will make configuration simpler.

 

Secondly, if you want to use catalog variable in MRVS then you need to create another hidden similar variable in MRVS and populate it using below method in MRVS Client script. Then you can use the value of new variable in reference qualifier.

g_service_catalog.parent.getValue('variable_name')

View solution in original post

2 REPLIES 2

Swapna Abburi
Mega Sage
Mega Sage

Hi @hoathong99 

Two things. Firstly, you can go with simple list collector instead of MRVS if it is just one variable in your MRVS. Which will make configuration simpler.

 

Secondly, if you want to use catalog variable in MRVS then you need to create another hidden similar variable in MRVS and populate it using below method in MRVS Client script. Then you can use the value of new variable in reference qualifier.

g_service_catalog.parent.getValue('variable_name')