I filed this as a support case/defect, but didn't get a useful answer there, so I'm trying the forums. For reference sake, case 1387740 and defect 207916.
I am attempting to add lines on a rev rec schedule using SuiteScript. At this point, I am attempting proof-of-concept scripts in the sandbox debugger.
Through the UI, I can add a new line to an RRS with amount zero. I tried the following code, but no line got added to the RRS.
-------------
var rrs = nlapiLoadRecord('revrecschedule', 7491);
rrs.selectNewLineItem('recurrence');
rrs.setCurrentLineItemValue('recurrence','incomeaccount','182');
rrs.setCurrentLineItemValue('recurrence','defrevaccount','316');
rrs.setCurrentLineItemValue('recurrence','recamount',0);
rrs.setCurrentLineItemValue('recurrence','postingperiod','75');
rrs.commitLineItem('recurrence');
nlapiSubmitRecord(rrs);
-------------
This issue renders the new revenue recognition scripting feature completely useless.
The support rep claims that it works on a clean test account, but it clearly doesn't work on my account. Any ideas?