BR notification on Visual task boards - new label added
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-31-2025 12:56 PM
Hi, I am trying to trigger an event inside of a BR that will send a notification to the task primary owner if a label/tag containing "planned" is added to a VTB card on Visual Task Board. The event/email is not getting triggered whenever I make a change on the VTB. Could anyone review the following:
I set up a BR to run on vtb_card table, After, insert
My event and the notification are also running on vtb_card and the notification will get sent to the task.primary_contact.
Business Rule:
Condition: Board = Team Name
(function executeRule(current, previous /*null when async*/ ) {
var labelEntryGR = new GlideRecord('label_entry');
labelEntryGR.addQuery('table', 'vtb_card');
labelEntryGR.addQuery('table_key', current.sys_id);
labelEntryGR.query();
while (labelEntryGR.next()) {
var labelGR = new GlideRecord('label');
if (labelGR.get(labelEntryGR.label.sys_id)) {
if (labelGR.name.indexOf('planned') !== -1) {
var cardGR = new GlideRecord('vtb_card');
if (cardGR.get(labelEntryGR.table_key)) {
gs.eventQueue('myevent, cardGR);
}
}
}
}
})(current, previous);
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-31-2025 04:41 PM
I would recommend opening the module Debug Business Rules (Detailed) to see where exactly your BR is failing