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!
Don’t miss your chance to meet our SuiteGurus—NetSuite Support professionals and subject matter experts with extensive experience in select product areas, including OneWorld, Advanced & Basic Accounting, Supply Chain Management, Receivables & Payables, CRM, Account Administration, and the SuiteCloud Platform. Full Conference attendees can prebook exclusive 30-minute one-on-one sessions for your product questions.
Spots are limited! Register through your Agenda Builder and find SuiteGuru under Agenda Enhancements.
Detecting Sales Rep field changed in Before Submit
I've trying to find a way to detect a change in the Sales Rep field in a Before Submit script. This seems straight forward, but we are using Sales Teams. Specifically, I'd like to know the primary sales rep before and after the submit.
I tried variations of the following but it doesn't seem to work:
var oldRecord = nlapiGetOldRecord();
var newRecord = nlapiGetNewRecord();
var oldSalesRep = oldRecord.getFieldValue('salesrep');
var newSalesRep = newRecord.getFieldValue('salesrep');
No matter what I do, the old and new sales rep vars are always the same value. Is this a bug, as designed, or otherwise. Also, are there other ways of getting the old and new value for a Primary Sales Rep on a Customer record.