- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-17-2022 02:23 PM
Hi Community,
Just wondering if anyone could provide some suggestions or thoughts on this problem. We've recently upgraded to Tokyo and our portal search experience got a nice little upgrade. We now have "Suggestions" which provides us with a quick way to open items during a search.
Unfortunately, we've run into an issue where our order guides are being opened as an sc_cat_item, instead of sc_cat_item_guide when the user uses the "Suggested" feature. As such, the order guide isn't presented properly (does not have the "Next" button or the "Choose Options" button to proceed us to the next step). However, if the user completes the search to see the full results and then selects the item, they will be able to access the result properly (as a sc_cat_item_guide).
As an example:
If the user clicks the "Suggested - Order Guide - TEST", they will be brought to the order guide with the following URL:
https://<instance>.service-now.com/sp?id=sc_cat_item&table=sc_cat_item&sys_id=<sys id>
Whereas if they were to see the full list of results from the search and then click on the item, they would be brought to the order guide with the following URL:
https://<instance>.service-now.com/sp?id=sc_cat_item_guide&table=sc_cat_item&sys_id=<sys id>
We've tried:
- Marking the order guide as "No Search" - but this prevents the item from being searched at all
- Adjusting the Search Profile/Search Source (AI Search > Search Experience > Search Profiles) to hide the Class of Order Guides from the search results - the order guide as a Catalog Item shows up
- Trying to add order guides as a Facet in the Search Applications (AI Search > Search Experience > Search Applications) - but we get an error "Invalid table name: "sc_req_item_guide". Please ensure that the table is defined in the current search profile's search sources."
- So we tried to add an indexed source for the sc_cat_item_guide table but it doesn't exist
- So we tried to add an indexed source for the sc_cat_item_guide table but it doesn't exist
At this point, it looks like we are either going to have to disable the Suggested results from showing up or deal with the backlash of our end users being unable to submit an order guide. Our intention would be to be able to prevent specific items (our order guides) from appearing as a Suggested item in the search experience.
Any tips or suggestions would be really appreciated!
Thank you
Solved! Go to Solution.
- 9,645 Views
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-09-2023 04:05 PM
Hi Dale,
Try this:
function onLoad() {
//Type appropriate comment here, and begin script below
var qury = getParameterValue("id");
var sysId =getParameterValue("sys_id");
//alert('ji-- '+qury);
if(qury == "sc_cat_item"){
top.window.location = "/sp?id=sc_cat_item_guide&table=sc_cat_item&sys_id="+sysId
}
function getParameterValue(name) {
name = name.replace(/[\[]/, "\\\[").replace(/[\]]/, "\\\]");
var regexS = "[\\?&]" + name + "=([^&#]*)";
var regex = new RegExp(regexS);
var results = regex.exec(top.location);
if (results == null) {
return "";
} else {
return unescape(results[1]);
}
}
}
Created on the order guide as an onLoad script
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-17-2022 02:38 PM
Hi,
Are you using a custom logic for search?
Thanks and Regards,
Saurabh Gupta
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-17-2022 02:46 PM
My team deals with pushing a certain group of users to a Service Portal at every turn so they should never end up in an itil user's view. We accomplish this with a UI Script and Script Include. You could pass the URL or just the sys_id from the UI Script to the Script Include to look up the catalog item. If the catalog item is an order guide, pass back a constructed URL or variable(s) to construct one for the UI Script to redirect the user to.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-17-2022 03:27 PM
@Saurabh Gupta - Nope, no custom logic. just OOB
@Claude DAmico - thanks, seems like it could be an option but for now we are trying not to go down the path of creating scripts to hide the result
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-08-2022 01:37 PM
Did you get a fix for this? We are having the same issue.