Need help with Catalog Checkout widget (service portal)

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-21-2019 02:12 PM
We have onboarding form built using Order Guide. This form has a requested for field where the manager puts in his employee name for onboarding. This form when reaches the "Order Confirmation" screen, it pulls the gs.getUser().getID() in the requested for field. I am expecting the employee name here.
How do I get the employee name in checkout?
- Labels:
-
Service Portal

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-22-2019 12:58 PM
There is a client script on our onboarding form setting the cart's requested_for
function onChange(control, oldValue, newValue, isLoading) {
if (isLoading || newValue == '') {
return;
}
//Set Cart's requested_for user
var ga = new GlideAjax('CartAjaxProcessorV2');
ga.addParam('sysparm_action', 'req_for');
ga.addParam('sysparm_value', newValue);
ga.getXML({}, null, null);
}
If I turn the above client script on for Desktop UI, everything works well on Native UI. But, the Service Portal is not picking the requester name on checkout popup and instead pulls the gs.getUser name.
If I turn the above client script on for All UI type, then the Service Portal is showing Javascript error on (Requested for) field value change of the Order Guide form. Then I found that UI Script "CartCheckoutFunctionsV2" is not working in Service Portal because it has $ sign and so throwing a javascript error on field value change.
Has someone come across any fix for this?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-12-2021 11:21 AM
Have you found an answer for this? I am looking for a similar solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-19-2021 02:42 PM
This was a long time ago, so I don't remember everything. But I did modify some Service Portal widgets for our needs "SC Shopping Cart", "SC Saved Carts", "Catalog Checkout", "SC Order Guide".