- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-14-2025 09:14 AM
Hi,
How do I send notification to sys_updated_by.manager from business rule and notification by using gs.eventQueue? Below code doesn't work.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-14-2025 09:24 AM
Hi @dhara kacha ,
sys_update_by is not a reference field you cannot dot-walk as it is a string field
so remove manager from current.sys_updated_by.manager and try
if you want to include manager of sys_updated_by
try this
var managerID = null;
var userGr = new GlideRecord('sys_user');
if(userGr.get('user_name',current.sys_updated_by)){
managerID = userGr.getValue('manager');
}
gs.eventQueue("Redflag.incident.notification", current, managerID, null);
else
just use
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-14-2025 09:24 AM
Hi @dhara kacha ,
sys_update_by is not a reference field you cannot dot-walk as it is a string field
so remove manager from current.sys_updated_by.manager and try
if you want to include manager of sys_updated_by
try this
var managerID = null;
var userGr = new GlideRecord('sys_user');
if(userGr.get('user_name',current.sys_updated_by)){
managerID = userGr.getValue('manager');
}
gs.eventQueue("Redflag.incident.notification", current, managerID, null);
else
just use
Please mark my answer as helpful/correct if it resolves your query.
Regards,
Chaitanya