- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-12-2019 09:54 AM
Hi All,
Can we extend gs.addErrorMessage() time on Service portal?
I want to trigger Error Message When user's Manager is not assigned. Message is getting displayed but it disappears after few seconds can we extend the time for error message?
Below is my code which I have added on server controller part of a widget.
var grUser = new GlideRecord('sys_user');
grUser.get(gs.getUserID());
grUser.query();
if(grUser.next())
{
if(grUser.manager =='' )
{
gs.addErrorMessage("Manager field is empty");
}
}
Thanks and Regards,
Meenal
Solved! Go to Solution.
- Labels:
-
Service Catalog
-
Service Portal
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-12-2019 09:58 AM
Hi Meenal,
there is 1 system property; try to check the value for that
glide.service-portal.notification_timeout.seconds
I think default is 5; but try to increase to 10 or 20 seconds and check;
a value of zero disables auto-dismissal i.e. message will be shown unless user clicks cross icon
Note: this would be a global change
Mark Correct if this solves your issue and also mark Helpful if you find my response worthy based on the impact.
Thanks
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-20-2022 02:53 AM
Hello Ankur,
I have a requirement where we need to increase this error message timeout for 10sec for another portal (esc) and it shouldn't effect the existing service portal configuration (5 sec). Can you please suggest on how to do this ?
Thanks in advance..