Commit 29c1041c authored by zhuwei's avatar zhuwei

解除绑定关系

parent 2a6cf80f
...@@ -589,13 +589,13 @@ class UserService ...@@ -589,13 +589,13 @@ class UserService
public function removeUserBind($now_user_id,$user_id,$agent_id){ public function removeUserBind($now_user_id,$user_id,$agent_id){
// 检查权限 客方自己 有权限的人 // 检查权限 客方自己 有权限的人
$user_agent_id = $this->user->getUserByWhereValue('agent_id', ['id'=>$now_user_id]); $user_agent_id = $this->user->getUserByWhereValue('agent_id', ['id'=>$now_user_id]);
if($user_agent_id['agent_id' != $agent_id]){ if($user_agent_id != $agent_id){
return 1;//操作人不是客方 return 1;//操作人不是客方
} }
$s_vip = new VipService(); $s_vip = new VipService();
//0:有权限 1:无权限 //0:有权限 1:无权限
$is_can_edit = $s_vip->vip($agent_id,'removeUserBind'); $is_can_edit = $s_vip->vip($agent_id,'removeUserBind');
if ($is_can_edit == 1 and ($user_agent_id['agent_id' != $agent_id])) { if ($is_can_edit == 1 and ($user_agent_id != $agent_id)) {
return 2;//无解除关联权限权限 return 2;//无解除关联权限权限
} }
// 客户bind_id不等于0才能解绑并记录日志 // 客户bind_id不等于0才能解绑并记录日志
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment