Disable a certain Notification for a entire group
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-11-2025 08:35 AM - edited 03-11-2025 08:48 AM
I want to block some Notification to be sent to certain assigment groups, the assigment group has a group mailbox.
For example, a assigment group dont want to get the "There is a new WorkNote" Notification.
There is the table cmn_notif_message where i could define a notification and a group, but this is not working.
How can I achive this ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-12-2025 03:44 AM
Hi @Chaitanya ILCR ,
this only works with User but not with entire groups.
Can you perhaps tell me what i do wrong ? This is my config.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-12-2025 04:06 AM - edited 03-12-2025 04:11 AM
Hi @Cedric J ,
1.May be the group's email field is empty.
2. May be Group's include members flag is set to true.
you can create a BR or Flow on sys_gr_member table with with condition as group "is one of" one of your group for which the notifications should be disabled and create a record in
with script
(function executeRule(current, previous /*null when async*/ ) {
var notificationList = ['8d692961d72322005aed4ebfae6103f5','8cfda33683f11610c4d11a30ceaad30d']; //array of notifications
var notifPrefGr = new GlideRecord('sys_recipient_notif_preference');
notificationList.forEach(function(item) {
notifPrefGr.newRecord();
notifPrefGr.notification_table = 'sysevent_email_action';
notifPrefGr.recipient_table = 'sys_user';
notifPrefGr.recipient = current.getValue('user');
notifPrefGr.notification = item; //sysid of the notification
notifPrefGr.send = false;
notifPrefGr.insert();
});
})(current, previous);
this way for each user whoever gets added to those group those listed notifications will be disabled as soon as they are part of listed groups.
And fix script for the existing users.
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
03-13-2025 12:06 AM
Hi @Chaitanya ILCR ,
that would be a good idea for all the users in groups. But for my use case there is a group email set in the assignment group. And that will not work.
Do you have any other idea for a group with group email ?