|
...
|
...
|
@@ -60,16 +60,16 @@ class HrLogic extends BaseLogic |
|
|
|
* @method :post
|
|
|
|
* @time :2023/7/25 9:27
|
|
|
|
*/
|
|
|
|
public function getHrInfo($id){
|
|
|
|
public function getHrInfo(){
|
|
|
|
//查看当前用户是否有人事权限
|
|
|
|
if($this->manager['gid'] != ManageHr::GID_ZERO){
|
|
|
|
if(isset($this->param['id']) && ($this->manager['gid'] != ManageHr::GID_ZERO)){
|
|
|
|
$groupModel = new Group();
|
|
|
|
$groupInfo = $groupModel->read(['id'=>$this->manager['gid']]);
|
|
|
|
if (!in_array(20,$groupInfo['rights']) && ($id != $this->manager['id'])) {
|
|
|
|
if (!in_array(20,$groupInfo['rights']) && ($this->param['id'] != $this->manager['id'])) {
|
|
|
|
$this->fail('无权限查看其他用户信息');
|
|
|
|
}
|
|
|
|
}
|
|
|
|
$data = $this->model->read(['id'=>$id]);
|
|
|
|
$data = $this->model->read($this->param);
|
|
|
|
foreach ($this->model::specieField() as $v){
|
|
|
|
$data[$v] = json_decode($data[$v],true);
|
|
|
|
}
|
...
|
...
|
|