|
|
@@ -209,7 +209,8 @@ public class SysDeptServiceImpl implements ISysDeptService
|
|
209
|
209
|
updateDeptChildren(dept.getDeptId(), newAncestors, oldAncestors);
|
|
210
|
210
|
}
|
|
211
|
211
|
int result = deptMapper.updateDept(dept);
|
|
212
|
|
- if (UserConstants.DEPT_NORMAL.equals(dept.getStatus()))
|
|
|
212
|
+ if (UserConstants.DEPT_NORMAL.equals(dept.getStatus()) && StringUtils.isNotEmpty(dept.getAncestors())
|
|
|
213
|
+ && !StringUtils.equals("0", dept.getAncestors()))
|
|
213
|
214
|
{
|
|
214
|
215
|
// 如果该部门是启用状态,则启用该部门的所有上级部门
|
|
215
|
216
|
updateParentDeptStatusNormal(dept);
|