Is it possible to change notification comments added name with specific user name
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-25-2024 12:01 AM
Hi,
Is it possible to change notification comments added name(highlighted below) with specific user name for all the time when comments added?
Thank you
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-25-2024 12:30 AM - edited 07-25-2024 12:31 AM
Hi @Hari S1,
To always show a specific user name for notification comments in ServiceNow, you can use a business rule or modify the email notification template. Here's a quick summary:
Modify Email Notification
- Go to System Notification > Email > Notifications.
- Edit the relevant notification.
- Replace ${comments.added_by} with the specific user name (e.g., John Doe) in the message content.
- Save the notification.
Use a Business Rule:
Set it to run "Before" or "After" the appropriate condition
(function executeRule(current, previous /*null when async*/) {
// Set the comments added by a specific user
current.comments.setJournalEntry("Comment added by John Doe:\n" + current.comments.getJournalEntry(1));
current.update();
})(current, previous);
Thank you, please make helpful if you accept the solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-25-2024 01:06 AM
Hi @Yashsvi ,
Thanks for the reply.
I tried the notification part which you mentioned.
Is this the right way to add the line in notification:
Thank you
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-01-2024 12:53 AM
Hi All,
Can someone please help me on this issue?
Thank you in advance.