Recent and popular items widget is showing catalog items from other portals.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-22-2025 06:09 AM
In my organization we are using Employees Center portal as the main IT service portal. On the portal home page, I have “Recent and Popular” item widget which is OOTB. But recently I'm noticing that this widget is showing catalog items from other portals (for example CSM portal).
Within the portal page I already added the taxonomy in the related list so that it will show all the items from the IT Portal and not from CSM portal. But still, it is showing other catalog items which doesn't belong to the taxonomy. Do I need to do any changes or does it need a custom widget (specific to the portal). Any pointers will be appreciated.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-22-2025 07:26 AM
Yes, you are looking in right direction. Recent & Popular items widget shows data from sp_log table which do not apply any filter for current portal.
So you can use below approach:
- Clone the widget
- In server side script, after line number 5 (GlideRecord to sp_log table), add a line to include
recent.addQuery('portal', 'sysidOfYourPortal'); - That's it. now you can place this widget in your home page.
Accept the solution and mark as helpful if it does, to benefit future readers.
Regards,
Sumanth
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-22-2025 07:29 AM
You can use another approach aswell,
In recentItems array, remove all the items that are not mapped with the current portal taxonomy topics.
Regards,
Sumanth
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-22-2025 10:21 AM
I cloned the widget and this is how my 5 and 6th lines look. I refined the query for sp_log.
var recent = new GlideRecord('sp_log');
recent.addQuery('protal','70cd9f3b734b13001fdae9c54cf6a72f');//sys_id of my portal.
its not working, do I need to do anything else
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-22-2025 10:46 AM
Spelling mistake 'protal' -> 'portal'