tracksolid_timescale_grafan.../migrations
david kiania 0c32094347
Some checks are pending
Static Analysis / static (push) Waiting to run
Tests / test (push) Waiting to run
feat(reporting): exclude non-operational vehicles from the live map (migration 15)
Hide personal + management + mtn (Uganda/Kampala) vehicles from the live tracking
map (FleetNow + liveposition SPA). Adds an ops-editable config table
reporting.map_excluded_cost_centres and filters reporting.v_live_positions to drop
any plate whose device(s) carry an excluded cost centre (robust to the tracker/cam
cost_centre inconsistency).

Scope is live-map only; reporting.v_trips (trip history) is intentionally untouched.
The base view feeds reporting.fn_live_positions, so the change propagates to every
live consumer with no dashboard_api redeploy or frontend change. Verified live:
80 -> 74 vehicles, all 6 targets gone (KDU 613A, KDW 781E, UMA 011EK/382EK/418EK/826AB).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-08 14:18:30 +03:00
..
02_tracksolid_full_schema_rev.sql chore(repo): reorganize tree into migrations/ data/ legacy/ docs/ 2026-06-01 02:27:30 +03:00
03_webhook_schema_migration.sql chore(repo): reorganize tree into migrations/ data/ legacy/ docs/ 2026-06-01 02:27:30 +03:00
04_bug_fix_migration.sql chore(repo): reorganize tree into migrations/ data/ legacy/ docs/ 2026-06-01 02:27:30 +03:00
05_enhancement_migration.sql chore(repo): reorganize tree into migrations/ data/ legacy/ docs/ 2026-06-01 02:27:30 +03:00
06_business_analytics_migration.sql chore(repo): reorganize tree into migrations/ data/ legacy/ docs/ 2026-06-01 02:27:30 +03:00
07_analytics_views.sql chore(repo): reorganize tree into migrations/ data/ legacy/ docs/ 2026-06-01 02:27:30 +03:00
08_analytics_config.sql chore(repo): reorganize tree into migrations/ data/ legacy/ docs/ 2026-06-01 02:27:30 +03:00
09_trips_enrichment.sql chore(repo): reorganize tree into migrations/ data/ legacy/ docs/ 2026-06-01 02:27:30 +03:00
10_driver_clock_views.sql chore(repo): reorganize tree into migrations/ data/ legacy/ docs/ 2026-06-01 02:27:30 +03:00
10_pgbouncer_auth.sql chore(repo): reorganize tree into migrations/ data/ legacy/ docs/ 2026-06-01 02:27:30 +03:00
11_reporting_schema.sql feat(db): capture reporting.* map-dashboard schema as migration 11 2026-06-05 12:32:44 +03:00
12_drop_ops.sql chore(db): purge unused ops + dwh_gold schemas 2026-06-05 18:11:03 +03:00
13_drop_dwh_gold.sql chore(db): purge unused ops + dwh_gold schemas 2026-06-05 18:11:03 +03:00
14_fleet_segment_and_vehicles_view.sql feat(reporting): fleet segmentation + deduped vehicle roster (migration 14) 2026-06-08 13:54:47 +03:00
15_map_exclude_cost_centres.sql feat(reporting): exclude non-operational vehicles from the live map (migration 15) 2026-06-08 14:18:30 +03:00