Skip to main content

Sales Orders

📄️Release Credit Hold

Releases a pending credit hold on a sales order. Credit-held orders sit in Reserved with `credit_hold_status: 'pending'`; releasing the hold records the releasing user and timestamp (`credit_hold_released_at`) and opens the order for fulfillment unless another hold still gates it — when the order is also reserved on a payment-pending hold it stays reserved, and the response message says so ('Credit hold released. The order remains reserved on a payment-pending hold.').

📄️Mark Sales Orders Shipped Before Tracking

Starts a background job that marks the selected sales orders as shipped before inventory tracking. For each eligible order, every open product line is credited as externally fulfilled (pre-tracked): no inventory movement is created and no inventory debt is recorded, reservations are released, open unsubmitted fulfillment orders are retired, and the order is closed as fulfilled. A note is added to each order. Ineligible orders are skipped and reported in the job results.

📄️Reverse Sales Order Fulfillment to Pre-Tracked

Repairs a double deduction: for an order placed before the inventory start date, a shipment recorded from the sales channel with a date on or after the start date is voided locally — its inventory movements are reversed and stock returns — while the sales channel's own fulfillment is kept. The same units are credited as externally fulfilled (pre-tracked) in the same transaction, so a later channel sync changes nothing. A note is added to the order.

📄️Replace Channel-Linked Sales Order Lines

Swaps the order lines linked to one sales channel line for another line of the same order, e.g. the bundle components a channel item was split into, replaced by the kit product that ships. The replacement line is linked to the channel line and keeps that link through channel re-syncs. Each replaced line is deleted, or, when a shipping provider has a record of it (a fulfillment order for it was submitted to, or voided at, a carrier), every remaining unit is cancelled and the line drops to a zero price, so it stays as history without counting toward the order total.

📄️Bulk Email Customers About Orders

Dispatches a tracked background job that emails customers about their selected sales orders. Multiple orders for the same customer (same store + email, case-insensitive) are grouped into a single email (Cin7 Omni model). Recipients without a resolvable email and opted-out customers are suppressed. The send is capped at `config('mail.bulk_sales_order_recipient_cap')` distinct recipients (default 5000); overflow recipients are reported via the job's `skipped_overflow` result and a warning log — never silently dropped. Every send is written to the order's activity log under one batch.

📄️List Order Shipments

Lists ALL shipments (SalesOrderFulfillments) for a sales order, used by the order's Fulfillment tab. Includes VOIDED shipments: a voided shipment carries a non-null `voided_at` (plus `void_reason` and `voided_by`) and `status=canceled` — it was reversed and its fulfillment order reopened, but is kept for history. The UI buckets voided shipments into a read-only 'Voided' filter and excludes them from the active lifecycle counts. Each shipment exposes its `fulfillment_lines`, warehouse, shipping method, tracking, and provider-sync timestamps.