Jelajahi Sumber

plan不能查看别的公司下的

kely 7 bulan lalu
induk
melakukan
5abf4e0aea
1 mengubah file dengan 1 tambahan dan 1 penghapusan
  1. 1 1
      app/Http/Controllers/API/PlanController.php

+ 1 - 1
app/Http/Controllers/API/PlanController.php

@@ -66,7 +66,7 @@ class PlanController extends Controller
             return $emptyResponse;
         }
 
-        $plans = Plan::query()->with(['asset'])->whereIn("asset_id", $assets->toArray())->get();
+        $plans = Plan::query()->allowed()->with(['asset'])->whereIn("asset_id", $assets->toArray())->get();
 
         return PlanByAssetResource::collection($plans);
     }