101captain
2022-06-17 a3c4d4a9520ffb32f98cf07e835a90613e52abc4
bug修改
3个文件已修改
10 ■■■■■ 已修改文件
springcloud_k8s_panzhihuazhihuishequ/service_partybuilding/src/main/java/com/panzhihua/service_dangjian/dao/ComPbCheckUnitMapper.java 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
springcloud_k8s_panzhihuazhihuishequ/service_partybuilding/src/main/java/com/panzhihua/service_dangjian/service/impl/ComPbCheckUnitServiceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
springcloud_k8s_panzhihuazhihuishequ/service_partybuilding/src/main/resources/mapper/ComPbCheckUnitMapper.xml 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
springcloud_k8s_panzhihuazhihuishequ/service_partybuilding/src/main/java/com/panzhihua/service_dangjian/dao/ComPbCheckUnitMapper.java
@@ -54,5 +54,7 @@
     * @date 2022-02-16 16:22:18
     */
    List<ComPbCheckUnitVo> queryAllByList(@Param("dto") PageComPbCheckUnitDto comPbCheckUnit);
    Long selectCommunityId(@Param("area") String area,@Param("town")String town,@Param("community")String community);
}
springcloud_k8s_panzhihuazhihuishequ/service_partybuilding/src/main/java/com/panzhihua/service_dangjian/service/impl/ComPbCheckUnitServiceImpl.java
@@ -80,8 +80,12 @@
    @Override
    @Transactional
    public R insert(AddComPbCheckUnitDto comPbCheckUnit) {
        Long communityId=this.baseMapper.selectCommunityId(comPbCheckUnit.getHelpCommunityName().split(",")[0],comPbCheckUnit.getHelpCommunityName().split(",")[1],comPbCheckUnit.getHelpCommunityName().split(",")[2]);
        ComPbCheckUnit entity = new ComPbCheckUnit();
        BeanUtils.copyProperties(comPbCheckUnit, entity);
        if(communityId!=null){
            entity.setCommunityId(communityId);
        }
        if (this.baseMapper.insert(entity) > 0) {
            return R.ok();
        }
springcloud_k8s_panzhihuazhihuishequ/service_partybuilding/src/main/resources/mapper/ComPbCheckUnitMapper.xml
@@ -82,5 +82,9 @@
        order by cpcu.create_at desc
    </select>
    <select id="selectCommunityId" resultType="Integer">
        select community_id from com_area_town_community where area=#{area} and town=#{town} and community=#{community}
    </select>
</mapper>