NS AdminA
12/03/2024, 7:51 AMCeligo AI
12/03/2024, 7:51 AMAI generated answer (using internal Slack threads):In SuiteScript 2.0, you can set additional recipients for a new message by manipulating the 'otherrecipientslist' sublist. Here is a sample script:
javascript
var rec = currentRecord.get();
rec.selectNewLine({
sublistId: 'otherrecipientslist'
})
rec.setCurrentSublistValue({
sublistId: 'otherrecipientslist',
fieldId: 'email',
value: '<mailto:example@mail.com|example@mail.com>'
})
rec.setCurrentSublistValue({
sublistId: 'otherrecipientslist',
fieldId: 'cc',
value: true
})
// Commit The Item
rec.commitLine({
"sublistId": "otherrecipientslist"
});
In this script, rec.selectNewLine({sublistId: 'otherrecipientslist'})
is used to select a new line in the 'otherrecipientslist' sublist. Then, rec.setCurrentSublistValue()
is used to set the 'email' and 'cc' fields of the current line. The 'cc' field is set to true
instead of 'T'. Finally, rec.commitLine({sublistId: 'otherrecipientslist'})
is used to commit the changes to the line.
******
Disclaimer:
This response was generated by an artificial intelligence assistant based on previous conversations from multiple Slack channels, and may contain inaccuracies or mistakes.
******Celigo AI
12/03/2024, 7:52 AMSlack thread 1: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.827518582
Slack thread 2: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.825102448
Slack thread 3: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.818250835
Celigo AI
12/03/2024, 7:52 AM