ANS-0975 · SUITESCRIPT DEVELOPMENT
Why NetSuite Recalculates Line Amounts from Sales Order to Invoice?
Understand how NetSuite's record transformation process calculates line item totals on invoices based on sales order quantities and unit prices.
Short answer
NetSuite's `record.transform` function recalculates invoice line amounts from a sales order using quantity and unit price, rather than directly transferring pre-calculated totals. To ensure specific amounts are carried over, explicitly push the desired amounts from the sales order to the invoice during the transformation process.
Scenario
When transforming a Sales Order into an Invoice in NetSuite using SuiteScript, users may observe that the line item amounts on the newly created invoice do not directly reflect the pre-calculated amounts from the original Sales Order. Instead, the system appears to recalculate these amounts based on the quantity and unit price of each line item.
Solution
When transforming a Sales Order (SO) to an Invoice using the record.transform function in SuiteScript, NetSuite's default behavior is to recalculate the line item amounts on the Invoice. This recalculation is typically based on the quantity multiplied by the unit price specified on the original Sales Order, rather than directly carrying over the pre-calculated line amounts. To ensure that specific line amounts from the Sales Order are accurately reflected on the Invoice, it is necessary to explicitly push these amounts to the invoice record during the transformation process.
Expert NetSuite Support
Need help with this NetSuite issue?
SuiteScript Development consulting and configuration support
