Hello - have a SS 2.x map/reduce script that I've ...
# suitescript
s
Hello - have a SS 2.x map/reduce script that I've written. We have a custom transaction type in our instance for consolidated invoices, and each line is made up of underlying invoices. We have custom currency fields that we are leveraging, and so the goal is to keep the native total (header level) and native amount (line level) at $0, since this is a consolidated invoice, is non-posting, and want to avoid GL impact. When I attempt to set the value to $0 as shown below
Copy code
ciRecord.setCurrentSublistValue({sublistId : 'line', fieldId : 'amount', value : 0.0});
I receive the following error message... Value 0.0 outside of valid min/max range for field amount For additional context, this is a rewrite of the original process and SS 1.0 that created these consolidated invoices via scheduled script, and was able to set the amount line item field to $0. Anyone have an idea of how I can get around this and set the value to $0. I'm able to edit the transaction after it has been created, through the UI and set the value to $0
c
There was a weird bug a long time ago that wouldn't let you set 0 and you'd get an error like this. But, if you used a super small non-zero number like .00000001 it worked. I'm just curious if that still works on this.
s
Right on - I'll give that a try
@creece you my friend are awesome - I set the amount to 0.000000001 and it worked.. cheers🍻
🍻 1