Sales Returns & RMA
Manage customer return authorizations (RMA), restock returned inventory, and issue credit adjustments.
Routes:
/sales-returns /sales-returns/:id Sales Returns & RMA
The Sales Returns module manages Return Merchandise Authorizations (RMA). It coordinates returning goods back to warehouse stock, inspecting item condition, and issuing financial credit adjustments.
Return Lifecycle & Business Logic
stateDiagram-v2
[*] --> Draft : Create RMA
Draft --> Confirmed : Authorize RMA
Confirmed --> Processed : Receive, Restock & Credit
Confirmed --> Draft : Revise Lines
Draft --> Cancelled : Cancel
Confirmed --> Cancelled : Cancel
1. Invoicing Invariant & Quantity Validation
- Invoiced Precondition: Returns can only be initiated against Sales Orders in
Invoicedstate. - Return Ceiling: For each order line:
Attempting to authorize quantities above this boundary is strictly rejected.Maximum Returnable Quantity = Invoiced Quantity - Previously Processed Return Quantities
2. Credit Calculation & Restocking Fees
The system calculates aggregate return credit using line-level pricing from the original sales order:
Net Credit = Subtotal + Total Tax - Total Restocking Fees
- Line Pricing: Calculated via original line unit price, original line discount %, and current tax rate:
Line Net Amount = round2(Returned Quantity * Original Unit Price * (1 - Original Discount% / 100)) Line Tax Amount = round2(Line Net Amount * (Tax Rate% / 100)) - Resolution Differences:
- Refund: Line contributes to
SubtotalandTotal Tax, generating a linked Sales Credit Note. - Replacement: Generates 0.00 financial credit; triggers a replacement dispatch workflow.
- Refund: Line contributes to
- Restocking Fees: Deducted directly from gross credit (
Total Credit = Subtotal + Tax - Restocking Fees).
3. Physical Restocking & GL Postings
When warehouse staff mark an RMA as Processed:
- Physical Stock:
- Good Condition: Restocked into active pick/storage bins, increasing On Hand (OH) and Available stock.
- Damaged / Defective: Routed into a Quarantine Bin for inspection or vendor claim.
- General Ledger Journal Postings:
- Financial Credit:
Debit: Sales Returns / Revenue,Debit: Tax Liability,Credit: Accounts Receivable. - Inventory Restock:
Debit: Inventory Asset,Credit: Cost of Goods Sold (COGS).
- Financial Credit:
Step-by-Step Workflows
1. Authorizing a Return (RMA)
- Go to Sales → Sales Returns (
/sales-returns). - Click New Return and select the original Sales Order.
- Select line items and specify the Returned Quantity (must be
<= Invoiced Quantity). - Select the Return Reason and set the Resolution (
RefundorReplacement). - (Optional) Enter a Restocking Fee.
- Click Confirm Return to generate the official RMA document for the customer.
2. Receiving and Processing Goods
- When physical items arrive at the dock, open Receiving → Customer Returns.
- Inspect item condition and assign destination storage bins (or Quarantine bin if damaged).
- Click Process Return to update perpetual inventory counts and automatically post the Credit Note.
Field Reference
| Field | Description |
|---|---|
| Return Number | Unique RMA identifier (e.g. RMA-2026-00018). |
| Sales Order | Originating invoiced sales order reference. |
| Customer | Account returning the merchandise. |
| Returned Quantity | Authorized unit count (must be <= unreturned invoiced quantity). |
| Resolution | Action type: Refund (financial credit) or Replacement. |
| Return Reason | Quality or commercial reason code. |
| Restocking Fee | Deducted administrative or return handling charge. |
| Status | Stage (Draft, Confirmed, Processed, Cancelled). |
Field Reference & Data Dictionary
Key database fields, input parameters, and definitions associated with this workflow screen:
| Field / Parameter | Display Name | Description & Rules |
|---|---|---|
| return_number | Return Number | Unique return authorization identifier (e.g. RMA-2026-00018). |
| sales_order_id | Original Sales Order | Invoiced sales order against which items are being returned. |
| customer_id | Customer | Customer returning the goods, inherited from the originating sales order. |
| resolution | Return Resolution | Refund (generates credit note) vs Replacement (re-orders replacement items). |
| return_fee | Restocking Fee | Handling or restocking charge deducted from the customer's credit balance. |
| status | Return Status | Stage of the return (Draft, Confirmed, Processed, Cancelled). |