Commit Graph

1198 Commits

Author SHA1 Message Date
Nathnael
318af79962 feat: setup posthog 2026-07-16 08:52:29 +00:00
Nathnael
5f6d8f9294 fix: cache invalidation 2026-07-16 07:17:22 +00:00
marshal
50d5ce5ad9 Merge pull request #721 from Tria-plc/freight_feature/usermanagement
fix issue
2026-07-16 04:06:52 +03:00
Marshal
fe29b38377 fix issue 2026-07-16 01:05:57 +00:00
marshal
ea22f38adf Merge pull request #720 from Tria-plc/freight_feature/usermanagement
fix issue
2026-07-16 03:34:14 +03:00
Marshal
41fe04652f fix issue 2026-07-16 00:33:31 +00:00
marshal
67bc835458 Merge pull request #719 from Tria-plc/freight_feature/usermanagement
implement empty-container return service: add return quantity handlin…
2026-07-16 02:06:08 +03:00
Marshal
234a74e812 implement empty-container return service: add return quantity handling, update related DTOs, services, and UI components 2026-07-15 22:48:04 +00:00
marshal
e3fccbd24d Merge pull request #717 from Tria-plc/freight_feature/usermanagement
Freight feature/usermanagement
2026-07-15 23:18:55 +03:00
Marshal
fc44eee25e implement update train details feature: add DTO, service method, and UI modal for editing train name and run numbers 2026-07-15 20:14:39 +00:00
Marshal
d7d9db9c3a changes 2026-07-15 14:27:00 +00:00
Hagernesh
ac90b04be0 feat(warehouse): P2 dashboard — gate/dock throughput + live auto-refresh
- gateStats(): items cleared through the gate today, average arrival→gate
  turnaround (hours, 30d), and clearances per hour over the last 24h → new
  GateThroughputCard in the dashboard Performance section.
- Live board: every dashboard query (dashboard, ops, throughput, dwell, cycle,
  on-time, zone occupancy, accrual, gate) now auto-refreshes on a 60s interval,
  with a "Live" indicator in the header.

New endpoint GET /warehouse-inventory/gate-stats (guarded). Deferred (need
upstream data): capacity forecast, labour productivity, WebSocket push, yard map.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-15 14:26:02 +00:00
Hagernesh
fc4aadbc57 feat(warehouse): P1 dashboard analytics — dwell/aging, cycle-time + on-time, live deltas
Adds the operational-performance layer to the warehouse cockpit:

- Dwell time & aging: dwellStats() (avg + 0-3/4-7/8-14/15+ buckets over
  in-warehouse items) → DwellAgingCard histogram.
- Cycle time & on-time: cycleStats() (arrived→ready→loaded→dispatched stage
  averages + dock-to-dispatch) and onTimeDispatchStats() (share of items that
  left before their storage free-days expired, resolved via the fee engine's
  own rule matching) → CycleTimeCard.
- Live tiles: opsStats() now returns receivedYesterday; KpiStrip renders an
  optional ▲/▼ delta, and the ops strip shows received-today vs yesterday.

New endpoints: GET /warehouse-inventory/{dwell-stats,cycle-stats} and
/warehouse-fees/on-time-dispatch (all guarded). New "Performance" section on
WarehouseDashboardPage. On-time reads N/A when there is no sample / no active
storage rule.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-15 13:55:39 +00:00
marshal
6391ba837a Merge pull request #707 from Tria-plc/freight_feature/usermanagement
changes
2026-07-15 16:30:28 +03:00
Marshal
19c9da28ae changes 2026-07-15 13:29:01 +00:00
Hagernesh
2e22b72e27 feat(warehouse): assemble dashboard cockpit + server-side throughput series
- WarehouseDashboardPage now composes the ops KPI strip, lifecycle cards, flow
  charts, zone-occupancy heatmap and demurrage/accrual exceptions into one
  control-tower view; drop the redundant lifecycle donut.
- New GET /warehouse-inventory/throughput (date_trunc time series) replaces the
  client-side buildTrend that downloaded the entire inventory list to bucket it.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-15 12:27:53 +00:00
marshal
7700aa6358 Merge pull request #701 from Tria-plc/freight_feature/usermanagement
Freight feature/usermanagement
2026-07-15 13:32:37 +03:00
Marshal
c71a0043d6 implement wagon maintenance feature: add functionality to detach wagons and move them to maintenance status 2026-07-15 10:32:09 +00:00
Marshal
11771e5f92 remove reopen delay minutes from global rules and update related types
- Removed the  field from  and related components.
- Updated  to reflect the removal of the reopen delay input field.
- Modified  to include new train number fields:  and .
- Added  interface to manage active schedules with trade direction.
- Introduced  interface to track wagon shortages in bookings.
- Updated  logic to ensure consistent UI state representation.
- Created migrations to drop the  column and add  and  columns to the  table.
- Added tests for the new booking window display logic and wagon planning functionality.
2026-07-15 09:13:02 +00:00
Hagernesh
fd4c4d630f fix(warehouse): disable Receive-At-Warehouse once booking is received
The Warehouse Information card kept the receive button active after the booking
already had an inventory record. Disable it (relabel "Received At Warehouse",
add a tooltip) when an inventory item exists.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-15 07:54:23 +00:00
Hagernesh
b71a53c4a9 fix(warehouse): show booking reference instead of UUID in inventory table
The inventory table's Booking column rendered a truncated bookingId UUID; use
the bookingReference already attached to each row (fall back to the short UUID
only when absent). Keep the UUID in the tooltip.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-15 07:54:23 +00:00
Hagernesh
7e934b3433 feat(warehouse,last-mile): truck load size rule, dedup last-mile, driver-required + arrival prefill
Truck loading:
- loadTruck enforces max 2 containers / one 40ft (two 20ft) and auto-marks an
  assigned truck arrived on load; container-items payload + modal expose
  container size with a client-side selection cap.
- Show "#x containers pending assignment" in the portal truck card and the
  backoffice container modal.

Last-mile:
- create() is idempotent — return the existing record for a booking instead of
  inserting a duplicate delivery row (fixed the same booking showing twice in
  Assign-Mile).
- setVehicles/update reject a truck with no assigned driver; the Assign toast
  now surfaces the reason.
- New GET /last-mile/booking/:id/arrival-trucks returns assigned EDR trucks with
  driver details; ReleaseOrderModal fetches and auto-fills them so an assigned
  EDR truck no longer reads as "not assigned yet".

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-14 14:16:45 +00:00
Marshal
b102a31fc1 fix train builder and consolidation 2026-07-14 13:51:31 +00:00
Marshal
5cffe2860c fix train builder and consolidation 2026-07-14 13:49:39 +00:00
Marshal
01459bd73c train 2026-07-14 13:11:38 +00:00
Marshal
b5a97d344a train 2026-07-14 13:10:00 +00:00
Hagernesh
a367306565 feat(warehouse): accrual acknowledge/snooze + zone weight fix, handover signer, portal delivery
Accrual dashboard:
- warehouse_accrual_acks table (migration 2140) + acknowledge/unacknowledge
  endpoints; dashboard rows carry acknowledged/snoozeUntil, acked items sink
  and are skipped by the alert cron. Row menu: mark reviewed / snooze 3d / 7d /
  un-acknowledge; acked rows dimmed with a "Reviewed" badge.
- Fix zone weight occupancy: normalise inventory kg vs zone-capacity tonnes.

Handover (rode along, shared files):
- Require signer full name on delivery handover (signature optional);
  migration 2130 adds signer_name.

Portal delivery/docs (rode along, shared files):
- Approve-delivery name capture, booking-scoped GRN/release docs.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-14 12:54:41 +00:00
Hagernesh
d9fe79e160 accrual dashboard for port and terminal or warehouse related documents 2026-07-14 12:54:40 +00:00
Hagernesh
a542a13893 wAREHOUSE kPI strips 2026-07-14 12:54:40 +00:00
marshal
f7f311660b Merge pull request #672 from Tria-plc/freight_feature/usermanagement
train
2026-07-14 14:09:18 +03:00
Marshal
6d0cf50b4d train 2026-07-14 11:06:49 +00:00
natib21
a48e830584 fix ui 2026-07-14 09:27:44 +00:00
natib21
1b9b4ebb77 fix ui 2026-07-14 09:12:22 +00:00
natib21
246bf940b2 fix ui 2026-07-14 08:49:20 +00:00
natib21
e63e6a2fc0 fix ui 2026-07-14 08:47:46 +00:00
yaschalew
790d3a6286 fix 2026-07-14 11:02:41 +03:00
natib21
22cf8eabd1 fix ui 2026-07-14 07:59:17 +00:00
natib21
bf9520ece4 fix ui 2026-07-14 07:45:33 +00:00
natib21
0396b6474f fix ui 2026-07-14 07:30:09 +00:00
natib21
359d1091f7 Merge branch 'dev' of github.com:Tria-plc/edr-platform into freight/feature/user_management_UI 2026-07-14 07:20:19 +00:00
natib21
1d18248795 ui 2026-07-14 07:20:01 +00:00
marshal
42f948b835 Merge pull request #659 from Tria-plc/freight_feature/usermanagement
enhance contract clearance and train scheduling logic; add filters fo…
2026-07-14 09:54:00 +03:00
Marshal
957a185a4d enhance contract clearance and train scheduling logic; add filters for clearance documents and improve booking validation 2026-07-13 21:40:10 +00:00
Hagernesh
4e8d35a7fb Warehouse zone occupancy heatmap
Visualize live per-zone occupancy on the warehouse detail page.
2026-07-13 12:09:43 +00:00
Hagernesh
f655289eec :Merge branch 'dev' of github.com:Tria-plc/edr-platform into uienhancement
Please enter a commit message to explain why this merge is necessary,
:qa!
2026-07-13 09:57:21 +00:00
Hagernesh
ae30441f07 Truck assignment for Export before loading and import after arrival 2026-07-13 09:53:33 +00:00
marshal
61cc4fab00 Merge pull request #643 from Tria-plc/freight_feature/usermanagement
Freight feature/usermanagement
2026-07-13 12:11:12 +03:00
Marshal
a31f6216ce Puppeteer PDF rendering by adding necessary dependencies and skipping Chrome download 2026-07-13 09:09:39 +00:00
marshal
43cd0223aa Merge pull request #642 from Tria-plc/freight_feature/usermanagement
add wagon allocation snapshot to train schedules
2026-07-13 11:57:24 +03:00
Marshal
a4ccdb1173 add wagon allocation snapshot to train schedules 2026-07-13 08:56:06 +00:00