get the comment in the @mention notification
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
â12-16-2024 11:22 PM
i have the notifcation sent when somone mention somone with @ in the worknotes or comments,
how to add the actual @ comment into the notification?
2 REPLIES 2
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
â12-16-2024 11:25 PM
you can use email script for this
something like this
// Get the latest work note or comment
var journalEntry = current.comments.getJournalEntry(1); // Retrieves the latest comment
var workNoteEntry = current.work_notes.getJournalEntry(1); // Retrieves the latest work note
// Check if the latest entry contains an @ mention
var mentionComment = '';
if (journalEntry && journalEntry.indexOf('@') !== -1) {
mentionComment = journalEntry;
} else if (workNoteEntry && workNoteEntry.indexOf('@') !== -1) {
mentionComment = workNoteEntry;
}
// Add the mention comment to the notification
template.print('<p><b>Mention Comment:</b> ' + mentionComment + '</p>');
If my response helped please mark it correct and close the thread so that it benefits future readers.
Regards,
Ankur
⨠Certified Technical Architect || ⨠9x ServiceNow MVP || ⨠ServiceNow Community Leader
Ankur
⨠Certified Technical Architect || ⨠9x ServiceNow MVP || ⨠ServiceNow Community Leader
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
â12-16-2024 11:47 PM
i didnt go the comment( you can see below)
why is that? maybe because work notes is private?
do you have a way to fix it?