MGCLatticeSalesOrderCaptureService.createSalesOrder
Creates a sales order (SalesType::Sales) for a customer with one or more lines, via the AxSalesTable / AxSalesLine business-document framework so the header and lines are defaulted and validated the standard way (NOT raw table inserts). Optionally honors a caller-supplied SalesOrderId and order currency. Each line supplies ItemId, Qty (required; a line without a quantity is refused), and optionally UnitId, UnitPrice, and a site/warehouse (or a pre-resolved InventDimId). The created order number is returned as DocumentId and PostedDocumentId. Idempotent by RequestId: a duplicate replays the original created order and never creates a second order. The operation has no preview: PreviewMode set is refused.
- HTTP method:
POST - Route:
/api/services/MGCLatticeAccountsReceivableServiceGroup/MGCLatticeSalesOrderCaptureService/createSalesOrder - Service class:
MGCLatticeSalesOrderCaptureService
Parameters
| Name | Type | Optional | Description |
|---|---|---|---|
_request | MGCLatticeCreateSalesOrderRequestContract | No | Request with CustAccount, optional CurrencyCode/SalesOrderId, and the order lines. |
Returns
MGCLatticeOrderOperationResponseContract
An MGCLatticeOrderOperationResponseContract carrying the created SalesId, or a failure.
Security
- Requires privilege
MGCLatticeSalesOrderCaptureServiceMaintain