组织同步逻辑修改
This commit is contained in:
+2
@@ -489,6 +489,8 @@ public class OASyncServiceImpl implements IOASyncService {
|
|||||||
Set<String> companyNames = syncAll ? Collections.emptySet() : getCompanyNames();
|
Set<String> companyNames = syncAll ? Collections.emptySet() : getCompanyNames();
|
||||||
// 转换数据
|
// 转换数据
|
||||||
List<Dept> allParam = oaCompanies.stream()
|
List<Dept> allParam = oaCompanies.stream()
|
||||||
|
// 强制跳过上级公司为 0 的数据
|
||||||
|
.filter(company -> !OAConstant.ROOT_COMPANY_ID.equals(company.getSupsubcomid()))
|
||||||
// 非全量同步时,筛选只要配置的公司
|
// 非全量同步时,筛选只要配置的公司
|
||||||
.filter(company -> syncAll || companyNames.contains(company.getSubcompanyname()))
|
.filter(company -> syncAll || companyNames.contains(company.getSubcompanyname()))
|
||||||
.map(deptConvert::company2dept)
|
.map(deptConvert::company2dept)
|
||||||
|
|||||||
Reference in New Issue
Block a user