Stock from orders
An order that is on its way to the customer holds stock off the shelf. When the supplier records a return of goods the order never sold, the shelf follows what the supplier says happened to them: reshelved goods go back on the shelf, discarded goods do not.
Who uses it
- Supplier staff record an additional return on an order and choose Reshelve or Discard. They see the result in the product's stock and its inventory log.
- Restaurants are not affected: additional returns never change the invoice total.
How it works
- Stock only moves while the order holds it: Confirmed, Ready for delivery or Delivered. A Saved or Placed order moves nothing.
- Recording an additional return with Reshelve puts the quantity (and, for a catch-weight product, the weight) back on the shelf. Discard moves nothing.
- Editing the quantity, switching Reshelve to Discard, or removing the return moves only the difference.
- A product that is also a sold line on the order is netted into one movement per save.
- If the order was canceled after it held stock, the returned goods stay counted. If it was canceled while still Placed, nothing is counted.
Calculations
| Step | Shelf for product B |
|---|---|
| Starting stock | 10 |
| Return 2 of B, Reshelve | 12 |
| Change the quantity to 1 | 11 |
| Switch to Discard | 10 |
A catch-weight line re-weighed with the count unchanged moves the weight difference: 50 LB down to 48 LB puts 2 LB back; 48 LB up to 53 LB takes 5 LB off.
A product the order never sold is not on the invoice, so the shelf is the only place a reshelved return can show. Reshelved goods are on the shelf again; discarded goods never were.
Where it shows up
The product's stock and its inventory log, where the movement is labelled as a return.
Permissions
Anyone who can edit the order's returns can record additional returns; no extra permission is needed for the stock movement.
Decisions
- Reshelved additional returns move stock; discarded ones do not. The shelf follows what the supplier says happened to the goods. (#2390)
- A lighter re-weigh with the same count books stock in. It used to be booked as stock out. (#2390)
- Count and weight moving opposite ways write two entries. One entry has one direction. (#2390)
- Additional returns are not priced. They never reach a cost or sale average. (#2390)
Specs
# prefix: SAR
Feature: Stock from order returns
When a supplier records a return of a product the order never sold, the shelf follows
the supplier's choice: reshelved goods go back on the shelf, discarded goods do not.
A catch-weight product re-weighed on a confirmed order moves its weight in the right direction.
Rule: Stock moves only while the order holds stock
Scenario: SAR-001 reshelving an additional return puts it back on the shelf
Given a delivered order that sold 5 of product A
When the supplier returns 2 of product B, which the order never sold, and reshelves them
Then product B's stock rises by 2
And the stock history shows 2 of product B coming in as a return
Scenario: SAR-002 discarding an additional return moves no stock
Given a delivered order that sold 5 of product A
When the supplier returns 2 of product B and discards them
Then product B's stock is unchanged
And no stock history entry is written
Scenario: SAR-003 a returned catch-weight product brings its weight back
Given a delivered order that sold 5 of product A
When the supplier returns 2 boxes of catch-weight product B weighing 4.5 LB and reshelves them
Then product B's stock rises by 2 and its weight on hand rises by 4.5 LB
Scenario: SAR-004 editing or removing an additional return reverses the difference
Given a reshelved additional return of 2 of product B
When the supplier changes the quantity to 1
Then 1 of product B goes back out
When the supplier changes the return to discard
Then the remaining 1 of product B goes back out
When the supplier removes the return
Then product B's stock does not move again
Scenario: SAR-005 a product that is also a sold line nets into one movement
Given a delivered order that sold 5 of product A
When the supplier reshelves an additional return of 1 of product A while also editing its line
Then the stock history shows one entry for product A with the net difference
Scenario: SAR-006 an order that does not hold stock moves nothing until it does
Given a placed order with an additional return of 2 of product B
Then product B's stock is unchanged
When the supplier confirms the order
Then the shelf reflects the order once, including the return
Scenario: SAR-007 a canceled order keeps or drops the return by where it was canceled from
Given an order with a reshelved additional return
When it is canceled after it was confirmed
Then the returned goods stay counted
When it is canceled while still placed
Then nothing is counted
Rule: A catch-weight re-weigh moves weight in the right direction
Scenario: SAR-008 re-weighing a line lighter puts the difference back, heavier takes it off
Given a confirmed order with a catch-weight line of 5 boxes weighing 50 LB
When the supplier re-weighs the line to 48 LB with the count unchanged
Then 2 LB come back on the shelf
When the supplier re-weighs the line to 53 LB with the count unchanged
Then 5 LB go off the shelf
Scenario: SAR-010 count-only and same-direction changes write one entry, opposite directions write two
Given a confirmed order with a catch-weight line
When the supplier changes only the count, or the count and weight in the same direction
Then one stock history entry is written with that count and weight
When the count and weight move in opposite directions
Then the count and the weight are written as two entries
Known limitations
- Additional returns recorded before stock followed them have no stock entries and are not backfilled. Editing or removing one later takes stock off that was never put on.
- An order canceled while Placed never moves stock for a return recorded on it.
FAQ
I returned a product the order never sold and discarded it. Why did stock not change? Discarded goods never go back on the shelf. See How it works.
Why is the same product's movement one row when it is also on the order? Movements are netted by product on each save.