Include Defect, Enhancement, Incident in Service Portal Search
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-29-2018 12:50 AM
Hi All,
I am working on a requirement to allow search for defects, enhancements and incidents in Service Portal Search.
Based on the below blog,
https://community.servicenow.com/community?id=community_blog&sys_id=de5ce6a1dbd0dbc01dcaf3231f96194a
I configured incident table in Search Source in my Portal.
But when i search for incident number in service portal, it is not working.
Please help me on this.
Thanks,
Maddy

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-29-2018 01:04 AM
HI,
Make sure you edit code in search sources and include incident as a tale for search.
If you open Service Catalog Search Source you will see script in it as line seven if you see var sc = new GlideRecord('sc_cat_item');
so similarly we have to use incident table as well. This is applicable if you are using Script if not then use normal condition.
Can you show how you configured it.
Thanks,
Ashutosh Munot
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-29-2018 01:10 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-29-2018 01:56 AM
HI,
You also have to edit Search page.
See below page code:
HTML:
<div class="list-group">
<a ng-class="{active: !data.t}" class="list-group-item" ng-href="?id=search&q={{data.q}}"><i class="fa fa-chevron-right"/><span class="m-l-sm">${All}</span></a>
<a ng-if="data.hasKB" ng-class="{active: data.t=='kb'}" class="list-group-item" ng-href="?id=search&t=kb&q={{data.q}}"><i class="fa fa-chevron-right"/><span class="m-l-sm">${Knowledge Base}</span></a>
<a ng-if="data.isLoggedIn && data.hasCatalog" ng-class="{active: data.t=='sc'}" class="list-group-item" ng-href="?id=search&t=sc&q={{data.q}}"><i class="fa fa-chevron-right"/><span class="m-l-sm">${Service Catalog}</span></a>
<a ng-if="data.isLoggedIn" ng-class="{active: data.t=='incident_search'}" class="list-group-item" ng-href="?id=search&t=incident&q={{data.q}}"><i class="fa fa-chevron-right"/><span class="m-l-sm">${Incident}</span></a>
<a ng-if="data.sqandaEnabled" ng-class="{active: data.t=='qa'}" class="list-group-item" ng-href="?id=search&t=qa&q={{data.q}}"><i class="fa fa-chevron-right"/><span class="m-l-sm">${Questions and Answers}</span></a>
<a ng-repeat="group in data.searchGroups" ng-class="{active: data.t==group.table}" class="list-group-item" ng-href="?id=search&t={{group.table}}&q={{data.q}}"><i class="fa fa-chevron-right"/><span class="m-l-sm">{{group.label || group.table}}</span></a>
</div>
See below screen shot.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-29-2018 03:11 AM
Hi Ashutosh,
I checked in my personal developer instance. It is working without any changes to the Search Page Template, it is in Kingston Instance.
But in our instance, it is still not working, it is in Jakarta instance.
I also tried to edit the search page template. But still not working.
Thanks,
Maddy