- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-08-2016 05:00 AM
Where I can configure infomessage on portal, for example when new HR case is created, there are two infomessages, I need to change them little bit (trim surname and change link) but I have no idea where I could find them.
Solved! Go to Solution.
- Labels:
-
Service Portal
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-09-2016 07:04 AM
Hi Jan,
You can edit the "Created..." message by editing a Widget. The Widget you are seeking is called SC Catalog Item (widget-sc-cat-item). Clone that widget to begin making your changes.
The logic for generating the messages exists in the Client Script.
Edit the function at the bottom of the Client Script, called issueMessage(). This is what is called after the form has been submitted, and the order has been processed.
function issueMessage(n, table, sys_id) {
var page = table == 'sc_request' ? 'sc_request' : 'ticket';
var t = "${Created} " + n + " - ";
t += "${track using 'Requests' in the header or}";
t += ' <a href="?id=' + page + '&table=' + table + '&sys_id=' + sys_id + '">' + "${click here to view}" + '</a>';
spUtil.addInfoMessage(t);
}
Once you have made the changes, simply replace the OOB Widget Instance that appears on the page "sc_cat_item", with your newly cloned one.
If you want to see where issueMessage() gets called, take a peek at the getOne() function for its use.
I am unsure where the "assigned to" message gets called from, but it is not in the Widget from what I can tell.
Thanks.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-08-2016 11:07 AM
Not sure if there is an easy way, however you can try looking into some system logs: Viewing System Logs - ServiceNow Wiki
or try running on of these debugging tools, may be the client side debugging: Debugging Tools Best Practices - ServiceNow Wiki
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-09-2016 07:04 AM
Hi Jan,
You can edit the "Created..." message by editing a Widget. The Widget you are seeking is called SC Catalog Item (widget-sc-cat-item). Clone that widget to begin making your changes.
The logic for generating the messages exists in the Client Script.
Edit the function at the bottom of the Client Script, called issueMessage(). This is what is called after the form has been submitted, and the order has been processed.
function issueMessage(n, table, sys_id) {
var page = table == 'sc_request' ? 'sc_request' : 'ticket';
var t = "${Created} " + n + " - ";
t += "${track using 'Requests' in the header or}";
t += ' <a href="?id=' + page + '&table=' + table + '&sys_id=' + sys_id + '">' + "${click here to view}" + '</a>';
spUtil.addInfoMessage(t);
}
Once you have made the changes, simply replace the OOB Widget Instance that appears on the page "sc_cat_item", with your newly cloned one.
If you want to see where issueMessage() gets called, take a peek at the getOne() function for its use.
I am unsure where the "assigned to" message gets called from, but it is not in the Widget from what I can tell.
Thanks.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-21-2016 12:37 AM
Thank you Paul, thats it!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-31-2017 06:57 AM
How to prevent confirmation messages( infomessages ) from disappearing after a few seconds. If we hoover over the message then it stays but I need to extend it for some more time before it gets disappeared.
Thanks in advance
Adrish
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-04-2017 06:38 PM