Bruce Backman
04/21/2025, 4:51 PMCeligo AI
04/21/2025, 4:51 PMAI generated answer (using internal Slack threads):To move sales order items from backorder to committed status via SuiteScript, you can modify the "commit" column at the line level of the sales order. This can be done by setting the "commit" column to either "do not commit", "commit available", or "commit complete" depending on your requirements. Here is a simple example of how you can do this:
javascript
var salesOrderRecord = nlapiLoadRecord('salesorder', salesOrderId);
var lineItemCount = salesOrderRecord.getLineItemCount('item');
for (var i = 1; i <= lineItemCount; i++) {
salesOrderRecord.setLineItemValue('item', 'commit', i, 'commit complete');
}
nlapiSubmitRecord(salesOrderRecord);
In this example, we're loading a sales order record, iterating over each line item, and setting the "commit" column to "commit complete". This will move the items from backorder to committed status.
Please note that this is a simplified example and may not cover all scenarios. You may need to add additional logic to handle your specific use case.
******
Disclaimer:
This response was generated by an artificial intelligence assistant based on previous conversations from multiple Slack channels, and may contain inaccuracies or mistakes.
******Celigo AI
04/21/2025, 4:52 PMSlack thread 1: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.834986329
Slack thread 2: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.829318643
Slack thread 3: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.829236448
Celigo AI
04/21/2025, 4:52 PM