I want to redirect the record producer to a particular URL after submitting from the service catalog.

Phoebe Buffay
Mega Expert

Hi All,
I want to redirect the record producer to a particular URL after submitting from the service catalog. After redirecting the URL, I was looking to provide an info message as well. Below is the sample code which I am trying at the end of the script:

producer.redirect="home.do";
gs.addInfoMessage("Test");

Also, the Redirect To field is selected as "Catalog Homepage". Hence currently, after submitting, it is redirecting to Catalog Homepage.

11 REPLIES 11

Pranav Bhagat
Kilo Sage

Hi 

You can redirect the record producer after creating the record into the form by applying the following in the script 

For Service Portal

producer.portal_redirect = "sp?id=sc_home" ; // You can put any page

For Backend

producer.redirect="home.do";

Reference Document:

https://docs.servicenow.com/bundle/orlando-it-service-management/page/product/service-catalog-management/concept/c_PopulatingRecordData.html

Regards

Pranav

Kieran Anson
Kilo Patron

Hi,

If you want to override the behaviour for the service portal, you need to use 

producer.portal_redirect

Hi,

We are not using Service Portal. I was looking to redirect Within the Platform UI.

Pranav Bhagat
Kilo Sage

Hi

Here is the sample Script

find_real_file.png

 

 

Regards

Pranav