|
...
|
...
|
@@ -41,7 +41,7 @@ class DepartmentLogic extends BaseLogic |
|
|
|
continue;
|
|
|
|
}
|
|
|
|
//是否有子部门
|
|
|
|
if(Department::where('pid', $id)->count()){
|
|
|
|
if(Department::where('project_id', $this->user['project_id'])->where('pid', $id)->count()){
|
|
|
|
$this->fail("部门{$info['title']}存在下级部门,不能删除");
|
|
|
|
}
|
|
|
|
}
|
...
|
...
|
|