jen
04/12/2019, 4:05 PMjen
04/12/2019, 4:05 PMjen
04/12/2019, 4:16 PMOgabeg
04/12/2019, 4:27 PMOgabeg
04/12/2019, 4:28 PMParth M
04/12/2019, 5:40 PMLei
04/12/2019, 5:41 PMVtor
04/12/2019, 5:43 PMLei
04/12/2019, 5:44 PMKevinJ of Kansas
04/12/2019, 5:50 PMKevinJ of Kansas
04/12/2019, 5:50 PMKevinJ of Kansas
04/12/2019, 5:51 PMVtor
04/12/2019, 5:51 PMKevinJ of Kansas
04/12/2019, 5:53 PMKevinJ of Kansas
04/12/2019, 5:53 PMLei
04/12/2019, 5:53 PMKevinJ of Kansas
04/12/2019, 5:55 PMLei
04/12/2019, 5:57 PMKevinJ of Kansas
04/12/2019, 5:57 PMKevinJ of Kansas
04/12/2019, 5:58 PMOgabeg
04/12/2019, 6:12 PMmarkderrick
04/12/2019, 6:32 PMmarkus.99
04/12/2019, 6:56 PMfunction CS_PNRefUpdate(){
var pnref = nlapiGetFieldValue('custbody_pnref');
nlapiSetFieldValue('pnrefnum', pnref); }
Script is solely trying to get value of a custom field and update the pnref
field on the Cash Sale.
Issue I'm running into is that the workflow action script isn't updating the pnref
field and i'm getting this error: Credit Card Number or P/N Ref. has to be set to record external payment event.
So any help on what I could change to get this to work would be appreciated.KevinJ of Kansas
04/12/2019, 7:21 PMKevinJ of Kansas
04/12/2019, 7:23 PMmarkus.99
04/12/2019, 7:37 PMmarkus.99
04/12/2019, 7:56 PMmarkus.99
04/12/2019, 8:36 PMmarkus.99
04/12/2019, 8:37 PMfunction SO-to-CS(){
var id = nlapiGetFieldValue('id');
var pnref = nlapiGetFieldValue('custbody_pnref');
var date = new Date();
var csRec = nlapiTransformRecord('salesorder', id, 'cashsale', {recordmode: 'dynamic'});
csRec.setFieldValue('trandate', date);
csRec.setFieldValue('pnrefnum', pnref);
csRec.setFieldValue('ccapproved','T');
nlapiSubmitRecord(csRec);
}
Noel B
04/12/2019, 9:25 PM