Discussions
Read on for the latest updates including:
• Agenda Builder launch
• SuiteWorld On Air registration
• New NetSuite Prompt Studio Contest
• And more!
Check out this thread to learn more!
add a button on view mode depending on record type
Hi,
I am new to SS2,and stuck at checking the record type and record id of a record on view mode (via user event).
I am creating a ue script that would add a button on view mode, and different label depending on what is the current record type.
so in ss1 it would be something like:
if(type == 'view'){
if(nlapiGetRecordType() == 'salesorder'){
//add button
form.addButton('cuspage_btn1','SO','printso()');
//load record
var rec =nlapiLoadRecord(nlapiGetRecordType(),nlapiGetRecordId());
.....
} else if (nlapiGetRecordType() == 'invoice'){
form.addButton('cuspage_btn1','INV','printinv()');
......
}
}
Im having a hard time figuring out the equivalent module/method for nlapiLoadRecord for ue script