- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-22-2017 09:33 AM
Hi Community!
Have an issue with a UI macro for downloading a SOP document from a knowledge base article.
When I preview the record producer myself the download works correctly but the record producer preview window redirects to the homepage url.
When I impersonate a Customer user who would be accessing this SOP document , the below screenshots show, the redirect happens again but completely freezes the instance. and also it does not download.
Can anyone advise on the redirect issue and the download not working for the Customer user?
Screenshot 1: User clicks the SOP document link
Screenshot 2: UI Macro does not Download document and redirects to frozen duplicate homepage screens
Solved! Go to Solution.
- Labels:
-
Knowledge Management
-
Service Catalog
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-23-2017 09:19 PM
It seems like again you are using a deep link and its opening frame inside a frame. There shouldn't be 'nav_to.do?uri=' in the link. Remove bold part from below link.
"https://test.service-now.com/nav_to.do?uri=sys_attachment.do?sys_id=5ae18a3c37abb200a1e9466754990e00"
If the attachment is on same instance then you could also use a relative link
"/sys_attachment.do?sys_id=5ae18a3c37abb200a1e9466754990e00"
After all the user should have access over attachment.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-22-2017 09:53 AM
Hi Chad,
Where are you redirecting the user.. Please paste the link in here. try to include target="_blank" in the <a> tag. Also do not use deep link (don't use nav_to.do?uri=..) in link.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-22-2017 09:55 AM
Apologies, completely forgot to put the UI Macro xml
<?xml version="1.0" encoding="utf-8" ?>
<j:jelly trim="false" xmlns:j="jelly:core" xmlns:g="glide" xmlns:j2="null" xmlns:g2="null">
<a href="https://test.service-now.com/nav_to.do?uri=sys_attachment.do?sys_id=5ae18a3c37abb200a1e9466754990e00">SOP Document</a>
</j:jelly>
We do NOT want the url to redirect at all, but it seems to no matter what
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-22-2017 09:59 AM
Try below code
<?xml version="1.0" encoding="utf-8" ?>
<j:jelly trim="false" xmlns:j="jelly:core" xmlns:g="glide" xmlns:j2="null" xmlns:g2="null">
<a href="https://test.service-now.com/sys_attachment.do?sys_id=5ae18a3c37abb200a1e9466754990e00" target="_blank">SOP Document</a>
</j:jelly>
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-22-2017 10:23 AM
That seemed to work, for me at least, but when I impersonate a customer user who has access to the Knowledge base it just has a blank page pop up in new tab and no download.
When I click the url macro link the blank page appears and disappear once download occurs which is the expected behavior.
Is there something missing ?