Add physical dimensions to bin editor for correct aspect ratio

When de-perspectiving a bin photo taken at an angle, inferring the
output size from the quadrilateral shape squishes the result. Entering
real-world W×H (mm) lets the server use the correct aspect ratio,
scaled to the same resolution as the inferred size.

- Bin editor dialog: W×H number inputs, pre-filled from saved phys_w/phys_h
- PUT /api/bins/:id/corners: accepts optional phys_w/phys_h; when provided,
  derives bin_w/bin_h from the physical aspect ratio at equivalent area
- phys_w/phys_h stored on the bin record for re-use on next edit
- future-plans.md: bin types note (reusable dimensions per model)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-04-01 05:13:57 +00:00
parent 1ea14f8953
commit 320c6f1bd9
6 changed files with 60 additions and 6 deletions

View File

@@ -381,6 +381,16 @@ used/visited locations at the top so you can quickly re-select where you just we
Useful when processing a batch of components into the same storage location — you
shouldn't have to navigate the grid picker from scratch each time.
## Bins
### Bin types
Define reusable bin type records (e.g. "Sortimo L-Boxx insert small", "Wago 221
connector box") that store physical dimensions (mm), and optionally a default
compartment layout. When creating or editing a bin, the user picks a type and the
dimensions are pre-filled — no need to re-enter for every bin of the same model.
This also enables filtering/grouping bins by type, and makes it easy to re-process
all bins of a type if the corner algorithm improves.
## Grids
### Grid view layers