DonkeyBot
08/05/2021, 7:37 AMMike Robbins
08/05/2021, 3:29 PM// Map subsidiary id to email template id
var emailTemplates = {
1: 101,
2: 102,
3: 103
};
var subsidiaryId = record.getValue({ fieldId: 'subsidiary' });
// Get the template for this subsidiary, default to 105 if no template is specified.
var templateId = emailTemplates[subsidiaryId] || 105;