Commit Graph

5 Commits

Author SHA1 Message Date
Developer
f5d520181e feat(admin/teams): add truck operational status badge
- Add truck_is_full computed field to CollectionTeamResource
  - true when current trip load >= truck capacity_kg
  - true when trip status is at_dumpsite (driver rerouted to dumpsite)
  - uses whenLoaded() guard, safe when currentTrip not eager-loaded

- Rework teams card badge layout (Admin UI)
  - H row: remove misleading 'Not Full' for standby teams; show Full/Incomplete for active only
  - Truck Load row: always rendered with 4 context-aware states
    - IDLE (standby teams)
    - READY (active, no current trip)
    - COLLECTING (active trip, under capacity)
    - TRUCK FULL (at capacity or at dumpsite)
2026-07-02 14:23:02 +08:00
Developer
a1470eb85e feat: implement team standby status, helper persistence, and store portal foundations 2026-07-02 12:03:50 +08:00
Developer
7dc074e3c3 Implement household, QR sale, team helpers assignment, and helper endpoints 2026-06-29 16:56:33 +08:00
77af5ca876 feat(web): wire admin UI for Modules 9-13
- Dumpsites + Routes: full create forms (boundary point list,
  click-to-add ordered stops with reorder controls)
- Trucks: list + create
- Teams: list + create with conflict detection (override checkbox)
- Trips: schedule + list + detail panel showing stops + timeline
- Partner Stores: list + create + Issue-Inventory action
- Reports: tabbed dashboard (daily collection, trip performance,
  store sales, compliance CSV export) + rebuild aggregations
- Sidebar: moves Teams/Trucks/Trips/Stores/Reports out of "Soon",
  reorganized groups
- Admin resources expose db_id alongside public uuid so admin forms
  can post integer FKs without a separate lookup endpoint

164 tests still passing.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-30 19:50:08 +08:00
15f9295d34 feat(backend): complete Module 9 (teams + trucks)
trucks (with optional last_known_coordinates POINT 4326),
collection_teams, team_members. Admin CRUD for both. TeamConflictDetector
flags double-assignment of driver/scanner/truck/helper across active
teams; override_conflicts: true bypasses for emergencies. Promotes
routes.default_team_id to a real FK now that collection_teams exists.

144 feature tests passing.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-30 02:48:40 +08:00