mirror of
https://github.com/PlayEdu/PlayEdu
synced 2025-06-27 23:52:58 +08:00
fixed: LDAP部门同步的同层级的上级变动bug
This commit is contained in:
parent
6541c3a191
commit
bac04d164f
@ -138,8 +138,10 @@ public class LDAPBus {
|
|||||||
Department tmpDepartment =
|
Department tmpDepartment =
|
||||||
departmentService.findOrFail(tmpLdapDepartment.getDepartmentId());
|
departmentService.findOrFail(tmpLdapDepartment.getDepartmentId());
|
||||||
if (!tmpDepartment.getName().equals(tmpName)
|
if (!tmpDepartment.getName().equals(tmpName)
|
||||||
|| tmpLdapDepartment.getDn().split(",").length
|
|| !tmpLdapDepartment
|
||||||
!= dn.split(",").length) {
|
.getDn()
|
||||||
|
.replace("ou=" + tmpName, "")
|
||||||
|
.equals(dn.replaceAll("ou=" + tmpName, ""))) {
|
||||||
departmentService.update(tmpDepartment, tmpName, parentId, sort);
|
departmentService.update(tmpDepartment, tmpName, parentId, sort);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user