- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-30-2025 10:41 AM
Hi Team,
Im having a problem that my notification is going out with the word 'Code' at the top and at the bottom. it happens only when I add comments or work_notes
Here is the script can someone assist
var notificationUtil = new IncidentNotificationUtil();
var comment = notificationUtil.getLatestCommentOrWorkNotes(current.getTableName(), current.getUniqueValue(), 'comments');
template.print('<div style="text-align: center; line-height: 36px; padding-bottom: 24px; border-bottom: 1px solid #DADDE2;"><span style="font-size: 24px; font-weight: 600; color: #181A1f;">' + comment.user + ' added a comment to Requested Item</span></div>');
template.print('<div style="font-size: 16px; padding-top: 24px; padding-bottom: 16px; color: #181A1F"><span style="font-weight: 700;">' + comment.user + ' </span>');
template.print('<span style="font-weight: 400;">left a comment on </span>');
template.print('<span style="font-weight: 700;">${number}:</span></div>');
template.print('<span style="font-weight: 600;color: #181A1F">' + comment.val + '</span>');
Regards
Rak**bleep**h
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-30-2025 11:22 AM
try this
var notificationUtil = new IncidentNotificationUtil();
var comment = notificationUtil.getLatestCommentOrWorkNotes(current.getTableName(), current.getUniqueValue(), 'comments');
template.print('<div style="text-align: center; line-height: 36px; padding-bottom: 24px; border-bottom: 1px solid #DADDE2;"><span style="font-size: 24px; font-weight: 600; color: #181A1f;">' + comment.user + ' added a comment to Requested Item</span></div>');
template.print('<div style="font-size: 16px; padding-top: 24px; padding-bottom: 16px; color: #181A1F"><span style="font-weight: 700;">' + comment.user + ' </span>');
template.print('<span style="font-weight: 400;">left a comment on </span>');
template.print('<span style="font-weight: 700;">${number}:</span></div>');
template.print('<span style="font-weight: 600;color: #181A1F">' + comment.val.replace('[code]','').replace('[/code]','') + '</span>');
replace them with empty space
Please mark my answer as helpful/correct if it resolves your query.
Regards,
Chaitanya
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-30-2025 11:22 AM
try this
var notificationUtil = new IncidentNotificationUtil();
var comment = notificationUtil.getLatestCommentOrWorkNotes(current.getTableName(), current.getUniqueValue(), 'comments');
template.print('<div style="text-align: center; line-height: 36px; padding-bottom: 24px; border-bottom: 1px solid #DADDE2;"><span style="font-size: 24px; font-weight: 600; color: #181A1f;">' + comment.user + ' added a comment to Requested Item</span></div>');
template.print('<div style="font-size: 16px; padding-top: 24px; padding-bottom: 16px; color: #181A1F"><span style="font-weight: 700;">' + comment.user + ' </span>');
template.print('<span style="font-weight: 400;">left a comment on </span>');
template.print('<span style="font-weight: 700;">${number}:</span></div>');
template.print('<span style="font-weight: 600;color: #181A1F">' + comment.val.replace('[code]','').replace('[/code]','') + '</span>');
replace them with empty space
Please mark my answer as helpful/correct if it resolves your query.
Regards,
Chaitanya