This commit is contained in:
2025-05-28 13:31:56 +08:00
parent f5b65bc15c
commit 5d052fa431
+1
View File
@@ -19,6 +19,7 @@ class LocationController
->map(function ($location) {
$location->vehicle_count = $location->vehicles->count();
$location->fbo_vehicle_count = $location->fboVehicles->count();
$location->count = ($location->vehicle_count > 0) ? $location->vehicle_count : $location->fbo_vehicle_count;
return $location;
});
return Util::success($locations);