Files
Siro/backend/Admin
Hamza-AyedandClaude Opus 5 852c6ece5c Fix admin status handling for the current ride pipeline; extend console
The ride table holds two generations of status values: the legacy CamelCase
set ('Finished', 'CancelFromPassenger') and the lowercase set written by
backend/ride/rides/* today ('completed', 'cancelled_by_passenger'). Admin
queries only matched the legacy set, so on live data:

- get_rides_by_status.php returned nothing meaningful for every filter, and
  the "in progress" default masked it.
- dashbord.php reported total_driver_earnings as NULL, completed_rides as a
  fraction of the real count, and cancelled_rides as 0.
- driver_avg_duration averaged in negative durations, yielding "-00h 22m".

All three now match on LOWER(status) across both families.

Staff/pending.php ran with no authentication at all, exposing pending
admins' names and phone numbers to any caller; it now goes through
connect.php with a role check. It also returned HTTP 400 for everything when
the `users` table was absent — each source is queried independently and
reports its own availability.

Console:
- Render rides from either schema generation (price/date/time and
  start_location coordinates, or the older address/created_at columns).
- Null aggregates render as "—" rather than a measured 0.00.
- Add tariff/promo, WhatsApp send and encryption modules, all super-admin
  gated; pricing remains read-only.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-07-25 01:47:55 +03:00
..
2026-06-09 08:40:31 +03:00
2026-06-26 17:59:47 +03:00
2026-06-12 20:40:40 +03:00
2026-06-12 20:40:40 +03:00
2026-07-02 05:27:05 +03:00
2026-07-09 01:01:16 +03:00
2026-07-12 18:53:59 +03:00
2026-07-10 23:59:23 +03:00
2026-06-09 08:40:31 +03:00
2026-06-09 08:40:31 +03:00
2026-06-09 08:40:31 +03:00
2026-06-16 01:17:29 +03:00
2026-06-09 08:40:31 +03:00
2026-06-12 20:40:40 +03:00