Sales Orders#

A Sales Order (SO) is a customer’s commitment to buy — one or more lines of parts / assemblies at agreed prices and due dates. SOs feed MRP demand, drive WO creation for build-to-order lines, and terminate in Ship Bills / invoices.

Structure#

  • SOMAIN — header: customer, currency, terms, ship-to, status.
  • SODET — one line per part with quantity, unit price, and account defaults.
  • SODueDate — schedule rows if a line ships in multiple deliveries.
  • SalesPriceList — contracted prices used to default the line price.

Lifecycle#

  1. Draft / Open — created manually, from an upload, or from a customer PO.
  2. Released — visible to MRP as demand; WOs may be created against build-to-order lines.
  3. Partially shipped — one or more lines have ship activity.
  4. Fully shipped / Invoiced — closes automatically or on user action.
  5. Cancelled — allowed while no shipments have posted.

Business rules#

  • Pricing defaults from the customer’s SalesPriceList; the user can override with permission.
  • Changing customer or currency on an SO with any ship activity is blocked.
  • Cancelling a line with an open WO built against it must either close the WO or transfer its material.
  • Tax / freight are computed on the ship-bill, not the SO — the SO is the commitment, the ship-bill is the transaction.
  • Bulk / CSV import goes through SalesOrderUpload — errors are captured per line and shown before commit.

Where it lives#

LayerFile
ControllerSoMainController, SalesOrderUploadController
HelperMnxEFModel/Helper/Sales Order/SalesOrderBaseHelper.cs, SOMainHelper.cs, SODetailHelper.cs, SODueDateHelper.cs, SOPriceHelper.cs, SoSetupHelper.cs, SalesPriceHelper.cs
ImportMnxEFModel/Helper/SalesOrderUpload/
RelatedShip Bills & Invoicing, Customers, Work Orders