Commit be4fc0cd authored by 赵啸非's avatar 赵啸非

修改根据业务查询部门逻辑

parent 05b9f110
...@@ -124,17 +124,21 @@ public class DemoWebApiController { ...@@ -124,17 +124,21 @@ public class DemoWebApiController {
//更新窗口事项中的部门id //更新窗口事项中的部门id
List<WindowMatterEntity> windowMatterEntities = windowMatterService.find(new WindowMatterQuery()); List<WindowMatterEntity> windowMatterEntities = windowMatterService.find(new WindowMatterQuery());
for (WindowMatterEntity windowMatterEntity : windowMatterEntities) { for (WindowMatterEntity windowMatterEntity : windowMatterEntities) {
DeptEntity extCache = deptService.getExtCache(windowMatterEntity.getDeptCode()); if(!ObjectUtils.isEmpty(windowMatterEntity.getDeptCode())){
if (!ObjectUtils.isEmpty(extCache)) { DeptEntity extCache = deptService.getExtCache(windowMatterEntity.getDeptCode());
if (extCache.getId() != windowMatterEntity.getDeptId()) { if (!ObjectUtils.isEmpty(extCache)) {
windowMatterEntity.setDeptId(extCache.getId()); if (extCache.getId() != windowMatterEntity.getDeptId()) {
windowMatterService.update(windowMatterEntity); windowMatterEntity.setDeptId(extCache.getId());
windowMatterService.update(windowMatterEntity);
}
} }
} }
} }
List<SiteMatterEntity> siteMatterEntities = siteMatterService.find(new SiteMatterQuery()); List<SiteMatterEntity> siteMatterEntities = siteMatterService.find(new SiteMatterQuery());
for (SiteMatterEntity siteMatterEntity : siteMatterEntities) { for (SiteMatterEntity siteMatterEntity : siteMatterEntities) {
if(ObjectUtils.isEmpty(siteMatterEntity.getDeptCode())) continue;
DeptEntity extCache = deptService.getExtCache(siteMatterEntity.getDeptCode()); DeptEntity extCache = deptService.getExtCache(siteMatterEntity.getDeptCode());
if (!ObjectUtils.isEmpty(extCache)) { if (!ObjectUtils.isEmpty(extCache)) {
if (extCache.getId() != siteMatterEntity.getDeptId()) { if (extCache.getId() != siteMatterEntity.getDeptId()) {
......
...@@ -71,6 +71,14 @@ Content-Type: application/json ...@@ -71,6 +71,14 @@ Content-Type: application/json
} }
###testre
POST {{baseUrl}}/test/reDepts
Content-Type: application/json
{}
###短信设置编辑 ###短信设置编辑
GET {{baseUrl}}/sms/set/edit?id={{SmsSet_id}} GET {{baseUrl}}/sms/set/edit?id={{SmsSet_id}}
Accept: application/json Accept: application/json
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment