Kaynağa Gözat

修改负责人下拉KV

ith5 5 ay önce
ebeveyn
işleme
2f545b0dd8
1 değiştirilmiş dosya ile 2 ekleme ve 5 silme
  1. 2 5
      app/v1/controller/CommonController.php

+ 2 - 5
app/v1/controller/CommonController.php

@@ -145,10 +145,7 @@ class CommonController extends BaseController
             $deptList = SystemDept::where('1=1')->select()->toArray();
         }else{
             // 看公司的广告数据权限
-            if($user_info['ad_permission'] == 1){
-                $data = $this->systemUserLogic->field('id as value, username as label,dept_id')->select()->toArray();
-                $deptList = SystemDept::where('1=1')->select()->toArray();
-            }
+         
             if($user_info['ad_permission'] == 2){
                 // 看自己以及组员
                 // 1. 查看自己是哪个组
@@ -157,7 +154,7 @@ class CommonController extends BaseController
                 $data = $this->systemUserLogic->field('id as value, username as label,dept_id')->where('dept_id',$deptId)->select()->toArray();
                 $deptList = SystemDept::where('id',$deptId)->select()->toArray();
             }
-            if($user_info['ad_permission'] == 0){
+            if($user_info['ad_permission'] == 1){
                 // 仅看自己
                 $data = $this->systemUserLogic->field('id as value, username as label,dept_id')->where('id',$user_info['id'])->select()->toArray();
                 $deptList = SystemDept::where('id',$user_info['dept_id'])->select()->toArray();