v1.24.0: returns, RMA, and exchanges
"Returns, RMA, and exchanges" release. The post-fulfillment arc, end to end -- and the release that completes the fork-to-OSS migration.
A sale can now spawn typed child orders: a replacement or exchange outbound, a goods-in RMA to receive returned stock against, and a credit-memo refund -- each numbered off and linked to its original.
Mobile. Zero mobile/ diffs on this release. The current mobile build (version 1.19.0, versionCode 9) remains current; no new APK for v1.24.0.
Added
- Post-fulfillment order types and numbering (#407):
sales_orders.order_typeadmitsreplacement/exchange/returnalongsidesale/refund/backorder. A post-fulfillment child takes a readable so_number off its original (<orig>-REPLACEMENT/-EXCHANGE/-RMA/-REFUND, suffixed-Nfor repeats) and links back viaparent_so_idand, per line,original_so_line_id. - RMA goods-in (#407):
create_rmamints the return SO;POST /api/admin/sales-orders/<so_id>/receive-returnbooks a line into a disposition bin (a sellable bin restocks, a defective bin quarantines), advances the RMA status, and emitsreturn.received/1. The receive is idempotent on a handheld-supplied key. A tabbed Returns admin page (RMA + Refunds) fronts the flow. - POS returns (#407): POS checkout in replacement / exchange mode mints the typed child off an attached original (an exchange also auto-creates the
<orig>-RMAfor the returned goods); refund accepts a line subset for partial refunds (a full refund still cancels the original); a POS sales-order lookup and a reference-order ingest (for an original that lives only in an upstream source system) support the attach-order flow.
Migrations
- 070 (#407) --
sales_orders.order_typeCHECK expands to includereplacement,exchange,return. - 071 (#407) --
sales_order_lines.original_so_line_idlinks a post-fulfillment child line to the original line it derives from (NULL on ordinary lines). - 072 (#407) --
item_receiptscan book against a return SO (nullableso_id/so_line_id);sales_order_lines.quantity_receivedtracks per-line return receipts. - 073 (#407) --
sales_orders.so_numberwidens toVARCHAR(128)so the longest suffixed child numbers fit.