# 07 – Orders

Tested in the QA company (company admin) · Pages: Create Order, Order List, Pending, Dispatch (page + list), Tracing, Delivered, Cancel Orders, Claim/Dispute, Order RFQ List, Rate Matrix

## Works fine

- All ten pages open. **Create Order** saves ("Order created successfully!"); the Order ID is pre-filled (ORDER-001).
- **Dispatch** (carrier, equipment, currency, rate, truck/trailer unit) saves ("Order dispatched successfully!"); the **Dispatch List** shows Order Total 1,000 / Carrier Total 700 / Profit 300.
- **Order PDF, Rate Confirmation PDF and BOL** open as valid PDFs.
- **Tracing → Update Tracing:** Pending and Delivered (with a POD file) both save. The order moves to **Delivered Orders** with *Merged PDF / View POD*.
- **Repeat Order** opens a copy (new ID ORDER-002, PO and addresses copied) and saves.
- **Cancel Order from the Order List** (reason required) moves the order to **Cancel Orders**.

## Issues

| # | Sev | What the user experiences | Steps | Evidence |
|---|-----|---------------------------|-------|----------|
| O1 | **Medium** | **Cancel Order does nothing on the Pending Orders page.** The reason box closes, no message, and the order stays Pending (the page never passes the order to the cancel window; the Order List page does). | Pending Orders → Action → Cancel Order → enter reason → Cancel Order | `screens/order_cancel_dialog.png` |
| O2 | Medium | **Dispatch page asks for the carrier's drivers with an empty id** (a failed request `drivers-by-carrier/undefined` every time it opens), and choosing the carrier does not fill Contact / Driver. | Pending → Dispatch → choose the carrier | `screens/order_dispatch_dialog.png` |
| O3 | Medium | **Update Tracing: saving it empty just closes the window** – no "required" message and no result, although Tracing Status is marked required. | Tracing → Update Tracing → Update | – |
| O4 | Medium | **Unclear path from a won bid to an order.** After a quote is sent to the Load Board it leaves the *Approved Quotation* list (so no "Create Order" there) and neither Approved Bids nor the Load Board List offers "Create Order". Please confirm how an approved bid should become an order. | Approved quote → Send to Load Board → approve a bid | `screens/lb_approved_bids.png` |
| O5 | Low | No success message after cancelling an order. | Order List → Cancel Order | – |
| O6 | Low | **Pickup location is shown without the state** on Pending and Dispatch lists ("Cherrapunji,, India") but with it on the Order List ("Cherrapunji,ML, India"). | Compare the lists | `screens/order_pending.png` |
| O7 | Low | **Delivered / Cancel lists show "N/A"** for carrier and customer columns even though the order was dispatched to a carrier. | Delivered Orders | `screens/order_delivered.png` |
| O8 | Low | **Claim/Dispute page opens slowly** (about 13 s, even with no data). | Open Claim/Dispute Orders | – |
| O9 | Low | Script errors / missing script on Create Order, Tracing, Delivered, Cancel, Claim, Rate Matrix and Repeat Order pages (`addEventListener` of null, `classList`, `DataTable`, `discount is not defined`). | Open them, look at the console | – |

## Not tested (and why)

- Claim/Dispute flow, Customer Confirmation, Deposite Slip, Edit Order, Reset Dispatch, Quick Notes, Send Email from Tracing, drivers, the Order RFQ list (needs customer-created RFQs), Rate Matrix data.
- Delete (data kept on purpose).

## Test data left in the QA company (for Invoices etc.)

- **ORDER-001** – Delivered with a POD, carrier QA Carrier One, INR order 1,000 / carrier 700 / profit 300 → ready for customer and carrier invoices.
- **ORDER-002** – Cancelled (copy made with Repeat Order).
- Note: the Customer PO shows as "PO-QA-10011" because my own typing put an extra "1" there – not a bug.
