Skip to content

PATCH /oms/inbound-orders/(?P\d+)/items/(?P\d+)

OMS > oms.inbound-order

What it does

#^/oms/inbound-orders/(?P<id>\d+)/items/(?P<itemId>\d+)$# accepts PATCH and is declared in app/systems/OMS/inbound-order/api_routes.php:251 as a regex pattern.

The route handler delegates to purchase_order_post_handle(). That function is the owner of this behaviour; the route entry is only dispatch.

Call chain:

  1. → purchase_order_post_handle() — app/systems/OMS/inbound-order/purchase_order_write_helper.php:185
  2. ↳ order_basic_write_data() — app/systems/OMS/inbound-order/sales_order_write_helper.php:963
  3. ↳ order_assert_advanced_operations() — app/systems/OMS/inbound-order/sales_order_write_helper.php:794

Who calls it

No literal caller path was found in frontend/, public/ or new-system/. The endpoint may be called through a constructed path, a helper wrapper, or only by an external client. Treat the route table and owner function as the authority.

Input

Where Key
path id
path itemId
body APPLY_OPERATIONAL_STATUS
body BILLING_COMPANY_ID
body BOOKING_ID
body CARRIER_COMPANY_ID
body COMMERCIAL_ORDER_ID
body CONSIGNEE_COMPANY_ID
body CREDIT
body INGATE_TIME
body IN_TIME
body ITEMS
body LOAD_NUMBER
body OPERATIONAL_STATUS
body ORDER_DATE
body ORDER_NUMBER
body ORDER_STATUS
body ORDER_TYPE
body OUT_TIME
body PAYMENT_TERM
body PURCHASE_TYPE
body REFERENCE_NUMBER
body REMARK
body SHIPPER_COMPANY_ID
body TRUCKING_FEE

Request bodies must not use TYPE, ACTION or USERNAME as contract fields.

Output

Key
BILLING_COMPANY_ID
CARRIER_COMPANY_ID
CONSIGNEE_COMPANY_ID
SHIPPER_COMPANY_ID

Success is { "data": …, "requestId": "…" }. Failure is { "error": { "code", "message" }, "requestId": "…" }.

SQL executed

INSERT INTO T_LOAD ( CLIENT_ID, ORDER_DIRECTION, ORDER_CLASS, ORDER_STATUS, {$orderTypeColumn},

Data

Tables reached from the owner function:

  • T_LOAD

Access

  • module-gated on oms.inbound-order, so tenant module access applies