- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-19-2022 12:55 AM
Hi,
I want to set/display custom view , I have given url in email script for sysapproval_approver form. When i click url in the email notification, it is directing to the default view, how can i make the user to redirect it to the custom view created for approval table .
below is the code i have added for providing url ,please let me know where and how to include the custom view name here.
var str = "<a href =\"https://" + gs.getProperty('instance_name') + ".service-now.com/nav_to.do?uri=%2Fsysapproval_approver.do%3Fsys_id%3D" + current.sys_id + "\">" + URL + "</a>";
Thanks & Regards,
Kalyani
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-19-2022 01:02 AM
Hey @kalyani23
you have to add the view to the URL by using "sysparm_view=<name of the view>".
So in your example this could be: <a href =\"https://" + gs.getProperty('instance_name') + ".service-now.com/nav_to.do?uri=%2Fsysapproval_approver.do%3Fsys_id%3D" + current.sys_id + "%26sysparm_view=viewname\">
Best regards
Oli
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-19-2022 01:02 AM
Hey @kalyani23
you have to add the view to the URL by using "sysparm_view=<name of the view>".
So in your example this could be: <a href =\"https://" + gs.getProperty('instance_name') + ".service-now.com/nav_to.do?uri=%2Fsysapproval_approver.do%3Fsys_id%3D" + current.sys_id + "%26sysparm_view=viewname\">
Best regards
Oli
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-19-2022 01:33 AM
Thank you for providing the solution, i have tried it and is working as expected.