|
|
@@ -102,13 +102,17 @@ class WorkOrderFilters
|
|
|
{
|
|
|
if (isset($this->params['is_end'])) return;
|
|
|
$this->queryBuilder->where('status', '!=', 5); // 过滤已完成
|
|
|
+ $status = [];
|
|
|
if (Gate::allows('订单管理-工单处理-客服编辑')) {
|
|
|
- $this->queryBuilder->where('status', 4); // 过滤宝时终审
|
|
|
- } else if (Gate::allows('订单管理-工单处理-承运商编辑')) {
|
|
|
- $this->queryBuilder->where('status', 3); // 过滤承运商编辑
|
|
|
- } else if (Gate::allows('订单管理-工单处理-货主编辑')) {
|
|
|
- $this->queryBuilder->where('status', 1); // 过滤货主编辑
|
|
|
+ $status[]= 4;
|
|
|
+ }
|
|
|
+ if (Gate::allows('订单管理-工单处理-承运商编辑')) {
|
|
|
+ $status[]= 3;
|
|
|
+ }
|
|
|
+ if (Gate::allows('订单管理-工单处理-货主编辑')) {
|
|
|
+ $status[]= 1;
|
|
|
}
|
|
|
+ $this->queryBuilder->whereIn('status',$status);
|
|
|
}
|
|
|
|
|
|
private function afterFilterOwner($owner_ids)
|