sys_id instead of value displayed

jean-pauldehaas
Tera Guru

Hi all,

 

i have a catalog item as follows:

variable 1: Owner of the team (reference to sys_user)

variable 2: email address (single line)

variable 3: organization (singe line)

 

Variable 2 and 3 should change when variables  1 changes, this works for both only variable 3 is displayed with the sys_id of the organization.

find_real_file.png

Catalog client script used:

 

find_real_file.png

 

what am i doing wrong here ?

1 ACCEPTED SOLUTION

Jaspal Singh
Mega Patron
Mega Patron

You need to change the Organization variable to be of type Reference instead of Single line text.

View solution in original post

12 REPLIES 12

SumanthDosapati
Mega Sage
Mega Sage

Hi,

 

Change your 10th line to below

user.u_organisation.getDisplayValue();

 

Mark as correct and helpful if it solved your query.

 

Regards,

Sumanth

FYI.

this won't work in client side.

Regards
Ankur

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

 

organization field stays empty on the catalog item

Musab Rasheed
Tera Sage
Tera Sage

Hello,

Use getDisplayValue() for Organisation like below

user.u_organization.getDisplayValu();

Mark my answer as correct if that helps.

Regards

Please hit like and mark my response as correct if that helps
Regards,
Musab