Store value other than the display value
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-14-2017 10:33 AM
Hey guys,
Is there a way to display and store the value on a reference field other than the display value of the table it is referencing? I am currently dynamically trying to populate the Step field, based on the Job Title selection, however I want the 'Step' reference field to display the u_step field on the table instead of the name id (which is set as the display field).
This what I have on the form:
This is my script include that I am calling as reference qualifier on the step dictionary item:
var ChangeStep = Class.create();
ChangeStep.prototype = {
initialize: function() {
},
changeOptions : function() {
var stepList = ' ';
var jt = current.u_job_title;
var sl = new GlideRecord('profiles');
sl.addQuery('u_udc','position');
if(jt) {
sl.addQuery('uc_code',jt.u_it_code);
}
sl.query();
while(sl.next()) {
if (stepList.length > 0) {
stepList += (',' + sl.u_step);
}
else {
stepList = sl.u_step;
}
},
return 'u_stepIN' + stepList;
},
type: 'ChangeStep'
};
Thanks,
Raed
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-05-2018 12:12 PM
Is there any solution for this? I am also facing the same issue.
Thanks
Hiran
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-05-2018 12:25 PM
Are you looking to have different to be show in reference field other than what is set for display value? If yes then that's not possible. In a table there can be only one column set as display and when you reference that table only display value true can be shown. but you can achieve it by setting the ref_ac_display_value attribute to false.
Please check below link if that helps.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-05-2018 12:34 PM
Yes, in reference field i want to display other field value than the "display field" .
I have already checked this link. As per this link it changes the default view on global level eg - wherever i will use sys_user table as reference it will by default display that column.
But i want to just display "Email ID" as default in one place. In other places it should display "Name" as OOB.
Thanks
Hiran
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-05-2018 12:41 PM