我正在编写一个套件脚本以将订单详细信息发送到客户电子邮件地址。
是否可以通过 scriptContext 或类似方法获取销售订单 ID?
我的功能在提交后在销售订单上运行。
function afterSubmit(scriptContext){
soid = scriptContext.soid; //<--trying to get the sales order id
}
我正在编写一个套件脚本以将订单详细信息发送到客户电子邮件地址。
是否可以通过 scriptContext 或类似方法获取销售订单 ID?
我的功能在提交后在销售订单上运行。
function afterSubmit(scriptContext){
soid = scriptContext.soid; //<--trying to get the sales order id
}
在 afterSubmit 中,您可以使用scriptContext.newRecord.id
.
请参阅afterSubmit
此处的文档:https ://system.netsuite.com/app/help/helpcenter.nl?fid=section_4407992281.html
和record.Record
对象成员文档: https ://system.netsuite.com/app/help/helpcenter.nl?fid=section_4267255811.html#bridgehead_4273190849