Saleoff (Saleout) / Abverkauf
Describes how items are sold off stock, typically limited in the amount for a given delivery day.
We distinguish several types of sale-off in the backend, depending on the scheduled vendor deliveries and stock left. For the POS, it boils down on:
- a how many items are available for a given delivery day
- b if items can be offered, even if the item/tour related orderstop for the item is already over >item.saleLeft can be offered.
item.saleType:
- 0: no saleout: nolimits, just consider other constraits like items/tour specific order stops.
- 1: regular (forever) saleout. With this type, items.saleLeft tells whats left to be sold. Dont offer more item than available. In the standard shop implementation, no more than these items can be put into the cart.
- 2: periodic sale; for each delivery day, effect to the POS is like type 1
- 3:packing day, after osh: you may offer item.saleLeft items even if the item exceeded its orderStop (which is before the orders overall order stop)
- 4 periodic, but after osh: if an item is after its (specific) order stop, you may still offer item.saleLeft
api
These values can be found in Items. You should poll these item values frequently, if a saletype > 0 is given.
It may happen (in usually rare cases), that submitting an order leads to a clash error response, as other customer(s) did buy all available items shortly before. Plan to catch this circumstance.