Boxes of blisters: modelling units with a real client
I spent a day designing a model for nested packaging. Then I spent an hour with the clinic team, and I deleted most of it.
ICS Stock tracks consumables for a dental clinic. The first thing I got wrong was assuming I knew what a "unit" was.
Two kinds of unit
The clinic talks about stock in two ways, and they are not the same thing:
- Purchase units are how things arrive: a unit, a box, a pack.
- Handout units are how things leave: a blister, a syringe, a roll, a millilitre.
A supplier invoice says "3 boxes". A dentist takes 2 blisters out of one. If the system only knows about boxes, it can't say how much is left after that.
One base unit
The decision that simplified everything: every stock figure is stored in a single base unit, the thing that leaves the shelf. Boxes are a way to enter and display a quantity, never stored stock.
Receive 3 boxes of 10 blisters and the batch holds 30. Hand out 2 and it holds 28. The screen can still show "2 boxes and 8 blisters" when that is friendlier, but that is arithmetic on the way out. Some products are measured in mL and arrive in 5 L packs, which is the same model with a bigger factor.
Keeping a single base unit means the stock total is a plain sum, with no conversions to get wrong when you add up movements, reserve for a transfer or export a report.
The design I threw away
Some products come as a box that holds several boxes, each holding several blisters. My draft handled this with nested packaging: levels of containers, each with its own count, and a conversion chain between them.
It was correct and it was heavy. Worse, the numbers at each level change with every order, because suppliers repackage. I would have been building a model for variation that the clinic didn't need.
I put the question to the clinic directly. Their answer: when a box of boxes arrives, they open the outer one. Nobody tracks it. So a box of boxes is simply entered as N boxes, and the outer layer never enters the system.
That one meeting removed a table, a conversion chain and a screen.
The bulk product problem
Some products can't be counted at all. A tub of vaseline is used until it's empty, and nobody is going to weigh it.
Forcing a number on it would put fake data into the stock figures. Instead a delivery is recorded as a movement with a quantity of zero: the log shows that it arrived and when, but no count is invented. It is a trail without a pretend measurement.
What I took from it
- Ask what people do, not what they have. The clinic's actual process was simpler than the packaging in front of them.
- Name your units. "Unit" meant three different things in my first draft.
- Store the one thing that's true. Everything else, boxes included, is presentation.
The design spec for this feature had a before and an after. The after was shorter, and the client had written half of it.