feat(wms): peso/volumen del material + computeLoad (Inc 1 vehículos como almacén móvil)#411
Merged
Conversation
…umeM3, base defaultUnit) — Inc 1 vehículos
…exclusión de personal y flags por dimensión (Inc 1 vehículos)
…en árboles de containers (Inc 1 vehículos)
…n no las persiste) — Inc 1 vehículos
|
The latest updates on your projects. Learn more about Vercel for GitHub. 1 Skipped Deployment
|
…enga bruto declarado + preconditions Review de la PR: el guard de addContainer se saltaba las líneas de un container con ambas dimensiones declaradas, perdiendo el personal (nature=human) de ese subárbol — el personal no es carga y debe reportarse siempre. Se recorren líneas e hijos incondicionalmente (el peso/volumen sigue cortado por el bruto). Además: lines readonly (consistencia con looseLines) y preconditions documentadas (quantity finita/≥0 y bosque acíclico, garantizadas por el llamador).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #410 · Incremento 1 del EPIC #409 (vehículos como almacén móvil, WMS-first para Protección Civil). Foundation: toda carga pasa a ser calculable en peso y volumen.
Qué incluye
Supply.unitWeightKg/unitVolumeM3(nullable, basedefaultUnit, >0 validado) + mutador inmutablesetUnitMeasures. Patrón exacto denature/externalCodes.computeLoad(servicio puro eninventory, formas estructurales — no acopla módulos — + port de lookup síncrono(supplyId) → info | null):defaultUnit→ desconocido (no multiplica).nature=humanexcluido del peso/volumen (reportado enpersonnel).weightComplete/volumeComplete/complete+unknowns[]con dimensión y motivo — un total incompleto es un límite inferior, nunca un dato falso.null(su persistencia llega cuando el host adopte la feature; frontera 1:1, sin migración ni cambio de API). Detectado con typecheck limpio (la caché incremental denest buildlo enmascaraba en local).Verificación (local)
warehouse-core build + 175 tests (158→175: 5 de medidas + 12 de computeLoad) · api build + tsc limpio sin caché (0 errores) · eslint (0) · prettier api y packages · api-client + web build · frozen-lockfile — todo verde. TDD estricto (test-fail-first en cada tarea).
Spec:
docs/superpowers/specs/2026-07-13-vehiculos-almacen-movil-design.md§2 · Plan:docs/superpowers/plans/2026-07-13-vehiculos-inc1-peso-volumen.md.