# sales-order-detail

## Overview

Displays full details of a sales order (受注), including all three status axes, line items, and order total. Available document actions depend on `orderStatus`.

## Screen Type

DetailView

### DetailView Details

#### Displayed Fields

- **Header**
  - Order — short id (sales orders have no human `docNumber` in this template)
  - Status — Badge
  - Customer — name + ID, links to the customer
  - Order Date
  - Requested Ship — shown only when set
  - Shipping Address
  - Total Amount
  - Hold Reason — shown only when set
  - Close Reason — shown only when set
- **Line Items** (table)
  - Item (name + SKU)
  - UoM
  - Ordered
  - Shipped
  - Unit Price
  - Subtotal (`quantity × unitPrice`)

#### Available Actions

| Action | Condition | Requires Input | Confirmation |
|---|---|---|---|
| Submit | `orderStatus` is DRAFT | — | dialog |
| Confirm | `orderStatus` is SUBMITTED | — | dialog |
| Reject | `orderStatus` is SUBMITTED | reason (String) | dialog |
| Create Outbound Shipment | `orderStatus` is CONFIRMED and fulfillment remains open | — | — |
| Close | order is closable | closeReason (String, optional) | dialog |
| Cancel | `orderStatus` is DRAFT, SUBMITTED, or CONFIRMED | — | dialog |
| Back | — | — | — |

**Create Outbound Shipment** is a shortcut to the [outbound-shipment-create-form](outbound-shipment-create-form.md) with this order pre-selected.

## Access Control

- [sales-rep](../actor/sales-rep.md)
- [approver](../actor/approver.md)
