ajun 4 år sedan
förälder
incheckning
13c51eddcc
1 ändrade filer med 4 tillägg och 4 borttagningar
  1. 4 4
      app/Filters/WorkOrderFilters.php

+ 4 - 4
app/Filters/WorkOrderFilters.php

@@ -71,7 +71,7 @@ class WorkOrderFilters
         if(isset($this->params['data']))
         if(isset($this->params['data']))
             $this->id(explode(',',$this->params['data']));
             $this->id(explode(',',$this->params['data']));
 
 
-        // 可见过滤
+
         $this->afterFilter();
         $this->afterFilter();
     }
     }
 
 
@@ -89,14 +89,17 @@ class WorkOrderFilters
         $this->afterFilterOwner($orderQuery,$owner_ids,);
         $this->afterFilterOwner($orderQuery,$owner_ids,);
     }
     }
 
 
+    // 可见货主过滤
     private function afterFilterOwner($orderQuery,$owner_ids)
     private function afterFilterOwner($orderQuery,$owner_ids)
     {
     {
         if(Gate::allows('订单管理-工单处理-客服编辑') || Gate::allows('订单管理-工单处理-承运商编辑')){
         if(Gate::allows('订单管理-工单处理-客服编辑') || Gate::allows('订单管理-工单处理-承运商编辑')){
+
         }else if(Gate::allows('订单管理-工单处理-货主编辑')){
         }else if(Gate::allows('订单管理-工单处理-货主编辑')){
             $orderQuery->whereIn('owner_id',$owner_ids);
             $orderQuery->whereIn('owner_id',$owner_ids);
         }
         }
     }
     }
 
 
+    // 可见承运商过滤
     private function afterFilterLogistic($orderQuery,$owner_ids,$logistic_ids)
     private function afterFilterLogistic($orderQuery,$owner_ids,$logistic_ids)
     {
     {
         if(Gate::allows('订单管理-工单处理-客服编辑') || Gate::allows('订单管理-工单处理-货主编辑')){
         if(Gate::allows('订单管理-工单处理-客服编辑') || Gate::allows('订单管理-工单处理-货主编辑')){
@@ -106,11 +109,8 @@ class WorkOrderFilters
         } else if (Gate::allows('订单管理-工单处理-承运商编辑')){
         } else if (Gate::allows('订单管理-工单处理-承运商编辑')){
             $orderQuery->whereIn('logistic_id',array_values($logistic_ids));
             $orderQuery->whereIn('logistic_id',array_values($logistic_ids));
         }
         }
-
     }
     }
 
 
-
-
     public function beforeApply()
     public function beforeApply()
     {
     {
         if ($this->orderPackageQuery){
         if ($this->orderPackageQuery){