- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-11-2022 07:06 AM
Hi Team,
i am trying to populate some field value from a User record via On Change catalog client script and getting this message in logs
Cancelling transaction #67630 /angular.do (cancelled by other transaction) angular.do?sysparm_cancelable=true&sysparm_type=sp_ref_list_data
Solved! Go to Solution.
- Labels:
-
Request Management
-
Service Catalog
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-12-2022 10:51 PM
thanks

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-11-2022 07:10 AM
Hi,
Not too sure about that log message, but can you post briefly what you're trying to do?
Perhaps there's an issue with your script include. Unfortunately, you didn't provide information if this worked previously or not, or if this is brand new development (thus errors and such may be expected).
Please mark reply as Helpful, if applicable. Thanks!
Please consider marking my reply as Helpful and/or Accept Solution, if applicable. Thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-11-2022 07:49 AM
variableset variable name = ref_requester
on change of this variableset variable the manager, location and department should be changed
script include - client callable
var MWNUserUtils = Class.create();
MWNUserUtils.prototype = Object.extendsObject(AbstractAjaxProcessor, {
getUserDetails: function(){
var id = this.getParameter("sysparm_id");
var gr = new GlideRecord("sys_user");
gr.get(id);
if (gr.next()) {
var dataArray={"manager": gr.getValue('manager'), "location": gr.getValue('location'), "department": gr.getValue('department') };
return JSON.stringify(dataArray);
}
},
type: 'MWNUserUtils'
});
catalog client script:
function onChange(control, oldValue, newValue, isLoading) {
if (isLoading || newValue == '') {
return;
}
var ajax = new GlideAjax('MWNUserUtils');
ajax.addParam('sysparm_name', getUserDetails);
ajax.addParam('sysparm_id',g_form.getValue('ref_requester') );
ajax.getXML(getResponse);
function getResponse(response){
var answer = response.responseXML.documentElement.getAttribute("answer");
var obj= JSON.parse(answer);
alert("response: " + obj.manager);
g_form.setValue('ref_location', obj.location);
g_form.setValue('ref_business_unit', obj.department);
g_form.setValue('ref_reporting_to', obj.manager);
}
}
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-12-2022 10:51 PM
thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-11-2022 07:15 AM
Can you show your script?
Is it taking too much time or something?
Is the behavior same when you try from portal Vs when you try from native ui?