|
|
|
@ -115,17 +115,6 @@ class MarketEvent extends Controller
|
|
|
|
|
];
|
|
|
|
|
return M('auth_group','sys_')->field("id,department_id,department_level")->where($where)->find();
|
|
|
|
|
}
|
|
|
|
|
/**
|
|
|
|
|
* 是否是某个部门领导
|
|
|
|
|
* @param int $department_id 部门id
|
|
|
|
|
* @param int $uid 管理员id
|
|
|
|
|
* @return boolean
|
|
|
|
|
*/
|
|
|
|
|
public function isDepartmentLeder($department_id,$uid)
|
|
|
|
|
{
|
|
|
|
|
$gid = M("auth_group_access")->where("uid = '{$uid}'")->getField('group_id');
|
|
|
|
|
return M('department','sys_')->where("id = '{$department_id}' and leader_group = '$gid'")->field("id")->find();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* 添加部门总监的会长权限
|
|
|
|
|