Create a catalog request in Agent Workspace

TT3
Kilo Guru

The documentation provided by ServiceNow at here is very unclear. Especially, first two points in the section "Before you begin".

  • To associate a request with any parent table record, the corresponding mapping configuration should be available in the Catalog Administration > Request Parent Mapping submodule.
  • To associate a record producer request with the parent table record, retrieve the sysparm_parent_sys_id and sysparm_parent_table parameters from the URL using the RP.getParameterValue() method in the Script field of the record producer.

Further, there is no screenshot or any other reference available on what is the intention.

Can someone please explain in what this is about?

I have a record producer and I want to show it in Agent workspace. My expectation was that this article will help for the same.

Further, why there is no documentation available for below function?

g_service_catalog.openCatalogItem('sc_cat_item', '-1', params);

 

Thank you.

I will mark you response correct/helpful if applicable.

2 REPLIES 2

Shane41
ServiceNow Employee
ServiceNow Employee

Hi TT,

if you want to open a specific record producer from the workspace here are the steps:

1. Copy the OOTB UI action 'Create Request'

find_real_file.png

https://[YOURINSTANCENAME].service-now.com/nav_to.do?uri=sys_ui_action.do?sys_id=084959b087081300e30...

 

2. In the workspace client script, change the following line

g_service_catalog.openCatalogItem('sc_cat_item', '-1', params);

to 

g_service_catalog.openCatalogItem('sc_cat_item', '04b7e94b4f7b4200086eeed18110c7fd', params);

 

The entry in bold should be your record producers sys_id

 

3. You will see the UI action in the workspace, i created an order laptop Ui action as an example

find_real_file.png

When this UI action is clicked it opens the standard laptop catalog item on a new tab

find_real_file.png

Hope this helps,

Shane

Hi Shane, I tried that the problem with this approach is very strange.

Let's say we are opening request for each incident. So you select an incident and then there is a button (UI Action) to make catalog request.

Now, if you open two incidents at the same time and then open catalog request for each, any change you make in the request for one incident will reflect in  request for another incident.