feat: add 5-hour trip expiration timer and rbac activity deletion permissions

This commit is contained in:
Ray1111-aa
2026-10-22 12:23:13 +07:00
parent d389e0a9c2
commit 34c9310e8a
14 changed files with 753 additions and 27 deletions
@@ -66,6 +66,9 @@ class VehicleActivityFormController extends Controller
->orderBy('name')
->get();
// Bersihkan data aktivitas pending yang telah kedaluwarsa (> 5 jam)
VehicleActivity::expireOverduePendingActivities();
// Tentukan arah yang diperbolehkan berdasarkan riwayat terakhir
$allowedDirection = $vehicle->determineNextAllowedDirection();