This commit is contained in:
JaguarJack
2020-09-07 19:57:58 +08:00
parent dd023caf36
commit 377b72ae19
3 changed files with 54 additions and 43 deletions

View File

@@ -59,6 +59,7 @@ trait DataRangScopeTrait
case Roles::DEPARTMENT_DOWN_DATA:
// 查一下下级部门
$departmentIds = Department::where('parent_id', $user->department_id)->column('id');
$departmentIds[] = $user->department_id;
$userIds = array_merge([$user->id], $this->getUserIdsByDepartmentId($departmentIds));
break;
case Roles::DEPARTMENT_DATA: