在客户端脚本中执行命令后,如何重定向到记录类型。更好地解释一下,我在客户端脚本中,单击按钮后,会在另一种记录类型中生成一条新记录,我希望被重定向到那里。
谢谢
我需要在执行过程后离开此页面,并被重定向到我刚刚创建的记录
var newType = <NetSuite ID of record type>;
// making new record code
var newId = newRecord.save();
// performing the procedures
// Requires the N/url module
var output = url.resolveRecord({
recordType: newType,
recordId: newId,
isEditMode: true
});
window.location.replace(output);