Catalog item reference field shows sysIDs

dev_K
Tera Contributor

Hi All,

 

 

I would like to create a field that shows in the dropdown all the groups that the requester belongs to however

when I test this catalog item I see that the sysIDs of the groups are fetched instead of the names of the groups. How can I fix it?

 

 

dev_K_0-1727420575585.png

 

 

dev_K_1-1727420714757.png

 

Thanks!

 

7 REPLIES 7

Aniket Chavan
Tera Sage
Tera Sage

Hello @dev_K 

Could you please check the display value for the sys_user_grmember table? If the display value for the sys_id field is set to true in that table, the sys_id will be reflected on the portal for the reference variable. To display the group name instead, you’ll need to set the display value to true for the group field.

Aditya02
Tera Guru

Hi @dev_K ,

 

Check the sys_user_grmemebr table once, Weather the display value is true for the field you want to display.

Suppose if you want to get names of the groups set the group name field display value as TRUE. 

 

"If you found my answer helpful, please give it a like and mark it as the accepted solution. It helps others find the solution more easily and supports the community!"

 

Thank you,

Aditya

Stefan Reichelt
Tera Guru
Tera Guru

The thing is that even if you change the Display Value for that table, you can adjust what is shown in the reference field after the selection, but the lookup list itself won't change. You can also change that:

 

StefanReichelt_0-1727422986394.png

BUT both actions may cause issues in other scenarios where you want to work from the opposite point of view.

 

I would rather recommend to do a lookup against the actual sys_user_group table, and to filter for all the groups of the current user  there. You can do what ever you want to do in the logic later (like with a Flow that is taking the selected group, and looking into the group membership table again). The bare M2M tables are probably not the best elements to expose in a catalog item.

 

Proposed solution:

StefanReichelt_1-1727423520726.png

sys_idINjavascript:gs.getUser().getMyGroups()

 

 

it seems this ref qualifier does not work... im seeing all the groups