作者 lyh

gx

@@ -84,11 +84,6 @@ class ProjectRoleLogic extends BaseLogic @@ -84,11 +84,6 @@ class ProjectRoleLogic extends BaseLogic
84 if($info !== false){ 84 if($info !== false){
85 $this->fail('当前角色名称已存在'); 85 $this->fail('当前角色名称已存在');
86 } 86 }
87 - //类型  
88 - $this->param['type'] = $this->model::TYPE_ONE;  
89 - //A端操作人  
90 - $this->param['create_id'] = $this->manager['id'];  
91 - $this->param['operator_id'] = $this->manager['id'];  
92 $rs = $this->model->add($this->param); 87 $rs = $this->model->add($this->param);
93 if($rs === false){ 88 if($rs === false){
94 $this->fail('添加失败'); 89 $this->fail('添加失败');
@@ -111,7 +106,6 @@ class ProjectRoleLogic extends BaseLogic @@ -111,7 +106,6 @@ class ProjectRoleLogic extends BaseLogic
111 if($info !== false){ 106 if($info !== false){
112 $this->fail('当前菜单名称已存在'); 107 $this->fail('当前菜单名称已存在');
113 } 108 }
114 - $this->param['operator_id'] = $this->manager['id'];  
115 $rs = $this->edit($this->param,['id'=>$this->param['id']]); 109 $rs = $this->edit($this->param,['id'=>$this->param['id']]);
116 if($rs === false){ 110 if($rs === false){
117 $this->fail('error'); 111 $this->fail('error');
@@ -32,13 +32,8 @@ class UserLogic extends BaseLogic @@ -32,13 +32,8 @@ class UserLogic extends BaseLogic
32 if($info === false){ 32 if($info === false){
33 $this->fail('当前数据不存在'); 33 $this->fail('当前数据不存在');
34 } 34 }
35 - if($info['type'] == 1){  
36 - $userModel = new UserModel();  
37 - $info['operator_name'] = $userModel->read(['id'=>$info['operator_id']],['name'])['name'];  
38 - }else{  
39 - $managerModel = new Manage();  
40 - $info['operator_name'] = $managerModel->read(['id'=>$info['operator_id']],['name'])['name'];  
41 - } 35 + $userModel = new UserModel();
  36 + $info['operator_name'] = $userModel->read(['id'=>$info['operator_id']],['name'])['name'];
42 $info['project_name'] = (new Project())->read(['id'=>$info['project_id']],['title'])['title']; 37 $info['project_name'] = (new Project())->read(['id'=>$info['project_id']],['title'])['title'];
43 Common::set_user_cache($info,$this->model,$this->param['id'],'A'); 38 Common::set_user_cache($info,$this->model,$this->param['id'],'A');
44 } 39 }
@@ -53,11 +48,6 @@ class UserLogic extends BaseLogic @@ -53,11 +48,6 @@ class UserLogic extends BaseLogic
53 public function user_add(){ 48 public function user_add(){
54 $this->verifyMobile();//验证手机号 49 $this->verifyMobile();//验证手机号
55 $this->param['password'] = base64_encode(md5($this->param['password'])); 50 $this->param['password'] = base64_encode(md5($this->param['password']));
56 - //类型  
57 - $this->param['type'] = 1;  
58 - //A端操作人  
59 - $this->param['create_id'] = $this->manager['id'];  
60 - $this->param['operator_id'] = $this->manager['id'];  
61 $rs = $this->model->add($this->param); 51 $rs = $this->model->add($this->param);
62 if($rs === false){ 52 if($rs === false){
63 $this->fail('添加失败'); 53 $this->fail('添加失败');
@@ -80,7 +70,6 @@ class UserLogic extends BaseLogic @@ -80,7 +70,6 @@ class UserLogic extends BaseLogic
80 $this->param['password'] = base64_encode(md5($this->param['password'])); 70 $this->param['password'] = base64_encode(md5($this->param['password']));
81 } 71 }
82 } 72 }
83 - $this->param['operator_id'] = $this->manager['id'];  
84 $rs = $this->model->edit($this->param,['id'=>$this->param['id']]); 73 $rs = $this->model->edit($this->param,['id'=>$this->param['id']]);
85 if($rs === false){ 74 if($rs === false){
86 $this->fail('编辑失败'); 75 $this->fail('编辑失败');