101captain
2022-05-24 8c7ccc0402a105ea6b6dfd743f8cb9add2041f36
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComMngPopulationServiceImpl.java
@@ -139,6 +139,8 @@
    private String aesKey;
    @Resource
    private ComActEasyPhotoDAO comActEasyPhotoDAO;
    @Resource
    private ComMngBuildingDAO comMngBuildingDAO;
    /**
     * 新增实有人口
@@ -925,6 +927,7 @@
                                iterator.remove();
                        }
                        comMngPopulationCommunityTagsDO.setLabel(Joiner.on(",").join(userTag));
                        comMngPopulationCommunityTagsDO.setUpdateBy(userId);
                        updatePopulationCommunityList.add(comMngPopulationCommunityTagsDO);
@@ -936,6 +939,18 @@
                    }
                }
                log.info("查询实有人口存在社区信息完成");
                log.info("开始处理楼栋信息");
                List<ComMngBuildingDO> comMngBuildingDOList= comMngBuildingDAO.selectList(new QueryWrapper<ComMngBuildingDO>().lambda().eq(ComMngBuildingDO::getVillageId,comMngVillageDO.getVillageId()).eq(ComMngBuildingDO::getName,vo.getFloor()));
                if(comMngBuildingDOList.isEmpty()){
                   ComMngBuildingDO  comMngBuildingDO=new ComMngBuildingDO();
                   comMngBuildingDO.setId(Snowflake.getId());
                   comMngBuildingDO.setVillageId(comMngVillageDO.getVillageId());
                   comMngBuildingDO.setName(vo.getFloor());
                   comMngBuildingDO.setActId(comMngVillageDO.getCommunityId());
                   comMngBuildingDO.setStreetId(comMngVillageDO.getStreetId());
                   comMngBuildingDAO.insert(comMngBuildingDO);
                }
            }
        } catch (Exception e) {
            log.info("出现错误,错误原因:" + e.getMessage());
@@ -1230,7 +1245,12 @@
                            if (!labelList.contains(s))
                                iterator.remove();
                        }
                        comMngPopulationCommunityTagsDO.setLabel(Joiner.on(",").join(userTag));
                        if(StringUtils.isNotEmpty(comMngPopulationCommunityTagsDO.getLabel())){
                            comMngPopulationCommunityTagsDO.setLabel(comMngPopulationCommunityTagsDO.getLabel()+","+Joiner.on(",").join(userTag));
                        }
                        else{
                            comMngPopulationCommunityTagsDO.setLabel(Joiner.on(",").join(userTag));
                        }
                        comMngPopulationCommunityTagsDO.setUpdateBy(userId);
                        updatePopulationCommunityList.add(comMngPopulationCommunityTagsDO);
@@ -1241,7 +1261,19 @@
                        mistakes.add(mistake);
                    }
                }
                log.info("查询实有人口存在社区信息完成");
                log.info("开始处理楼栋信息");
                List<ComMngBuildingDO> comMngBuildingDOList= comMngBuildingDAO.selectList(new QueryWrapper<ComMngBuildingDO>().lambda().eq(ComMngBuildingDO::getVillageId,comMngVillageDO.getVillageId()).eq(ComMngBuildingDO::getName,vo.getFloor()));
                if(comMngBuildingDOList.isEmpty()){
                   ComMngBuildingDO  comMngBuildingDO=new ComMngBuildingDO();
                   comMngBuildingDO.setVillageId(comMngVillageDO.getVillageId());
                   comMngBuildingDO.setName(vo.getFloor());
                   comMngBuildingDO.setActId(comMngVillageDO.getCommunityId());
                   comMngBuildingDO.setStreetId(comMngBuildingDO.getStreetId());
                   comMngBuildingDAO.insert(comMngBuildingDO);
                }
            }
        } catch (Exception e) {
            log.info("出现错误,错误原因:" + e.getMessage());
@@ -1536,7 +1568,12 @@
                            if (!labelList.contains(s))
                                iterator.remove();
                        }
                        comMngPopulationCommunityTagsDO.setLabel(Joiner.on(",").join(userTag));
                        if(StringUtils.isNotEmpty(comMngPopulationCommunityTagsDO.getLabel())){
                            comMngPopulationCommunityTagsDO.setLabel(comMngPopulationCommunityTagsDO.getLabel()+","+Joiner.on(",").join(userTag));
                        }
                        else{
                            comMngPopulationCommunityTagsDO.setLabel(Joiner.on(",").join(userTag));
                        }
                        comMngPopulationCommunityTagsDO.setUpdateBy(userId);
                        updatePopulationCommunityList.add(comMngPopulationCommunityTagsDO);
@@ -1547,7 +1584,19 @@
                        mistakes.add(mistake);
                    }
                }
                log.info("查询实有人口存在社区信息完成");
                log.info("开始处理楼栋信息");
                List<ComMngBuildingDO> comMngBuildingDOList= comMngBuildingDAO.selectList(new QueryWrapper<ComMngBuildingDO>().lambda().eq(ComMngBuildingDO::getVillageId,comMngVillageDO.getVillageId()).eq(ComMngBuildingDO::getName,vo.getFloor()));
                if(comMngBuildingDOList.isEmpty()){
                   ComMngBuildingDO  comMngBuildingDO=new ComMngBuildingDO();
                   comMngBuildingDO.setVillageId(comMngVillageDO.getVillageId());
                   comMngBuildingDO.setName(vo.getFloor());
                   comMngBuildingDO.setActId(comMngVillageDO.getCommunityId());
                   comMngBuildingDO.setStreetId(comMngBuildingDO.getStreetId());
                   comMngBuildingDAO.insert(comMngBuildingDO);
                }
            }
        } catch (Exception e) {
            log.info("出现错误,错误原因:" + e.getMessage());
@@ -1842,7 +1891,12 @@
                            if (!labelList.contains(s))
                                iterator.remove();
                        }
                        comMngPopulationCommunityTagsDO.setLabel(Joiner.on(",").join(userTag));
                        if(StringUtils.isNotEmpty(comMngPopulationCommunityTagsDO.getLabel())){
                            comMngPopulationCommunityTagsDO.setLabel(comMngPopulationCommunityTagsDO.getLabel()+","+Joiner.on(",").join(userTag));
                        }
                        else{
                            comMngPopulationCommunityTagsDO.setLabel(Joiner.on(",").join(userTag));
                        }
                        comMngPopulationCommunityTagsDO.setUpdateBy(userId);
                        updatePopulationCommunityList.add(comMngPopulationCommunityTagsDO);
@@ -1853,7 +1907,19 @@
                        mistakes.add(mistake);
                    }
                }
                log.info("查询实有人口存在社区信息完成");
                log.info("开始处理楼栋信息");
                List<ComMngBuildingDO> comMngBuildingDOList= comMngBuildingDAO.selectList(new QueryWrapper<ComMngBuildingDO>().lambda().eq(ComMngBuildingDO::getVillageId,comMngVillageDO.getVillageId()).eq(ComMngBuildingDO::getName,vo.getFloor()));
                if(comMngBuildingDOList.isEmpty()){
                   ComMngBuildingDO  comMngBuildingDO=new ComMngBuildingDO();
                   comMngBuildingDO.setVillageId(comMngVillageDO.getVillageId());
                   comMngBuildingDO.setName(vo.getFloor());
                   comMngBuildingDO.setActId(comMngVillageDO.getCommunityId());
                   comMngBuildingDO.setStreetId(comMngBuildingDO.getStreetId());
                   comMngBuildingDAO.insert(comMngBuildingDO);
                }
            }
        } catch (Exception e) {
            log.info("出现错误,错误原因:" + e.getMessage());
@@ -2148,7 +2214,12 @@
                            if (!labelList.contains(s))
                                iterator.remove();
                        }
                        comMngPopulationCommunityTagsDO.setLabel(Joiner.on(",").join(userTag));
                        if(StringUtils.isNotEmpty(comMngPopulationCommunityTagsDO.getLabel())){
                            comMngPopulationCommunityTagsDO.setLabel(comMngPopulationCommunityTagsDO.getLabel()+","+Joiner.on(",").join(userTag));
                        }
                        else{
                            comMngPopulationCommunityTagsDO.setLabel(Joiner.on(",").join(userTag));
                        }
                        comMngPopulationCommunityTagsDO.setUpdateBy(userId);
                        updatePopulationCommunityList.add(comMngPopulationCommunityTagsDO);
@@ -2159,7 +2230,19 @@
                        mistakes.add(mistake);
                    }
                }
                log.info("查询实有人口存在社区信息完成");
                log.info("开始处理楼栋信息");
                List<ComMngBuildingDO> comMngBuildingDOList= comMngBuildingDAO.selectList(new QueryWrapper<ComMngBuildingDO>().lambda().eq(ComMngBuildingDO::getVillageId,comMngVillageDO.getVillageId()).eq(ComMngBuildingDO::getName,vo.getFloor()));
                if(comMngBuildingDOList.isEmpty()){
                   ComMngBuildingDO  comMngBuildingDO=new ComMngBuildingDO();
                   comMngBuildingDO.setVillageId(comMngVillageDO.getVillageId());
                   comMngBuildingDO.setName(vo.getFloor());
                   comMngBuildingDO.setActId(comMngVillageDO.getCommunityId());
                   comMngBuildingDO.setStreetId(comMngBuildingDO.getStreetId());
                   comMngBuildingDAO.insert(comMngBuildingDO);
                }
            }
        } catch (Exception e) {
            log.info("出现错误,错误原因:" + e.getMessage());
@@ -2455,7 +2538,12 @@
                            if (!labelList.contains(s))
                                iterator.remove();
                        }
                        comMngPopulationCommunityTagsDO.setLabel(Joiner.on(",").join(userTag));
                        if(StringUtils.isNotEmpty(comMngPopulationCommunityTagsDO.getLabel())){
                            comMngPopulationCommunityTagsDO.setLabel(comMngPopulationCommunityTagsDO.getLabel()+","+Joiner.on(",").join(userTag));
                        }
                        else{
                            comMngPopulationCommunityTagsDO.setLabel(Joiner.on(",").join(userTag));
                        }
                        comMngPopulationCommunityTagsDO.setUpdateBy(userId);
                        updatePopulationCommunityList.add(comMngPopulationCommunityTagsDO);
@@ -2467,7 +2555,19 @@
                        mistakes.add(mistake);
                    }
                }
                log.info("查询实有人口存在社区信息完成");
                log.info("开始处理楼栋信息");
                List<ComMngBuildingDO> comMngBuildingDOList= comMngBuildingDAO.selectList(new QueryWrapper<ComMngBuildingDO>().lambda().eq(ComMngBuildingDO::getVillageId,comMngVillageDO.getVillageId()).eq(ComMngBuildingDO::getName,vo.getFloor()));
                if(comMngBuildingDOList.isEmpty()){
                   ComMngBuildingDO  comMngBuildingDO=new ComMngBuildingDO();
                   comMngBuildingDO.setVillageId(comMngVillageDO.getVillageId());
                   comMngBuildingDO.setName(vo.getFloor());
                   comMngBuildingDO.setActId(comMngVillageDO.getCommunityId());
                   comMngBuildingDO.setStreetId(comMngBuildingDO.getStreetId());
                   comMngBuildingDAO.insert(comMngBuildingDO);
                }
            }
        } catch (Exception e) {
            log.info("出现错误,错误原因:" + e.getMessage());
@@ -2761,7 +2861,12 @@
                            if (!labelList.contains(s))
                                iterator.remove();
                        }
                        comMngPopulationCommunityTagsDO.setLabel(Joiner.on(",").join(userTag));
                        if(StringUtils.isNotEmpty(comMngPopulationCommunityTagsDO.getLabel())){
                            comMngPopulationCommunityTagsDO.setLabel(comMngPopulationCommunityTagsDO.getLabel()+","+Joiner.on(",").join(userTag));
                        }
                        else{
                            comMngPopulationCommunityTagsDO.setLabel(Joiner.on(",").join(userTag));
                        }
                        comMngPopulationCommunityTagsDO.setUpdateBy(userId);
                        updatePopulationCommunityList.add(comMngPopulationCommunityTagsDO);
@@ -2772,7 +2877,19 @@
                        mistakes.add(mistake);
                    }
                }
                log.info("查询实有人口存在社区信息完成");
                log.info("开始处理楼栋信息");
                List<ComMngBuildingDO> comMngBuildingDOList= comMngBuildingDAO.selectList(new QueryWrapper<ComMngBuildingDO>().lambda().eq(ComMngBuildingDO::getVillageId,comMngVillageDO.getVillageId()).eq(ComMngBuildingDO::getName,vo.getFloor()));
                if(comMngBuildingDOList.isEmpty()){
                   ComMngBuildingDO  comMngBuildingDO=new ComMngBuildingDO();
                   comMngBuildingDO.setVillageId(comMngVillageDO.getVillageId());
                   comMngBuildingDO.setName(vo.getFloor());
                   comMngBuildingDO.setActId(comMngVillageDO.getCommunityId());
                   comMngBuildingDO.setStreetId(comMngBuildingDO.getStreetId());
                   comMngBuildingDAO.insert(comMngBuildingDO);
                }
            }
        } catch (Exception e) {
            log.info("出现错误,错误原因:" + e.getMessage());
@@ -3066,7 +3183,12 @@
                            if (!labelList.contains(s))
                                iterator.remove();
                        }
                        comMngPopulationCommunityTagsDO.setLabel(Joiner.on(",").join(userTag));
                        if(StringUtils.isNotEmpty(comMngPopulationCommunityTagsDO.getLabel())){
                            comMngPopulationCommunityTagsDO.setLabel(comMngPopulationCommunityTagsDO.getLabel()+","+Joiner.on(",").join(userTag));
                        }
                        else{
                            comMngPopulationCommunityTagsDO.setLabel(Joiner.on(",").join(userTag));
                        }
                        comMngPopulationCommunityTagsDO.setUpdateBy(userId);
                        updatePopulationCommunityList.add(comMngPopulationCommunityTagsDO);
@@ -3077,7 +3199,19 @@
                        mistakes.add(mistake);
                    }
                }
                log.info("查询实有人口存在社区信息完成");
                log.info("开始处理楼栋信息");
                List<ComMngBuildingDO> comMngBuildingDOList= comMngBuildingDAO.selectList(new QueryWrapper<ComMngBuildingDO>().lambda().eq(ComMngBuildingDO::getVillageId,comMngVillageDO.getVillageId()).eq(ComMngBuildingDO::getName,vo.getFloor()));
                if(comMngBuildingDOList.isEmpty()){
                   ComMngBuildingDO  comMngBuildingDO=new ComMngBuildingDO();
                   comMngBuildingDO.setVillageId(comMngVillageDO.getVillageId());
                   comMngBuildingDO.setName(vo.getFloor());
                   comMngBuildingDO.setActId(comMngVillageDO.getCommunityId());
                   comMngBuildingDO.setStreetId(comMngBuildingDO.getStreetId());
                   comMngBuildingDAO.insert(comMngBuildingDO);
                }
            }
        } catch (Exception e) {
            log.info("出现错误,错误原因:" + e.getMessage());
@@ -3371,7 +3505,12 @@
                            if (!labelList.contains(s))
                                iterator.remove();
                        }
                        comMngPopulationCommunityTagsDO.setLabel(Joiner.on(",").join(userTag));
                        if(StringUtils.isNotEmpty(comMngPopulationCommunityTagsDO.getLabel())){
                            comMngPopulationCommunityTagsDO.setLabel(comMngPopulationCommunityTagsDO.getLabel()+","+Joiner.on(",").join(userTag));
                        }
                        else{
                            comMngPopulationCommunityTagsDO.setLabel(Joiner.on(",").join(userTag));
                        }
                        comMngPopulationCommunityTagsDO.setUpdateBy(userId);
                        updatePopulationCommunityList.add(comMngPopulationCommunityTagsDO);
@@ -3382,7 +3521,19 @@
                        mistakes.add(mistake);
                    }
                }
                log.info("查询实有人口存在社区信息完成");
                log.info("开始处理楼栋信息");
                List<ComMngBuildingDO> comMngBuildingDOList= comMngBuildingDAO.selectList(new QueryWrapper<ComMngBuildingDO>().lambda().eq(ComMngBuildingDO::getVillageId,comMngVillageDO.getVillageId()).eq(ComMngBuildingDO::getName,vo.getFloor()));
                if(comMngBuildingDOList.isEmpty()){
                   ComMngBuildingDO  comMngBuildingDO=new ComMngBuildingDO();
                   comMngBuildingDO.setVillageId(comMngVillageDO.getVillageId());
                   comMngBuildingDO.setName(vo.getFloor());
                   comMngBuildingDO.setActId(comMngVillageDO.getCommunityId());
                   comMngBuildingDO.setStreetId(comMngBuildingDO.getStreetId());
                   comMngBuildingDAO.insert(comMngBuildingDO);
                }
            }
        } catch (Exception e) {
            log.info("出现错误,错误原因:" + e.getMessage());
@@ -3676,7 +3827,12 @@
                            if (!labelList.contains(s))
                                iterator.remove();
                        }
                        comMngPopulationCommunityTagsDO.setLabel(Joiner.on(",").join(userTag));
                        if(StringUtils.isNotEmpty(comMngPopulationCommunityTagsDO.getLabel())){
                            comMngPopulationCommunityTagsDO.setLabel(comMngPopulationCommunityTagsDO.getLabel()+","+Joiner.on(",").join(userTag));
                        }
                        else{
                            comMngPopulationCommunityTagsDO.setLabel(Joiner.on(",").join(userTag));
                        }
                        comMngPopulationCommunityTagsDO.setUpdateBy(userId);
                        updatePopulationCommunityList.add(comMngPopulationCommunityTagsDO);
@@ -3687,7 +3843,19 @@
                        mistakes.add(mistake);
                    }
                }
                log.info("查询实有人口存在社区信息完成");
                log.info("开始处理楼栋信息");
                List<ComMngBuildingDO> comMngBuildingDOList= comMngBuildingDAO.selectList(new QueryWrapper<ComMngBuildingDO>().lambda().eq(ComMngBuildingDO::getVillageId,comMngVillageDO.getVillageId()).eq(ComMngBuildingDO::getName,vo.getFloor()));
                if(comMngBuildingDOList.isEmpty()){
                   ComMngBuildingDO  comMngBuildingDO=new ComMngBuildingDO();
                   comMngBuildingDO.setVillageId(comMngVillageDO.getVillageId());
                   comMngBuildingDO.setName(vo.getFloor());
                   comMngBuildingDO.setActId(comMngVillageDO.getCommunityId());
                   comMngBuildingDO.setStreetId(comMngBuildingDO.getStreetId());
                   comMngBuildingDAO.insert(comMngBuildingDO);
                }
            }
        } catch (Exception e) {
            log.info("出现错误,错误原因:" + e.getMessage());
@@ -3986,7 +4154,12 @@
                            if (!labelList.contains(s))
                                iterator.remove();
                        }
                        comMngPopulationCommunityTagsDO.setLabel(Joiner.on(",").join(userTag));
                        if(StringUtils.isNotEmpty(comMngPopulationCommunityTagsDO.getLabel())){
                            comMngPopulationCommunityTagsDO.setLabel(comMngPopulationCommunityTagsDO.getLabel()+","+Joiner.on(",").join(userTag));
                        }
                        else{
                            comMngPopulationCommunityTagsDO.setLabel(Joiner.on(",").join(userTag));
                        }
                        comMngPopulationCommunityTagsDO.setUpdateBy(userId);
                        updatePopulationCommunityList.add(comMngPopulationCommunityTagsDO);
@@ -3997,7 +4170,19 @@
                        mistakes.add(mistake);
                    }
                }
                log.info("查询实有人口存在社区信息完成");
                log.info("开始处理楼栋信息");
                List<ComMngBuildingDO> comMngBuildingDOList= comMngBuildingDAO.selectList(new QueryWrapper<ComMngBuildingDO>().lambda().eq(ComMngBuildingDO::getVillageId,comMngVillageDO.getVillageId()).eq(ComMngBuildingDO::getName,vo.getFloor()));
                if(comMngBuildingDOList.isEmpty()){
                   ComMngBuildingDO  comMngBuildingDO=new ComMngBuildingDO();
                   comMngBuildingDO.setVillageId(comMngVillageDO.getVillageId());
                   comMngBuildingDO.setName(vo.getFloor());
                   comMngBuildingDO.setActId(comMngVillageDO.getCommunityId());
                   comMngBuildingDO.setStreetId(comMngBuildingDO.getStreetId());
                   comMngBuildingDAO.insert(comMngBuildingDO);
                }
            }
        } catch (Exception e) {
            log.info("出现错误,错误原因:" + e.getMessage());
@@ -4306,7 +4491,19 @@
                        mistakes.add(mistake);
                    }
                }
                log.info("查询实有人口存在社区信息完成");
                log.info("开始处理楼栋信息");
                List<ComMngBuildingDO> comMngBuildingDOList= comMngBuildingDAO.selectList(new QueryWrapper<ComMngBuildingDO>().lambda().eq(ComMngBuildingDO::getVillageId,comMngVillageDO.getVillageId()).eq(ComMngBuildingDO::getName,vo.getFloor()));
                if(comMngBuildingDOList.isEmpty()){
                   ComMngBuildingDO  comMngBuildingDO=new ComMngBuildingDO();
                   comMngBuildingDO.setVillageId(comMngVillageDO.getVillageId());
                   comMngBuildingDO.setName(vo.getFloor());
                   comMngBuildingDO.setActId(comMngVillageDO.getCommunityId());
                   comMngBuildingDO.setStreetId(comMngBuildingDO.getStreetId());
                   comMngBuildingDAO.insert(comMngBuildingDO);
                }
            }
        } catch (Exception e) {
            log.info("出现错误,错误原因:" + e.getMessage());
@@ -4614,7 +4811,19 @@
                        mistakes.add(mistake);
                    }
                }
                log.info("查询实有人口存在社区信息完成");
                log.info("开始处理楼栋信息");
                List<ComMngBuildingDO> comMngBuildingDOList= comMngBuildingDAO.selectList(new QueryWrapper<ComMngBuildingDO>().lambda().eq(ComMngBuildingDO::getVillageId,comMngVillageDO.getVillageId()).eq(ComMngBuildingDO::getName,vo.getFloor()));
                if(comMngBuildingDOList.isEmpty()){
                   ComMngBuildingDO  comMngBuildingDO=new ComMngBuildingDO();
                   comMngBuildingDO.setVillageId(comMngVillageDO.getVillageId());
                   comMngBuildingDO.setName(vo.getFloor());
                   comMngBuildingDO.setActId(comMngVillageDO.getCommunityId());
                   comMngBuildingDO.setStreetId(comMngBuildingDO.getStreetId());
                   comMngBuildingDAO.insert(comMngBuildingDO);
                }
            }
        } catch (Exception e) {
            log.info("出现错误,错误原因:" + e.getMessage());