Skip to main content

Stock history

One product's page of every movement in and out of stock, with five summary tiles above it. It answers "where did this stock go?"

Who uses it​

  • Supplier staff with read access to products. Click a product's Stock figure, or use Manage Stock → View Stock History.

How it works​

Tiles. Pick a date range. The tiles read:

TileMeans
InventoryStock on hand now. The date range does not change it
PurchasesStock received from vendors minus purchase returns, with the average cost per unit
SalesStock sold to customers before returns, with the average selling price per unit
Gross ProfitSales revenue minus cost of goods sold, net of reshelved returns, with the margin
Return RateQuantity reshelved after customer returns as a share of quantity sold. Discarded goods do not count

Log. Each row has a Date, Type, Customer/Vendor, Invoice, QTY, Weight, Unit Price and Note. The footer says "Showing 25 of 140 entries".

Type filter. Choose which movements to show; All is the default, and the filter keeps your choice in the page address.

TypeDirectionComes from
SalesOutA sale order holding stock
Sales ReturnsInGoods reshelved from a return
PurchasesInA delivered purchase order
Purchase ReturnsOutGoods returned to a vendor
Stock InInStock In by hand
Stock OutOutStock Out by hand

Sales and Sales Returns also include movements caused by editing, confirming, canceling or deleting an order. See Stock from orders.

Sorting​

Every sortable column puts rows with a value first. A row with no value in that column, such as a blank Note, is always last in both directions; a weight of 0 counts as a value. Rows that tie, or are both empty, show the newest first.

Where it shows up​

The product's stock history page, opened from the Products list.

Permissions​

Products: read access.

Specs​

stock-history-sort.feature
# prefix: SHS
Feature: Stock history sorting
Every sortable column of a product's stock history orders the rows that have a value.
Rows with nothing in that column never decide the order: they always come last.

Rule: Empty values sort last in both directions

Scenario: SHS-001 a row with no note sorts last
Given a product whose stock history has two rows with notes and one without
When the supplier sorts the Note column ascending
Then the row without a note is last
When the supplier sorts the Note column descending
Then the row without a note is still last

Scenario: SHS-002 a blank note counts as no note
Given a stock history row whose note is only spaces
When the supplier sorts the Note column in either direction
Then that row is last

Scenario: SHS-003 a row with no weight sorts after every weighed row, and a weight of 0 is a weight
Given a stock history with weighed rows, a row weighing 0 and a row with no weight
When the supplier sorts the weight column in either direction
Then the row with no weight is last
And the row weighing 0 sorts among the weighed rows

Rule: Ties keep the newest movement first

Scenario: SHS-004 rows with equal or empty values are ordered newest first
Given several stock history rows with the same quantity, and several with none
When the supplier sorts the quantity column in either direction
Then within each group the most recent row comes first

Known limitations​

  • The log is a record: rows cannot be edited or deleted from here.

FAQ​

Inventory says 12 but the date range shows less. Why? Inventory is the count now; the other tiles cover only the dates you picked.

An order I edited has several rows. Why? Each save writes the difference as its own entry.