How to redirect to another Service Portal page after submit of service catalog

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-17-2018 10:46 AM
We are trying to redirect user after submission of a service catalog item form to a specific page however the below code does not work:
producer.redirect ="sp?view=sp&id=form&table=change_request&sys_id="+current.sys_id;
I've seen a known error document on the producer.redirect not working for Service Portal (fixed in Jakarta) - we are already on Jakarta so not really sure why it is still not working. Is there any way to redirect user to specific SP page?
- Labels:
-
Change Management
-
Incident Management

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-17-2018 10:50 AM
please check related articles below to know more about such configurations:
The thing about redirecting to the Service Portal
6 ways to set up your Service Portal for redirection SUCCESS!
Regards,
Sachin

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-17-2018 08:20 PM
None of those articles address our issue on redirecting after submitting a service catalog (record producer).

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-18-2018 05:54 AM
you need to develop widget to render your record producer and add code in your widget to redirect to SP page.
check below sample widget code to redirect to particular SP page
function issueMessage(n, table, sys_id) {
var page = table == 'sc_request' ? 'sc_request' : 'ticket';
//var t = "${Created} " + n + " - ";
//t += "${track using 'Incidents/Changes' in the header or}";
//t += ' <a href="?id=' + page + '&table=' + table + '&sys_id=' + sys_id + '">' + "${click here to view}" + '</a>';
//spUtil.addInfoMessage(t);
//go to the ticket view instead
var url = "?id=" + page + '&table=' + table + '&sys_id=' + sys_id;
$location.url(url);
}
Regards,
Sachin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-02-2018 02:22 AM
Is this when submitting from the SC Catalog Item widget?
And if so, would you like to go to a different ticket page? Or to a standard homepage?
If you have the same issue I had, you need to clone the SC Catalog Item widget, and edit the server script ~ line 19
options.url = options.url || "?id={page}&table={table}&sys_id={sys_id}";
If you want a new ticket page replace {page} with your ticket page
i.e.
options.url = options.url || "?id=sc_request&table={table}&sys_id={sys_id}";
Or else replace the whole url with a hardcoded uel
You then need to edit the widget on the page to redirect on submission.
Let me know if this helps
Thanks