From 8f15203c0eb8fbc43761593eacff9bb692929ecc Mon Sep 17 00:00:00 2001 From: sunyuchao Date: Fri, 22 Jul 2022 11:01:49 +0800 Subject: [PATCH 001/155] =?UTF-8?q?=E5=B7=A5=E4=BD=9C=E4=BA=BA=E5=91=98?= =?UTF-8?q?=E8=A1=A8=E6=96=B0=E5=A2=9E=E8=BA=AB=E4=BB=BD=E8=AF=81=E5=8F=B7?= =?UTF-8?q?=E5=AD=97=E6=AE=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/java/com/epmet/dto/CustomerStaffDTO.java | 6 ++++++ .../src/main/java/com/epmet/entity/CustomerStaffEntity.java | 5 +++++ 2 files changed, 11 insertions(+) diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/CustomerStaffDTO.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/CustomerStaffDTO.java index 71efe0c029..5f6e2685a3 100644 --- a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/CustomerStaffDTO.java +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/CustomerStaffDTO.java @@ -138,4 +138,10 @@ public class CustomerStaffDTO implements Serializable { * 登录密码 */ private String password; + + /** + * 身份证号 + */ + private String idCard; + } \ No newline at end of file diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/entity/CustomerStaffEntity.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/entity/CustomerStaffEntity.java index 86bedb482c..690bf326c2 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/entity/CustomerStaffEntity.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/entity/CustomerStaffEntity.java @@ -101,4 +101,9 @@ public class CustomerStaffEntity extends BaseEpmetEntity { * 登录密码 */ private String password; + + /** + * 身份证号 + */ + private String idCard; } From 422b6b05ce212d6d30610ee435e940e06b81ed08 Mon Sep 17 00:00:00 2001 From: wangxianzhang Date: Fri, 22 Jul 2022 11:14:10 +0800 Subject: [PATCH 002/155] =?UTF-8?q?=E3=80=90=E5=AF=B9=E6=8E=A5=E5=BA=93?= =?UTF-8?q?=E4=BB=A3=E7=A0=81=E7=94=9F=E6=88=90=E3=80=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../EventreportPingyinController.java | 31 +++ .../controller/GridInfoPingyinController.java | 31 +++ .../GridstaffInfoPingyinController.java | 30 +++ .../GridstaffWorkInfoPingyinController.java | 32 +++ .../opendata/dao/EventreportPingyinDao.java | 16 ++ .../opendata/dao/GridInfoPingyinDao.java | 16 ++ .../opendata/dao/GridstaffInfoPingyinDao.java | 16 ++ .../dao/GridstaffWorkInfoPingyinDao.java | 16 ++ .../entity/EventreportPingyinEntity.java | 195 ++++++++++++++++++ .../entity/GridInfoPingyinEntity.java | 105 ++++++++++ .../entity/GridstaffInfoPingyinEntity.java | 159 ++++++++++++++ .../GridstaffWorkInfoPingyinEntity.java | 89 ++++++++ .../service/EventreportPingyinService.java | 14 ++ .../service/GridInfoPingyinService.java | 16 ++ .../service/GridstaffInfoPingyinService.java | 16 ++ .../GridstaffWorkInfoPingyinService.java | 16 ++ .../impl/EventreportPingyinServiceImpl.java | 19 ++ .../impl/GridInfoPingyinServiceImpl.java | 19 ++ .../impl/GridstaffInfoPingyinServiceImpl.java | 18 ++ .../GridstaffWorkInfoPingyinServiceImpl.java | 17 ++ .../mapper/EventreportPingyinDao.xml | 44 ++++ .../resources/mapper/GridInfoPingyinDao.xml | 26 +++ .../mapper/GridstaffInfoPingyinDao.xml | 37 ++++ .../mapper/GridstaffWorkInfoPingyinDao.xml | 23 +++ 24 files changed, 1001 insertions(+) create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/EventreportPingyinController.java create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/GridInfoPingyinController.java create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/GridstaffInfoPingyinController.java create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/GridstaffWorkInfoPingyinController.java create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/EventreportPingyinDao.java create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridInfoPingyinDao.java create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridstaffInfoPingyinDao.java create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridstaffWorkInfoPingyinDao.java create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/EventreportPingyinEntity.java create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridInfoPingyinEntity.java create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridstaffInfoPingyinEntity.java create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridstaffWorkInfoPingyinEntity.java create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/EventreportPingyinService.java create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/GridInfoPingyinService.java create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/GridstaffInfoPingyinService.java create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/GridstaffWorkInfoPingyinService.java create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffWorkInfoPingyinServiceImpl.java create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/EventreportPingyinDao.xml create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridInfoPingyinDao.xml create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridstaffInfoPingyinDao.xml create mode 100755 epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridstaffWorkInfoPingyinDao.xml diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/EventreportPingyinController.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/EventreportPingyinController.java new file mode 100755 index 0000000000..fabedc32da --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/EventreportPingyinController.java @@ -0,0 +1,31 @@ +package com.epmet.opendata.controller; + +import com.epmet.commons.tools.aop.NoRepeatSubmit; +import com.epmet.commons.tools.utils.ExcelUtils; +import com.epmet.commons.tools.utils.Result; +import com.epmet.commons.tools.validator.AssertUtils; +import com.epmet.commons.tools.validator.ValidatorUtils; +import com.epmet.commons.tools.validator.group.AddGroup; +import com.epmet.commons.tools.validator.group.UpdateGroup; +import com.epmet.commons.tools.validator.group.DefaultGroup; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.*; + +import javax.servlet.http.HttpServletResponse; +import java.util.List; +import java.util.Map; + + +/** + * 平阴区事件上报中间表 + * + * @author generator generator@elink-cn.com + * @since v1.0.0 2022-07-22 + */ +@RestController +@RequestMapping("eventreportPingyin") +public class EventreportPingyinController { + + + +} diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/GridInfoPingyinController.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/GridInfoPingyinController.java new file mode 100755 index 0000000000..26e84cad1a --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/GridInfoPingyinController.java @@ -0,0 +1,31 @@ +package com.epmet.opendata.controller; + +import com.epmet.commons.tools.aop.NoRepeatSubmit; +import com.epmet.commons.tools.page.PageData; +import com.epmet.commons.tools.utils.ExcelUtils; +import com.epmet.commons.tools.utils.Result; +import com.epmet.commons.tools.validator.AssertUtils; +import com.epmet.commons.tools.validator.ValidatorUtils; +import com.epmet.commons.tools.validator.group.AddGroup; +import com.epmet.commons.tools.validator.group.UpdateGroup; +import com.epmet.commons.tools.validator.group.DefaultGroup; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.*; + +import javax.servlet.http.HttpServletResponse; +import java.util.Map; + + +/** + * 平阴区网格表 + * + * @author generator generator@elink-cn.com + * @since v1.0.0 2022-07-22 + */ +@RestController +@RequestMapping("gridInfoPingyin") +public class GridInfoPingyinController { + + + +} diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/GridstaffInfoPingyinController.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/GridstaffInfoPingyinController.java new file mode 100755 index 0000000000..9fb4b2a2a2 --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/GridstaffInfoPingyinController.java @@ -0,0 +1,30 @@ +package com.epmet.opendata.controller; + +import com.epmet.commons.tools.aop.NoRepeatSubmit; +import com.epmet.commons.tools.utils.ExcelUtils; +import com.epmet.commons.tools.utils.Result; +import com.epmet.commons.tools.validator.AssertUtils; +import com.epmet.commons.tools.validator.ValidatorUtils; +import com.epmet.commons.tools.validator.group.AddGroup; +import com.epmet.commons.tools.validator.group.UpdateGroup; +import com.epmet.commons.tools.validator.group.DefaultGroup; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.*; + +import javax.servlet.http.HttpServletResponse; +import java.util.Map; + + +/** + * 平阴区网格员基础信息 + * + * @author generator generator@elink-cn.com + * @since v1.0.0 2022-07-22 + */ +@RestController +@RequestMapping("gridstaffInfoPingyin") +public class GridstaffInfoPingyinController { + + + +} diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/GridstaffWorkInfoPingyinController.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/GridstaffWorkInfoPingyinController.java new file mode 100755 index 0000000000..3dd7d54d03 --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/GridstaffWorkInfoPingyinController.java @@ -0,0 +1,32 @@ +package com.epmet.opendata.controller; + +import com.epmet.commons.tools.aop.NoRepeatSubmit; +import com.epmet.commons.tools.page.PageData; +import com.epmet.commons.tools.utils.ExcelUtils; +import com.epmet.commons.tools.utils.Result; +import com.epmet.commons.tools.validator.AssertUtils; +import com.epmet.commons.tools.validator.ValidatorUtils; +import com.epmet.commons.tools.validator.group.AddGroup; +import com.epmet.commons.tools.validator.group.UpdateGroup; +import com.epmet.commons.tools.validator.group.DefaultGroup; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.*; + +import javax.servlet.http.HttpServletResponse; +import java.util.List; +import java.util.Map; + + +/** + * 平阴区网格员例行工作信息 + * + * @author generator generator@elink-cn.com + * @since v1.0.0 2022-07-22 + */ +@RestController +@RequestMapping("gridstaffWorkInfoPingyin") +public class GridstaffWorkInfoPingyinController { + + + +} diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/EventreportPingyinDao.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/EventreportPingyinDao.java new file mode 100755 index 0000000000..ec20e7f1c4 --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/EventreportPingyinDao.java @@ -0,0 +1,16 @@ +package com.epmet.opendata.dao; + +import com.epmet.commons.mybatis.dao.BaseDao; +import com.epmet.opendata.entity.EventreportPingyinEntity; +import org.apache.ibatis.annotations.Mapper; + +/** + * 平阴区事件上报中间表 + * + * @author generator generator@elink-cn.com + * @since v1.0.0 2022-07-22 + */ +@Mapper +public interface EventreportPingyinDao extends BaseDao { + +} \ No newline at end of file diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridInfoPingyinDao.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridInfoPingyinDao.java new file mode 100755 index 0000000000..fc6be9e1db --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridInfoPingyinDao.java @@ -0,0 +1,16 @@ +package com.epmet.opendata.dao; + +import com.epmet.commons.mybatis.dao.BaseDao; +import com.epmet.opendata.entity.GridInfoPingyinEntity; +import org.apache.ibatis.annotations.Mapper; + +/** + * 平阴区网格表 + * + * @author generator generator@elink-cn.com + * @since v1.0.0 2022-07-22 + */ +@Mapper +public interface GridInfoPingyinDao extends BaseDao { + +} \ No newline at end of file diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridstaffInfoPingyinDao.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridstaffInfoPingyinDao.java new file mode 100755 index 0000000000..05b862b40f --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridstaffInfoPingyinDao.java @@ -0,0 +1,16 @@ +package com.epmet.opendata.dao; + +import com.epmet.commons.mybatis.dao.BaseDao; +import com.epmet.opendata.entity.GridstaffInfoPingyinEntity; +import org.apache.ibatis.annotations.Mapper; + +/** + * 平阴区网格员基础信息 + * + * @author generator generator@elink-cn.com + * @since v1.0.0 2022-07-22 + */ +@Mapper +public interface GridstaffInfoPingyinDao extends BaseDao { + +} \ No newline at end of file diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridstaffWorkInfoPingyinDao.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridstaffWorkInfoPingyinDao.java new file mode 100755 index 0000000000..d515ae9fd6 --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridstaffWorkInfoPingyinDao.java @@ -0,0 +1,16 @@ +package com.epmet.opendata.dao; + +import com.epmet.commons.mybatis.dao.BaseDao; +import com.epmet.opendata.entity.GridstaffWorkInfoPingyinEntity; +import org.apache.ibatis.annotations.Mapper; + +/** + * 平阴区网格员例行工作信息 + * + * @author generator generator@elink-cn.com + * @since v1.0.0 2022-07-22 + */ +@Mapper +public interface GridstaffWorkInfoPingyinDao extends BaseDao { + +} \ No newline at end of file diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/EventreportPingyinEntity.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/EventreportPingyinEntity.java new file mode 100755 index 0000000000..84cddbe1d3 --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/EventreportPingyinEntity.java @@ -0,0 +1,195 @@ +package com.epmet.opendata.entity; + +import com.baomidou.mybatisplus.annotation.TableName; + +import com.epmet.commons.mybatis.entity.BaseEpmetEntity; +import lombok.Data; +import lombok.EqualsAndHashCode; + +import java.math.BigDecimal; +import java.util.Date; + +/** + * 平阴区事件上报中间表 + * + * @author generator generator@elink-cn.com + * @since v1.0.0 2022-07-22 + */ +@Data +@EqualsAndHashCode(callSuper=false) +@TableName("eventreport_pingyin") +public class EventreportPingyinEntity { + + private static final long serialVersionUID = 1L; + + /** + * 数据库主键自增字段,请勿指定 + */ + private Long id; + + /** + * 上报区县代码,参照6位行政区划代码 + */ + private String qxBm; + + /** + * 上报区县名称 + */ + private String qxMc; + + /** + * 网格编码,参照《山东省社会治理网格化智能工作平台数据标准》 + */ + private String gridCode; + + /** + * 网格名称 + */ + private String gridName; + + /** + * 事件编号,可以使用区县系统中的事件唯一识别码 + */ + private String eventCode; + + /** + * 事件名称 + */ + private String eventName; + + /** + * 事件类别,参照《山东省社会治理网格化智能工作平台数据标准》10.19 + */ + private String eventCategory; + + /** + * 上报网格员姓名 + */ + private String gridUserName; + + /** + * 上报网格员的身份证号码 + */ + private String gridUserCardid; + + /** + * 事件上报时间 + */ + private Date reportTime; + + /** + * 事件发生时间 + */ + private Date happenTime; + + /** + * 事件发生地点描述 + */ + private String happenPlace; + + /** + * 事件简述,详细一些,文字数量不少于10字 + */ + private String eventDescription; + + /** + * 事件办结方式,符合《标准》10.20 + */ + private String waysOfResolving; + + /** + * 是否办结,填写Y、N(Y 是 N 否) + */ + private String successfulOrNo; + + /** + * 办结层级,符合《标准》10.21 + */ + private String completeLevel; + + /** + * 办结时间,办结后填写 + */ + private Date completeTime; + + /** + * 事件发生位置经度,wgs84坐标系,请勿用火星坐标系,不得跑出辖区 + */ + private BigDecimal lng; + + /** + * 事件发生位置纬度,wgs84坐标系,请勿用火星坐标系,不得跑出辖区 + */ + private BigDecimal lat; + + /** + * 事件主要当事人姓名 + */ + private String name; + + /** + * 事件涉及人数 + */ + private Integer numberInvolved; + + /** + * 事件涉及单位名称 + */ + private String relatedUnites; + + /** + * 出租人姓名 + */ + private String lessorName; + + /** + * 出租屋巡查结果,符合《标准》10.24 + */ + private String rentingResult; + + /** + * 重点场所类别,符合《标准》10.25 + */ + private String keyAreaType; + + /** + * 宗教活动规模,符合《标准》10.26 + */ + private String religionScale; + + /** + * 宗教类别,符合《标准》10.27 + */ + private String religionType; + + /** + * 重点场所是否变动,填写Y、N(Y 是 N 否) + */ + private String isKeyareaState; + + /** + * 重点人员是否在当地,填写Y、N(Y 是 N 否) + */ + private String isKeypeopleLocate; + + /** + * 重点人员现状描述 + */ + private String keypeopleStatus; + + /** + * 例行工作编辑插入、更新时间,县市区填写 + */ + private Date updateTime; + + /** + * 事件是否删除,Y:是、N:否 + */ + private String isDel; + + /** + * 入库时间,自动生成,请勿设置 + */ + private Date recoredInsertTime; + +} diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridInfoPingyinEntity.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridInfoPingyinEntity.java new file mode 100755 index 0000000000..6051db5f01 --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridInfoPingyinEntity.java @@ -0,0 +1,105 @@ +package com.epmet.opendata.entity; + +import com.baomidou.mybatisplus.annotation.TableName; + +import com.epmet.commons.mybatis.entity.BaseEpmetEntity; +import lombok.Data; +import lombok.EqualsAndHashCode; + +import java.math.BigDecimal; +import java.util.Date; + +/** + * 平阴区网格表 + * + * @author generator generator@elink-cn.com + * @since v1.0.0 2022-07-22 + */ +@Data +@EqualsAndHashCode(callSuper=false) +@TableName("grid_info_pingyin") +public class GridInfoPingyinEntity { + + private static final long serialVersionUID = 1L; + + /** + * 数据库主键自增字段,请勿指定 + */ + private Long id; + + /** + * 上报区县代码,参照6位行政区划代码 + */ + private String qxBm; + + /** + * 上报区县名称 + */ + private String qxMc; + + /** + * 网格编码,参照《标准》 + */ + private String gridCode; + + /** + * 网格名称 + */ + private String gridName; + + /** + * 网格层级,应符合10.1组织层级,所有层级上报 + */ + private Integer gridLevel; + + /** + * 专属网格类型,应符合10.28专属网格类型 + */ + private String gridType; + + /** + * 网格内人口规模,如果为农村和城市网格,字段必填,应符合10.29.网格内人口规模 + */ + private String populationSize; + + /** + * 是否成立网格党支部或网格党小组,Y:是、N:否 + */ + private String isPartyBranch; + + /** + * 网格党组织类型,是否成立党支部或党小组为是,此项必填。应符合10.37网格党组织类型。 + */ + private String partyBranchType; + + /** + * 网格中心点的经度 + */ + private BigDecimal lng; + + /** + * 网格中心点纬度 + */ + private BigDecimal lat; + + /** + * 网格颜色,如 #000000 + */ + private String gridColor; + + /** + * 网格信息编辑插入、更新时间,,县市区填写 + */ + private Date updateTime; + + /** + * 此网格是否删除,Y:是、N:否 + */ + private String isDel; + + /** + * 入库时间,自动生成,请勿设置 + */ + private Date recoredInsertTime; + +} diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridstaffInfoPingyinEntity.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridstaffInfoPingyinEntity.java new file mode 100755 index 0000000000..0a53873f89 --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridstaffInfoPingyinEntity.java @@ -0,0 +1,159 @@ +package com.epmet.opendata.entity; + +import com.baomidou.mybatisplus.annotation.TableName; + +import com.epmet.commons.mybatis.entity.BaseEpmetEntity; +import lombok.Data; +import lombok.EqualsAndHashCode; + +import java.util.Date; + +/** + * 平阴区网格员基础信息 + * + * @author generator generator@elink-cn.com + * @since v1.0.0 2022-07-22 + */ +@Data +@EqualsAndHashCode(callSuper=false) +@TableName("gridstaff_info_pingyin") +public class GridstaffInfoPingyinEntity { + + private static final long serialVersionUID = 1L; + + /** + * 数据库主键自增字段,请勿指定 + */ + private Long id; + + /** + * 上报区县代码,参照6位行政区划代码 + */ + private String qxBm; + + /** + * 上报区县名称 + */ + private String qxMc; + + /** + * 区县系统中的网格员唯一编码 + */ + private String gridUserId; + + /** + * 网格编码 + */ + private String gridCode; + + /** + * 网格名称 + */ + private String gridName; + + /** + * 网格员姓名 + */ + private String nickName; + + /** + * 网格员身份证号码 + */ + private String cardNum; + + /** + * 网格员类型,符合《标准》10.3 + */ + private String userType; + + /** + * 网格员手机号 + */ + private String phonenumber; + + /** + * 网格员性别,应符合10.31中性别,不要有 其他 + */ + private String sex; + + /** + * 网格员民族,应符合10.32中民族 + */ + private String nation; + + /** + * 网格员政治面貌,符合GB/T 4762 + */ + private String paerty; + + /** + * 网格员出生日期 + */ + private Date birthday; + + /** + * 网格员学历,符合GB/T4658,博士、研究生会进行预警 + */ + private String education; + + /** + * 入职时间,格式为“YYYY-MM-DD” + */ + private Date entryDate; + + /** + * 是否离职,格式为Y:是、N:否 + */ + private String isLeave; + + /** + * 离职时间,格式为“YYYY-MM-DD” + */ + private Date leaveDate; + + /** + * 网格员年收入,含福利、补贴和保险等,应符合10.30中的网格员年收入,专职低于1w5、兼职大于3w会预警 + */ + private String income; + + /** + * 是否社区(村)两委委员,Y:是、N:否 + */ + private String isCommittee; + + /** + * 是否社区工作者,Y:是、N:否 + */ + private String isCommunityWorkers; + + /** + * 是否社会工作者,Y:是、N:否 + */ + private String isSocialWorker; + + /** + * 是否村(居)民小组长,Y:是、N:否 + */ + private String isVillageLeader; + + /** + * 是否警务助理,Y:是、N:否 + */ + private String isPoliceAssistant; + + /** + * 是否人民调解员,Y:是、N:否 + */ + private String isMediator; + + /** + * 网格员信息编辑插入、更新时间,,县市区填写 + */ + private Date updateTime; + + /** + * 入库时间,自动生成,请勿设置 + */ + private Date recoredInsertTime; + +} diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridstaffWorkInfoPingyinEntity.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridstaffWorkInfoPingyinEntity.java new file mode 100755 index 0000000000..4583256c90 --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridstaffWorkInfoPingyinEntity.java @@ -0,0 +1,89 @@ +package com.epmet.opendata.entity; + +import com.baomidou.mybatisplus.annotation.TableName; + +import com.epmet.commons.mybatis.entity.BaseEpmetEntity; +import lombok.Data; +import lombok.EqualsAndHashCode; + +import java.util.Date; + +/** + * 平阴区网格员例行工作信息 + * + * @author generator generator@elink-cn.com + * @since v1.0.0 2022-07-22 + */ +@Data +@EqualsAndHashCode(callSuper=false) +@TableName("gridstaff_work_info_pingyin") +public class GridstaffWorkInfoPingyinEntity { + + private static final long serialVersionUID = 1L; + + /** + * 主键 + */ + private String id; + + /** + * 上报区县代码,参照6位行政区划代码 + */ + private String qxBm; + + /** + * 上报区县名称 + */ + private String qxMc; + + /** + * 网格编码 + */ + private String gridCode; + + /** + * 网格名称 + */ + private String gridName; + + /** + * 例行工作类型,应符合10.27中的例行工作类型 + */ + private String workType; + + /** + * 发生日期,格式为“YYYY-MM-DD” + */ + private Date happenTime; + + /** + * 基础信息主键,出租房巡查、重点场所巡查、刑满释放人员、社区矫正、吸毒人员、信访人员重点青少年和精神障碍者必填 + */ + private Integer baseInfoId; + + /** + * 有无变动(异常),Y:是、N:否 + */ + private String workResult; + + /** + * 说明 + */ + private String workContent; + + /** + * 例行工作编辑插入、更新时间,,县市区填写 + */ + private Date updateTime; + + /** + * 例行工作是否删除,Y:是、N:否 + */ + private String isDel; + + /** + * 入库时间,自动生成,请勿设置 + */ + private Date recoredInsertTime; + +} diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/EventreportPingyinService.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/EventreportPingyinService.java new file mode 100755 index 0000000000..68433043d3 --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/EventreportPingyinService.java @@ -0,0 +1,14 @@ +package com.epmet.opendata.service; + + +import com.epmet.commons.mybatis.service.BaseService; +import com.epmet.opendata.entity.EventreportPingyinEntity; + +/** + * 平阴区事件上报中间表 + * + * @author generator generator@elink-cn.com + * @since v1.0.0 2022-07-22 + */ +public interface EventreportPingyinService extends BaseService { +} \ No newline at end of file diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/GridInfoPingyinService.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/GridInfoPingyinService.java new file mode 100755 index 0000000000..096739ee37 --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/GridInfoPingyinService.java @@ -0,0 +1,16 @@ +package com.epmet.opendata.service; + +import com.epmet.commons.mybatis.service.BaseService; +import com.epmet.opendata.entity.GridInfoPingyinEntity; + +import java.util.Map; + +/** + * 平阴区网格表 + * + * @author generator generator@elink-cn.com + * @since v1.0.0 2022-07-22 + */ +public interface GridInfoPingyinService extends BaseService { + +} \ No newline at end of file diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/GridstaffInfoPingyinService.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/GridstaffInfoPingyinService.java new file mode 100755 index 0000000000..ccf0cbc681 --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/GridstaffInfoPingyinService.java @@ -0,0 +1,16 @@ +package com.epmet.opendata.service; + +import com.epmet.commons.mybatis.service.BaseService; +import com.epmet.opendata.entity.GridstaffInfoPingyinEntity; + +import java.util.Map; + +/** + * 平阴区网格员基础信息 + * + * @author generator generator@elink-cn.com + * @since v1.0.0 2022-07-22 + */ +public interface GridstaffInfoPingyinService extends BaseService { + +} \ No newline at end of file diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/GridstaffWorkInfoPingyinService.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/GridstaffWorkInfoPingyinService.java new file mode 100755 index 0000000000..39c7d2bfe8 --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/GridstaffWorkInfoPingyinService.java @@ -0,0 +1,16 @@ +package com.epmet.opendata.service; + +import com.epmet.commons.mybatis.service.BaseService; +import com.epmet.opendata.entity.GridstaffWorkInfoPingyinEntity; + +import java.util.Map; + +/** + * 平阴区网格员例行工作信息 + * + * @author generator generator@elink-cn.com + * @since v1.0.0 2022-07-22 + */ +public interface GridstaffWorkInfoPingyinService extends BaseService { + +} \ No newline at end of file diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java new file mode 100755 index 0000000000..7a4a5e69ac --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java @@ -0,0 +1,19 @@ +package com.epmet.opendata.service.impl; + +import com.epmet.commons.mybatis.service.impl.BaseServiceImpl; +import com.epmet.opendata.dao.EventreportPingyinDao; +import com.epmet.opendata.entity.EventreportPingyinEntity; +import com.epmet.opendata.service.EventreportPingyinService; +import org.springframework.stereotype.Service; + +/** + * 平阴区事件上报中间表 + * + * @author generator generator@elink-cn.com + * @since v1.0.0 2022-07-22 + */ +@Service +public class EventreportPingyinServiceImpl extends BaseServiceImpl implements EventreportPingyinService { + + +} \ No newline at end of file diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java new file mode 100755 index 0000000000..2e0574706a --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java @@ -0,0 +1,19 @@ +package com.epmet.opendata.service.impl; + +import com.epmet.commons.mybatis.service.impl.BaseServiceImpl; +import com.epmet.opendata.dao.GridInfoPingyinDao; +import com.epmet.opendata.entity.GridInfoPingyinEntity; +import com.epmet.opendata.service.GridInfoPingyinService; +import org.springframework.stereotype.Service; + + +/** + * 平阴区网格表 + * + * @author generator generator@elink-cn.com + * @since v1.0.0 2022-07-22 + */ +@Service +public class GridInfoPingyinServiceImpl extends BaseServiceImpl implements GridInfoPingyinService { + +} \ No newline at end of file diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java new file mode 100755 index 0000000000..6bd94f326d --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java @@ -0,0 +1,18 @@ +package com.epmet.opendata.service.impl; + +import com.epmet.commons.mybatis.service.impl.BaseServiceImpl; +import com.epmet.opendata.dao.GridstaffInfoPingyinDao; +import com.epmet.opendata.entity.GridstaffInfoPingyinEntity; +import com.epmet.opendata.service.GridstaffInfoPingyinService; +import org.springframework.stereotype.Service; + +/** + * 平阴区网格员基础信息 + * + * @author generator generator@elink-cn.com + * @since v1.0.0 2022-07-22 + */ +@Service +public class GridstaffInfoPingyinServiceImpl extends BaseServiceImpl implements GridstaffInfoPingyinService { + +} \ No newline at end of file diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffWorkInfoPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffWorkInfoPingyinServiceImpl.java new file mode 100755 index 0000000000..405640c9db --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffWorkInfoPingyinServiceImpl.java @@ -0,0 +1,17 @@ +package com.epmet.opendata.service.impl; + +import com.epmet.commons.mybatis.service.impl.BaseServiceImpl; +import com.epmet.opendata.dao.GridstaffWorkInfoPingyinDao; +import com.epmet.opendata.entity.GridstaffWorkInfoPingyinEntity; +import com.epmet.opendata.service.GridstaffWorkInfoPingyinService; +import org.springframework.stereotype.Service; + +/** + * 平阴区网格员例行工作信息 + * + * @author generator generator@elink-cn.com + * @since v1.0.0 2022-07-22 + */ +@Service +public class GridstaffWorkInfoPingyinServiceImpl extends BaseServiceImpl implements GridstaffWorkInfoPingyinService { +} \ No newline at end of file diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/EventreportPingyinDao.xml b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/EventreportPingyinDao.xml new file mode 100755 index 0000000000..a4e026b73b --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/EventreportPingyinDao.xml @@ -0,0 +1,44 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridInfoPingyinDao.xml b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridInfoPingyinDao.xml new file mode 100755 index 0000000000..3cb20d2d76 --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridInfoPingyinDao.xml @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridstaffInfoPingyinDao.xml b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridstaffInfoPingyinDao.xml new file mode 100755 index 0000000000..c42fd9482b --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridstaffInfoPingyinDao.xml @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridstaffWorkInfoPingyinDao.xml b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridstaffWorkInfoPingyinDao.xml new file mode 100755 index 0000000000..44396702fc --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridstaffWorkInfoPingyinDao.xml @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file From 7ccf7dc2d9749e5f8b8b974f3d42b4d6dbaa2f6d Mon Sep 17 00:00:00 2001 From: sunyuchao Date: Fri, 22 Jul 2022 14:06:59 +0800 Subject: [PATCH 003/155] =?UTF-8?q?=E5=AE=A2=E6=88=B7=E4=B8=8B=E5=B7=A5?= =?UTF-8?q?=E4=BD=9C=E4=BA=BA=E5=91=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dto/form/GridStaffUploadtFormDTO.java | 26 +++++++++++++ .../dto/result/GridStaffUploadResultDTO.java | 39 +++++++++++++++++++ .../epmet/feign/EpmetUserOpenFeignClient.java | 3 ++ .../EpmetUserOpenFeignClientFallback.java | 5 +++ .../controller/CustomerStaffController.java | 9 +++++ .../java/com/epmet/dao/CustomerStaffDao.java | 2 + .../epmet/service/CustomerStaffService.java | 2 + .../impl/CustomerStaffServiceImpl.java | 6 +++ .../resources/mapper/CustomerStaffDao.xml | 15 +++++++ 9 files changed, 107 insertions(+) create mode 100644 epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/GridStaffUploadtFormDTO.java create mode 100644 epmet-user/epmet-user-client/src/main/java/com/epmet/dto/result/GridStaffUploadResultDTO.java diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/GridStaffUploadtFormDTO.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/GridStaffUploadtFormDTO.java new file mode 100644 index 0000000000..687adcaafc --- /dev/null +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/GridStaffUploadtFormDTO.java @@ -0,0 +1,26 @@ +package com.epmet.dto.form; + +import lombok.Data; +import lombok.NoArgsConstructor; + +import java.util.List; + +/** + * @description: 网格工作人员数据上报-查询客户网格下有效工作人员信息数据 + * @author: sun + */ +@NoArgsConstructor +@Data +public class GridStaffUploadtFormDTO { + + /** + * 客户Id + */ + private String customerId; + /** + * 网格Id + */ + private List gridId; + + +} diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/result/GridStaffUploadResultDTO.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/result/GridStaffUploadResultDTO.java new file mode 100644 index 0000000000..bc1c086578 --- /dev/null +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/result/GridStaffUploadResultDTO.java @@ -0,0 +1,39 @@ +package com.epmet.dto.result; + +import com.fasterxml.jackson.annotation.JsonIgnore; +import lombok.Data; + +import java.util.List; + +/** + * @description: 网格工作人员数据上报-查询客户网格下有效工作人员信息数据 + * @author: sun + */ +@Data +public class GridStaffUploadResultDTO { + /** + * 区县系统中的网格员唯一编码 + */ + private String gridUserId; + + /** + * 网格员姓名 + */ + private String nickName; + + /** + * 网格员身份证号码 + */ + private String cardNum; + + /** + * 网格员手机号 + */ + private String phonenumber; + + /** + * 网格员性别,应符合10.31中性别,不要有 其他 + */ + private String sex; + +} diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java index d52625b704..84dfc8ecb6 100644 --- a/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java @@ -846,4 +846,7 @@ public interface EpmetUserOpenFeignClient { */ @PostMapping("/epmetuser/icResiUserDataSync/icDataSyncTask") Result icDataSyncTask(String customerId); + + @PostMapping("/epmetuser/customerstaff/gridstaffupload") + Result> gridStaffUploadt(@RequestBody GridStaffUploadtFormDTO formDTO); } diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/fallback/EpmetUserOpenFeignClientFallback.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/fallback/EpmetUserOpenFeignClientFallback.java index 56b203743a..701c47715d 100644 --- a/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/fallback/EpmetUserOpenFeignClientFallback.java +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/fallback/EpmetUserOpenFeignClientFallback.java @@ -641,4 +641,9 @@ public class EpmetUserOpenFeignClientFallback implements EpmetUserOpenFeignClien return ModuleUtils.feignConError(ServiceConstant.EPMET_USER_SERVER, "icDataSyncTask", customerId); } + @Override + public Result> gridStaffUploadt(GridStaffUploadtFormDTO formDTO) { + return ModuleUtils.feignConError(ServiceConstant.EPMET_USER_SERVER, "gridStaffUploadt", formDTO); + } + } diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java index 274cb8ed87..ccb7f1ba12 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java @@ -493,5 +493,14 @@ public class CustomerStaffController { return new Result>().ok(customerStaffService.gridMobileList(formDTO.getGridId(), tokenDto.getUserId())); } + /** + * @Author sun + * @Description 网格工作人员数据上报-查询客户网格下有效工作人员信息数据 + **/ + @PostMapping(value = "gridstaffupload") + public Result> gridStaffUploadt(@RequestBody GridStaffUploadtFormDTO formDTO) { + return new Result>().ok(customerStaffService.gridStaffUploadt(formDTO)); + } + } diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/dao/CustomerStaffDao.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/dao/CustomerStaffDao.java index 725a456b46..a21621d56f 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/dao/CustomerStaffDao.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/dao/CustomerStaffDao.java @@ -229,4 +229,6 @@ public interface CustomerStaffDao extends BaseDao { * @Description 工作人员基本信息 **/ List gridStaffMobileList(List staffIdList); + + List getStaffByCustomerId(@Param("customerId") String customerId); } diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/CustomerStaffService.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/CustomerStaffService.java index e986aa8f07..ce456354e3 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/CustomerStaffService.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/CustomerStaffService.java @@ -347,4 +347,6 @@ public interface CustomerStaffService extends BaseService { * @Description 【事件】网格员服务电话 **/ List gridMobileList(String gridId, String userId); + + List gridStaffUploadt(GridStaffUploadtFormDTO formDTO); } diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java index 024d3aed37..4653fc8316 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java @@ -856,4 +856,10 @@ public class CustomerStaffServiceImpl extends BaseServiceImpl gridStaffUploadt(GridStaffUploadtFormDTO formDTO) { + //1.查询客户下有效工作人员信息 + return baseDao.getStaffByCustomerId(formDTO.getCustomerId()); + } + } diff --git a/epmet-user/epmet-user-server/src/main/resources/mapper/CustomerStaffDao.xml b/epmet-user/epmet-user-server/src/main/resources/mapper/CustomerStaffDao.xml index 10965b93ce..4335ca3468 100644 --- a/epmet-user/epmet-user-server/src/main/resources/mapper/CustomerStaffDao.xml +++ b/epmet-user/epmet-user-server/src/main/resources/mapper/CustomerStaffDao.xml @@ -456,4 +456,19 @@ + + From b15826578238208a5d5241a6666a688b887c36d4 Mon Sep 17 00:00:00 2001 From: sunyuchao Date: Fri, 22 Jul 2022 14:38:09 +0800 Subject: [PATCH 004/155] =?UTF-8?q?=E7=BD=91=E6=A0=BC=E4=B8=8B=E5=B7=A5?= =?UTF-8?q?=E4=BD=9C=E4=BA=BA=E5=91=98=E5=88=97=E8=A1=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../form/CustomerGridStaffListFormDTO.java | 16 +++++++++ .../CustomerGridStaffListResultDTO.java | 34 +++++++++++++++++++ .../epmet/feign/GovOrgOpenFeignClient.java | 4 +++ .../GovOrgOpenFeignClientFallback.java | 5 +++ .../CustomerStaffGridController.java | 15 ++++++-- .../com/epmet/dao/CustomerStaffGridDao.java | 2 ++ .../service/CustomerStaffGridService.java | 3 ++ .../impl/CustomerStaffGridServiceImpl.java | 8 +++++ .../resources/mapper/CustomerStaffGridDao.xml | 16 +++++++++ .../dto/form/GridStaffUploadtFormDTO.java | 4 --- .../epmet/feign/EpmetUserOpenFeignClient.java | 4 +-- .../EpmetUserOpenFeignClientFallback.java | 4 +-- .../controller/CustomerStaffController.java | 6 ++-- .../epmet/service/CustomerStaffService.java | 2 +- .../impl/CustomerStaffServiceImpl.java | 2 +- 15 files changed, 109 insertions(+), 16 deletions(-) create mode 100644 epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/CustomerGridStaffListFormDTO.java create mode 100644 epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/CustomerGridStaffListResultDTO.java diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/CustomerGridStaffListFormDTO.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/CustomerGridStaffListFormDTO.java new file mode 100644 index 0000000000..49b8dbc6c6 --- /dev/null +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/CustomerGridStaffListFormDTO.java @@ -0,0 +1,16 @@ +package com.epmet.dto.form; + +import lombok.Data; + +import java.io.Serializable; + + +@Data +public class CustomerGridStaffListFormDTO implements Serializable { + + /** + * 客户Id + */ + private String customerId; + +} diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/CustomerGridStaffListResultDTO.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/CustomerGridStaffListResultDTO.java new file mode 100644 index 0000000000..9d138437e9 --- /dev/null +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/CustomerGridStaffListResultDTO.java @@ -0,0 +1,34 @@ +package com.epmet.dto.result; + +import lombok.Data; + +import java.io.Serializable; + +/** + * @Author sun + * @DESC + */ +@Data +public class CustomerGridStaffListResultDTO implements Serializable { + + /** + * 网格Id + */ + private String gridId; + + /** + * 网格编码 + */ + private String gridCode; + + /** + * 网格名 + */ + private String gridName; + + /** + * 区县系统中的网格员唯一编码 + */ + private String gridUserId; + +} diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/GovOrgOpenFeignClient.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/GovOrgOpenFeignClient.java index b7c17a255d..8ffbd28528 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/GovOrgOpenFeignClient.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/GovOrgOpenFeignClient.java @@ -695,4 +695,8 @@ public interface GovOrgOpenFeignClient { */ @PostMapping("/gov/org/coverage/dictinit/{customerId}") Result dictInit(@PathVariable(value = "customerId") String customerId); + + @PostMapping("/gov/org/customerstaffgrid/gridstaff") + Result> gridStaff(CustomerGridStaffListFormDTO dto); + } diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/fallback/GovOrgOpenFeignClientFallback.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/fallback/GovOrgOpenFeignClientFallback.java index 0a8e690f38..c64544ef0f 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/fallback/GovOrgOpenFeignClientFallback.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/fallback/GovOrgOpenFeignClientFallback.java @@ -445,4 +445,9 @@ public class GovOrgOpenFeignClientFallback implements GovOrgOpenFeignClient { return ModuleUtils.feignConError(ServiceConstant.GOV_ORG_SERVER, "dictInit", customerId); } + @Override + public Result> gridStaff(CustomerGridStaffListFormDTO dto) { + return ModuleUtils.feignConError(ServiceConstant.GOV_ORG_SERVER, "gridStaff", dto); + } + } diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerStaffGridController.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerStaffGridController.java index 8858cac625..392594a1da 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerStaffGridController.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerStaffGridController.java @@ -29,10 +29,10 @@ import com.epmet.commons.tools.validator.group.DefaultGroup; import com.epmet.commons.tools.validator.group.UpdateGroup; import com.epmet.dto.CustomerStaffGridDTO; import com.epmet.dto.form.CommonGridIdFormDTO; +import com.epmet.dto.form.CustomerGridStaffListFormDTO; +import com.epmet.dto.form.GridStaffUploadtFormDTO; import com.epmet.dto.form.LatestGridFormDTO; -import com.epmet.dto.result.CustomerGridByUserIdResultDTO; -import com.epmet.dto.result.EventTitleOrgResultDTO; -import com.epmet.dto.result.GridStaffResultDTO; +import com.epmet.dto.result.*; import com.epmet.excel.CustomerStaffGridExcel; import com.epmet.service.CustomerStaffGridService; import org.springframework.beans.factory.annotation.Autowired; @@ -156,4 +156,13 @@ public class CustomerStaffGridController { public Result> getAllStaffByGridId(@RequestParam("gridId")String gridId){ return new Result>().ok(customerStaffGridService.getAllStaffByGridId(gridId)); } + + /** + * @Author sun + * @Description 网格下工作人员列表 + **/ + @PostMapping(value = "gridstaff") + public Result> gridStaff(@RequestBody CustomerGridStaffListFormDTO formDTO) { + return new Result>().ok(customerStaffGridService.gridStaff(formDTO)); + } } \ No newline at end of file diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/dao/CustomerStaffGridDao.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/dao/CustomerStaffGridDao.java index ed00369f86..fa95c587e4 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/dao/CustomerStaffGridDao.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/dao/CustomerStaffGridDao.java @@ -22,6 +22,7 @@ import com.epmet.dto.CustomerGridDTO; import com.epmet.dto.CustomerStaffGridDTO; import com.epmet.dto.StaffOrgRelationDTO; import com.epmet.dto.form.LatestGridFormDTO; +import com.epmet.dto.result.CustomerGridStaffListResultDTO; import com.epmet.dto.result.EventTitleOrgResultDTO; import com.epmet.dto.result.GridStaffResultDTO; import com.epmet.entity.CustomerStaffGridEntity; @@ -130,4 +131,5 @@ public interface CustomerStaffGridDao extends BaseDao { */ List getAllStaffByGridId(String gridId); + List getGridStaffByCustomerId(@Param("customerId") String customerId); } diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/CustomerStaffGridService.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/CustomerStaffGridService.java index c6b606e7df..899256eaf4 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/CustomerStaffGridService.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/CustomerStaffGridService.java @@ -22,8 +22,10 @@ import com.epmet.commons.tools.page.PageData; import com.epmet.commons.tools.utils.Result; import com.epmet.dto.CustomerStaffGridDTO; import com.epmet.dto.form.CommonGridIdFormDTO; +import com.epmet.dto.form.CustomerGridStaffListFormDTO; import com.epmet.dto.form.LatestGridFormDTO; import com.epmet.dto.result.CustomerGridByUserIdResultDTO; +import com.epmet.dto.result.CustomerGridStaffListResultDTO; import com.epmet.dto.result.EventTitleOrgResultDTO; import com.epmet.dto.result.GridStaffResultDTO; import com.epmet.entity.CustomerStaffGridEntity; @@ -142,4 +144,5 @@ public interface CustomerStaffGridService extends BaseService getAllStaffByGridId(String gridId); + List gridStaff(CustomerGridStaffListFormDTO formDTO); } diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffGridServiceImpl.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffGridServiceImpl.java index 4cc572edc8..c80d01bb9e 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffGridServiceImpl.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffGridServiceImpl.java @@ -29,8 +29,10 @@ import com.epmet.dao.CustomerStaffGridDao; import com.epmet.dto.CustomerGridDTO; import com.epmet.dto.CustomerStaffGridDTO; import com.epmet.dto.form.CommonGridIdFormDTO; +import com.epmet.dto.form.CustomerGridStaffListFormDTO; import com.epmet.dto.form.LatestGridFormDTO; import com.epmet.dto.result.CustomerGridByUserIdResultDTO; +import com.epmet.dto.result.CustomerGridStaffListResultDTO; import com.epmet.dto.result.EventTitleOrgResultDTO; import com.epmet.dto.result.GridStaffResultDTO; import com.epmet.entity.CustomerStaffGridEntity; @@ -202,4 +204,10 @@ public class CustomerStaffGridServiceImpl extends BaseServiceImpl getAllStaffByGridId(String gridId) { return baseDao.getAllStaffByGridId(gridId); } + + @Override + public List gridStaff(CustomerGridStaffListFormDTO formDTO) { + return baseDao.getGridStaffByCustomerId(formDTO.getCustomerId()); + } + } diff --git a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerStaffGridDao.xml b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerStaffGridDao.xml index db1fa9571b..1cca1f20a0 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerStaffGridDao.xml +++ b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerStaffGridDao.xml @@ -196,4 +196,20 @@ WHERE DEL_FLAG = '0' AND GRID_ID = #{gridId} + + + diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/GridStaffUploadtFormDTO.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/GridStaffUploadtFormDTO.java index 687adcaafc..78cd488d87 100644 --- a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/GridStaffUploadtFormDTO.java +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/GridStaffUploadtFormDTO.java @@ -17,10 +17,6 @@ public class GridStaffUploadtFormDTO { * 客户Id */ private String customerId; - /** - * 网格Id - */ - private List gridId; } diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java index 84dfc8ecb6..58cc398678 100644 --- a/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java @@ -847,6 +847,6 @@ public interface EpmetUserOpenFeignClient { @PostMapping("/epmetuser/icResiUserDataSync/icDataSyncTask") Result icDataSyncTask(String customerId); - @PostMapping("/epmetuser/customerstaff/gridstaffupload") - Result> gridStaffUploadt(@RequestBody GridStaffUploadtFormDTO formDTO); + @PostMapping("/epmetuser/customerstaff/customerstaff") + Result> customerStaff(@RequestBody GridStaffUploadtFormDTO formDTO); } diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/fallback/EpmetUserOpenFeignClientFallback.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/fallback/EpmetUserOpenFeignClientFallback.java index 701c47715d..906c1a3e85 100644 --- a/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/fallback/EpmetUserOpenFeignClientFallback.java +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/fallback/EpmetUserOpenFeignClientFallback.java @@ -642,8 +642,8 @@ public class EpmetUserOpenFeignClientFallback implements EpmetUserOpenFeignClien } @Override - public Result> gridStaffUploadt(GridStaffUploadtFormDTO formDTO) { - return ModuleUtils.feignConError(ServiceConstant.EPMET_USER_SERVER, "gridStaffUploadt", formDTO); + public Result> customerStaff(GridStaffUploadtFormDTO formDTO) { + return ModuleUtils.feignConError(ServiceConstant.EPMET_USER_SERVER, "customerStaff", formDTO); } } diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java index ccb7f1ba12..586bacf3c2 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java @@ -497,9 +497,9 @@ public class CustomerStaffController { * @Author sun * @Description 网格工作人员数据上报-查询客户网格下有效工作人员信息数据 **/ - @PostMapping(value = "gridstaffupload") - public Result> gridStaffUploadt(@RequestBody GridStaffUploadtFormDTO formDTO) { - return new Result>().ok(customerStaffService.gridStaffUploadt(formDTO)); + @PostMapping(value = "customerstaff") + public Result> customerStaff(@RequestBody GridStaffUploadtFormDTO formDTO) { + return new Result>().ok(customerStaffService.customerStaff(formDTO)); } diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/CustomerStaffService.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/CustomerStaffService.java index ce456354e3..3f0819ad85 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/CustomerStaffService.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/CustomerStaffService.java @@ -348,5 +348,5 @@ public interface CustomerStaffService extends BaseService { **/ List gridMobileList(String gridId, String userId); - List gridStaffUploadt(GridStaffUploadtFormDTO formDTO); + List customerStaff(GridStaffUploadtFormDTO formDTO); } diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java index 4653fc8316..ef4ca7de13 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java @@ -857,7 +857,7 @@ public class CustomerStaffServiceImpl extends BaseServiceImpl gridStaffUploadt(GridStaffUploadtFormDTO formDTO) { + public List customerStaff(GridStaffUploadtFormDTO formDTO) { //1.查询客户下有效工作人员信息 return baseDao.getStaffByCustomerId(formDTO.getCustomerId()); } From 508caf19c97921f7345636d10c9660037e09cd9b Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Fri, 22 Jul 2022 15:42:06 +0800 Subject: [PATCH 005/155] =?UTF-8?q?=E7=BB=84=E7=BB=87=E7=BD=91=E6=A0=BC?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E6=8A=BD=E5=8F=96=E5=88=B0pingyin?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dto/org/result/CustomerAgencyDTO.java | 10 ++ .../feign/DataStatisticalOpenFeignClient.java | 4 +- .../resources/mapper/org/CustomerGridDao.xml | 2 + .../mapper/org/StatsCustomerAgencyDao.xml | 2 + .../form/ExractGridInfoPingYinFormDTO.java | 38 ++++ .../controller/GridInfoPingyinController.java | 39 +++-- .../opendata/dao/GridInfoPingyinDao.java | 17 +- .../OpenDataOrgChangeEventListener.java | 30 +++- .../service/GridInfoPingyinService.java | 15 +- .../impl/GridInfoPingyinServiceImpl.java | 164 ++++++++++++++++++ .../resources/mapper/GridInfoPingyinDao.xml | 21 +++ 11 files changed, 318 insertions(+), 24 deletions(-) create mode 100644 epmet-module/open-data-worker/open-data-worker-client/src/main/java/com/epmet/opendata/dto/form/ExractGridInfoPingYinFormDTO.java diff --git a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/org/result/CustomerAgencyDTO.java b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/org/result/CustomerAgencyDTO.java index 658a3e9c2d..e281c7400e 100644 --- a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/org/result/CustomerAgencyDTO.java +++ b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/org/result/CustomerAgencyDTO.java @@ -147,4 +147,14 @@ public class CustomerAgencyDTO implements Serializable { * 社区 */ private String community; + + /** + * 中心位置经度 + */ + private String longitude; + + /** + * 中心位置纬度 + */ + private String latitude; } \ No newline at end of file diff --git a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/feign/DataStatisticalOpenFeignClient.java b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/feign/DataStatisticalOpenFeignClient.java index 67f56957dc..1c865240ea 100644 --- a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/feign/DataStatisticalOpenFeignClient.java +++ b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/feign/DataStatisticalOpenFeignClient.java @@ -36,8 +36,8 @@ import java.util.List; * @author: jianjun liu */ //url="http://localhost:8108" -//@FeignClient(name = ServiceConstant.DATA_STATISTICAL_SERVER, fallback = DataStatisticalOpenFeignClientFallBack.class, url = "http://localhost:6666") -@FeignClient(name = ServiceConstant.DATA_STATISTICAL_SERVER, fallbackFactory = DataStatisticalOpenFeignClientFallBackFactory.class) +@FeignClient(name = ServiceConstant.DATA_STATISTICAL_SERVER, fallbackFactory = DataStatisticalOpenFeignClientFallBackFactory.class, url = "http://localhost:8108") +// @FeignClient(name = ServiceConstant.DATA_STATISTICAL_SERVER, fallbackFactory = DataStatisticalOpenFeignClientFallBackFactory.class) public interface DataStatisticalOpenFeignClient { /** diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/CustomerGridDao.xml b/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/CustomerGridDao.xml index 7ab6ca322c..8622167974 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/CustomerGridDao.xml +++ b/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/CustomerGridDao.xml @@ -160,6 +160,8 @@ customer_grid WHERE del_flag = '0' AND customer_id = #{customerId} + and CODE is not null + and CODE !='' #{gridId} diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/StatsCustomerAgencyDao.xml b/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/StatsCustomerAgencyDao.xml index fa5da30046..105a4efcc7 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/StatsCustomerAgencyDao.xml +++ b/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/StatsCustomerAgencyDao.xml @@ -216,6 +216,8 @@ customer_agency WHERE del_flag = '0' AND customer_id = #{customerId} + and CODE is not null + and CODE !='' #{agencyId} diff --git a/epmet-module/open-data-worker/open-data-worker-client/src/main/java/com/epmet/opendata/dto/form/ExractGridInfoPingYinFormDTO.java b/epmet-module/open-data-worker/open-data-worker-client/src/main/java/com/epmet/opendata/dto/form/ExractGridInfoPingYinFormDTO.java new file mode 100644 index 0000000000..d57c25a387 --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-client/src/main/java/com/epmet/opendata/dto/form/ExractGridInfoPingYinFormDTO.java @@ -0,0 +1,38 @@ +package com.epmet.opendata.dto.form; + +import com.epmet.commons.tools.validator.group.CustomerClientShowGroup; +import lombok.Data; + +import javax.validation.constraints.NotBlank; +import java.io.Serializable; +import java.util.List; + +/** + * @Description + * @Author yzm + * @Date 2022/7/22 14:02 + */ +@Data +public class ExractGridInfoPingYinFormDTO implements Serializable { + + public interface GridInfo extends CustomerClientShowGroup { + } + + /** + * 客户Id + */ + @NotBlank(message = "客户Id不能为空", groups = {GridInfo.class}) + private String customerId = ""; + + /** + * 网格Id或者组织id + */ + private List orgIdList; + + /** + * 操作类型【新增:add 修改删除:edit 初始化所有数据:all】 + */ + @NotBlank(message = "操作类型【新增:add 修改删除:edit 初始化所有数据:all】不能为空", groups = {GridInfo.class}) + private String type; +} + diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/GridInfoPingyinController.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/GridInfoPingyinController.java index 26e84cad1a..2a1ac80444 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/GridInfoPingyinController.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/GridInfoPingyinController.java @@ -1,19 +1,14 @@ package com.epmet.opendata.controller; -import com.epmet.commons.tools.aop.NoRepeatSubmit; -import com.epmet.commons.tools.page.PageData; -import com.epmet.commons.tools.utils.ExcelUtils; import com.epmet.commons.tools.utils.Result; -import com.epmet.commons.tools.validator.AssertUtils; import com.epmet.commons.tools.validator.ValidatorUtils; -import com.epmet.commons.tools.validator.group.AddGroup; -import com.epmet.commons.tools.validator.group.UpdateGroup; -import com.epmet.commons.tools.validator.group.DefaultGroup; +import com.epmet.opendata.dto.form.ExractGridInfoPingYinFormDTO; +import com.epmet.opendata.service.GridInfoPingyinService; import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.web.bind.annotation.*; - -import javax.servlet.http.HttpServletResponse; -import java.util.Map; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; /** @@ -26,6 +21,28 @@ import java.util.Map; @RequestMapping("gridInfoPingyin") public class GridInfoPingyinController { + @Autowired + private GridInfoPingyinService gridInfoPingyinService; + /** + * @Author yzm + * @Description 组织基础信息中间库同步 + **/ + @PostMapping("extract-agency") + public Result getAgencyBaseInfo(@RequestBody ExractGridInfoPingYinFormDTO formDTO) { + ValidatorUtils.validateEntity(formDTO, ExractGridInfoPingYinFormDTO.GridInfo.class); + gridInfoPingyinService.exractAgency(formDTO); + return new Result(); + } + /** + * @Author yzm + * @Description 网格基础信息中间库同步 + **/ + @PostMapping("extract-grid") + public Result getGridBaseInfo(@RequestBody ExractGridInfoPingYinFormDTO formDTO) { + ValidatorUtils.validateEntity(formDTO, ExractGridInfoPingYinFormDTO.GridInfo.class); + gridInfoPingyinService.exractGrid(formDTO); + return new Result(); + } } diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridInfoPingyinDao.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridInfoPingyinDao.java index fc6be9e1db..e070cc30ce 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridInfoPingyinDao.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridInfoPingyinDao.java @@ -3,6 +3,10 @@ package com.epmet.opendata.dao; import com.epmet.commons.mybatis.dao.BaseDao; import com.epmet.opendata.entity.GridInfoPingyinEntity; import org.apache.ibatis.annotations.Mapper; +import org.apache.ibatis.annotations.Param; + +import java.math.BigDecimal; +import java.util.List; /** * 平阴区网格表 @@ -12,5 +16,16 @@ import org.apache.ibatis.annotations.Mapper; */ @Mapper public interface GridInfoPingyinDao extends BaseDao { - + + int deleteAllAgencyData(); + + int deleteAllGridData(); + + List selectByGridCode(String gridCode); + + int updateSomeCol(@Param("id") Long id, + @Param("gridName")String gridName, + @Param("gridLevel")Integer gridLevel, + @Param("lng")BigDecimal lng, + @Param("lat")BigDecimal lat); } \ No newline at end of file diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/mq/listener/OpenDataOrgChangeEventListener.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/mq/listener/OpenDataOrgChangeEventListener.java index 928489f8b0..02fc563a78 100644 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/mq/listener/OpenDataOrgChangeEventListener.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/mq/listener/OpenDataOrgChangeEventListener.java @@ -10,8 +10,8 @@ import com.epmet.commons.tools.exception.RenException; import com.epmet.commons.tools.redis.RedisKeys; import com.epmet.commons.tools.redis.RedisUtils; import com.epmet.commons.tools.utils.SpringContextUtils; -import com.epmet.opendata.dto.form.ExDeptFormDTO; -import com.epmet.opendata.service.ExDeptService; +import com.epmet.opendata.dto.form.ExractGridInfoPingYinFormDTO; +import com.epmet.opendata.service.GridInfoPingyinService; import org.apache.commons.lang.StringUtils; import org.apache.rocketmq.client.consumer.listener.ConsumeConcurrentlyContext; import org.apache.rocketmq.client.consumer.listener.ConsumeConcurrentlyStatus; @@ -78,17 +78,31 @@ public class OpenDataOrgChangeEventListener implements MessageListenerConcurrent lock = distributedLock.getLock(String.format("lock:open_data_org:%s", obj.getOrgId()), 30L, 30L, TimeUnit.SECONDS); - ExDeptFormDTO dto = new ExDeptFormDTO(); - dto.setCustomerId(obj.getCustomerId()); - dto.setType(obj.getType()); + // ExDeptFormDTO dto = new ExDeptFormDTO(); + // dto.setCustomerId(obj.getCustomerId()); + // dto.setType(obj.getType()); + // List orgIdList = new ArrayList<>(); + // orgIdList.add(obj.getOrgId()); + // dto.setOrgIdList(orgIdList); + // if ("agency".equals(obj.getOrgType())) { + // SpringContextUtils.getBean(ExDeptService.class).getAgencyBaseInfo(dto); + // } else { + // SpringContextUtils.getBean(ExDeptService.class).getGridBaseInfo(dto); + // } + + // 抽取到grid_info_pingyin + ExractGridInfoPingYinFormDTO extractFormDto = new ExractGridInfoPingYinFormDTO(); + extractFormDto.setCustomerId(obj.getCustomerId()); + extractFormDto.setType(obj.getType()); List orgIdList = new ArrayList<>(); orgIdList.add(obj.getOrgId()); - dto.setOrgIdList(orgIdList); + extractFormDto.setOrgIdList(orgIdList); if ("agency".equals(obj.getOrgType())) { - SpringContextUtils.getBean(ExDeptService.class).getAgencyBaseInfo(dto); + SpringContextUtils.getBean(GridInfoPingyinService.class).exractAgency(extractFormDto); } else { - SpringContextUtils.getBean(ExDeptService.class).getGridBaseInfo(dto); + SpringContextUtils.getBean(GridInfoPingyinService.class).exractGrid(extractFormDto); } + } catch (RenException e) { // 如果是我们手动抛出的异常,说明在业务可控范围内。目前不需要MQ重试 logger.error("【开放数据事件监听器】-组织信息变更-同步信息到中间库失败:".concat(ExceptionUtils.getErrorStackTrace(e))); diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/GridInfoPingyinService.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/GridInfoPingyinService.java index 096739ee37..3feaabc3eb 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/GridInfoPingyinService.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/GridInfoPingyinService.java @@ -1,10 +1,9 @@ package com.epmet.opendata.service; import com.epmet.commons.mybatis.service.BaseService; +import com.epmet.opendata.dto.form.ExractGridInfoPingYinFormDTO; import com.epmet.opendata.entity.GridInfoPingyinEntity; -import java.util.Map; - /** * 平阴区网格表 * @@ -12,5 +11,17 @@ import java.util.Map; * @since v1.0.0 2022-07-22 */ public interface GridInfoPingyinService extends BaseService { + /** + * 抽取customer_agency到grid_info_pingyin表 + * + * @param formDTO + */ + void exractAgency(ExractGridInfoPingYinFormDTO formDTO); + /** + * 抽取customer_grid到grid_info_pingyin表 + * + * @param formDTO + */ + void exractGrid(ExractGridInfoPingYinFormDTO formDTO); } \ No newline at end of file diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java index 2e0574706a..d9e505adef 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java @@ -1,11 +1,27 @@ package com.epmet.opendata.service.impl; import com.epmet.commons.mybatis.service.impl.BaseServiceImpl; +import com.epmet.commons.tools.constant.NumConstant; +import com.epmet.commons.tools.exception.RenException; +import com.epmet.commons.tools.utils.ConvertUtils; +import com.epmet.commons.tools.utils.Result; +import com.epmet.constant.IndexCalConstant; +import com.epmet.dto.org.result.CustomerAgencyDTO; +import com.epmet.dto.org.result.CustomerGridDTO; +import com.epmet.feign.DataStatisticalOpenFeignClient; import com.epmet.opendata.dao.GridInfoPingyinDao; +import com.epmet.opendata.dto.form.ExractGridInfoPingYinFormDTO; import com.epmet.opendata.entity.GridInfoPingyinEntity; import com.epmet.opendata.service.GridInfoPingyinService; +import org.apache.commons.collections4.CollectionUtils; +import org.apache.commons.collections4.ListUtils; +import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; +import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.List; + /** * 平阴区网格表 @@ -15,5 +31,153 @@ import org.springframework.stereotype.Service; */ @Service public class GridInfoPingyinServiceImpl extends BaseServiceImpl implements GridInfoPingyinService { + @Autowired + private DataStatisticalOpenFeignClient dataStatisticalOpenFeignClient; + + + /** + * 抽取customer_agency到grid_info_pingyin表 + * + * @param formDTO + */ + @Override + public void exractAgency(ExractGridInfoPingYinFormDTO formDTO) { + // 1.查询组织基础信息,customer_agency.code为空的不抽取 + com.epmet.dto.org.form.GridBaseInfoFormDTO formDTO1 = ConvertUtils.sourceToTarget(formDTO, com.epmet.dto.org.form.GridBaseInfoFormDTO.class); + Result> result = dataStatisticalOpenFeignClient.getAgencyBaseInfo(formDTO1); + if (!result.success()) { + throw new RenException(result.getInternalMsg()); + } + if (null == result.getData() || result.getData().size() < NumConstant.ONE) { + return; + } + // 2.封装数据 + List gridInfoList = new ArrayList<>(); + result.getData().forEach(ag -> { + GridInfoPingyinEntity entity = new GridInfoPingyinEntity(); + entity.setQxBm("370124"); + entity.setQxMc("平阴县"); + entity.setGridCode(ag.getCode()); + entity.setGridName(ag.getOrganizationName()); + if ("district".equals(ag.getLevel())) { + entity.setGridLevel(3); + } else if ("street".equals(ag.getLevel())) { + entity.setGridLevel(4); + } else if ("community".equals(ag.getLevel())) { + entity.setGridLevel(6); + } + entity.setLat(new BigDecimal(ag.getLatitude())); + entity.setLng(new BigDecimal(ag.getLongitude())); + gridInfoList.add(entity); + }); + // 3、初始化传all;新增或者编辑 + if ("all".equals(formDTO.getType())) { + // 全删,全增 + baseDao.deleteAllAgencyData(); + // 一次100 + List> partition = ListUtils.partition(gridInfoList, IndexCalConstant.INSERT_SIZE); + partition.forEach(list -> { + this.insertBatch(list); + }); + + } else if ("add".equals(formDTO.getType())) { + // 单独新增组织 + this.insertBatch(gridInfoList); + + } else if ("edit".equals(formDTO.getType())) { + // 修改组织时,先根据code查询,如果有数据,更新 + for (GridInfoPingyinEntity entity : gridInfoList) { + + List orginList = baseDao.selectByGridCode(entity.getGridCode()); + + if (CollectionUtils.isNotEmpty(orginList)) { + + // 更新网格名称、网格层级、网格中心点的经度,网格中心点纬度 + for (GridInfoPingyinEntity oigin : orginList) { + baseDao.updateSomeCol(oigin.getId(), entity.getGridName(), entity.getGridLevel(), entity.getLng(), entity.getLat()); + } + + } else { + // 插入 + baseDao.insert(entity); + } + } + } + + } + + /** + * 抽取customer_grid到grid_info_pingyin表 + * + * @param formDTO + */ + @Override + public void exractGrid(ExractGridInfoPingYinFormDTO formDTO) { + // 1.查询网格基础信息 + com.epmet.dto.org.form.GridBaseInfoFormDTO formDTO1 = ConvertUtils.sourceToTarget(formDTO, com.epmet.dto.org.form.GridBaseInfoFormDTO.class); + Result> result = dataStatisticalOpenFeignClient.getGridBaseInfo(formDTO1); + if (!result.success()) { + throw new RenException(result.getInternalMsg()); + } + if (null == result.getData() || result.getData().size() < NumConstant.ONE) { + return; + } + + // 2.封装数据 + List gridInfoList = new ArrayList<>(); + result.getData().forEach(ag -> { + GridInfoPingyinEntity entity = new GridInfoPingyinEntity(); + entity.setQxBm("370124"); + entity.setQxMc("平阴县"); + entity.setGridCode(ag.getCode()); + entity.setGridName(ag.getGridName()); + entity.setGridLevel(7); + if (ag.getLatitude().length() > 10) { + entity.setLat(new BigDecimal(ag.getLatitude().substring(0, 10))); + } else { + entity.setLat(new BigDecimal(ag.getLatitude())); + } + if (ag.getLongitude().length() > 10) { + entity.setLng(new BigDecimal(ag.getLongitude().substring(0, 10))); + } else { + entity.setLng(new BigDecimal(ag.getLongitude())); + } + gridInfoList.add(entity); + }); + // 3、初始化传all;新增或者编辑 + if ("all".equals(formDTO.getType())) { + // 全删,全增 + baseDao.deleteAllGridData(); + // 一次100 + List> partition = ListUtils.partition(gridInfoList, IndexCalConstant.INSERT_SIZE); + partition.forEach(list -> { + this.insertBatch(list); + }); + } else if ("add".equals(formDTO.getType())) { + // 单独新增组织 + this.insertBatch(gridInfoList); + + } else if ("edit".equals(formDTO.getType())) { + // 修改组织时,先根据code查询,如果有数据,更新 + for (GridInfoPingyinEntity entity : gridInfoList) { + + List orginList = baseDao.selectByGridCode(entity.getGridCode()); + + if (CollectionUtils.isNotEmpty(orginList)) { + + // 更新网格名称、网格层级、网格中心点的经度,网格中心点纬度 + for (GridInfoPingyinEntity oigin : orginList) { + baseDao.updateSomeCol(oigin.getId(), entity.getGridName(), entity.getGridLevel(), entity.getLng(), entity.getLat()); + } + + } else { + // 插入 + baseDao.insert(entity); + } + } + } + + } + } \ No newline at end of file diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridInfoPingyinDao.xml b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridInfoPingyinDao.xml index 3cb20d2d76..fd75c023f0 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridInfoPingyinDao.xml +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridInfoPingyinDao.xml @@ -22,5 +22,26 @@ + + delete from grid_info_pingyin where grid_level !='7' + + + + delete from grid_info_pingyin where grid_level ='7' + + + + + + update grid_info_pingyin + set grid_name = #{gridName}, + grid_level = #{gridLevel}, + lng = #{lng}, + lat = #{lat} + where id = #{id} + \ No newline at end of file From 1846909e2b8de063627a64308583773459e72d46 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Fri, 22 Jul 2022 15:43:25 +0800 Subject: [PATCH 006/155] DataStatisticalOpenFeignClient --- .../java/com/epmet/feign/DataStatisticalOpenFeignClient.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/feign/DataStatisticalOpenFeignClient.java b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/feign/DataStatisticalOpenFeignClient.java index 1c865240ea..7bdcd41b37 100644 --- a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/feign/DataStatisticalOpenFeignClient.java +++ b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/feign/DataStatisticalOpenFeignClient.java @@ -36,8 +36,8 @@ import java.util.List; * @author: jianjun liu */ //url="http://localhost:8108" -@FeignClient(name = ServiceConstant.DATA_STATISTICAL_SERVER, fallbackFactory = DataStatisticalOpenFeignClientFallBackFactory.class, url = "http://localhost:8108") -// @FeignClient(name = ServiceConstant.DATA_STATISTICAL_SERVER, fallbackFactory = DataStatisticalOpenFeignClientFallBackFactory.class) +// @FeignClient(name = ServiceConstant.DATA_STATISTICAL_SERVER, fallbackFactory = DataStatisticalOpenFeignClientFallBackFactory.class, url = "http://localhost:8108") +@FeignClient(name = ServiceConstant.DATA_STATISTICAL_SERVER, fallbackFactory = DataStatisticalOpenFeignClientFallBackFactory.class) public interface DataStatisticalOpenFeignClient { /** From 4f55bf2bbbc7ef6bf7b0c38b77c35abb76988f20 Mon Sep 17 00:00:00 2001 From: zhaoqifeng Date: Fri, 22 Jul 2022 15:52:16 +0800 Subject: [PATCH 007/155] =?UTF-8?q?=E6=96=B0=E7=89=88=E4=BA=8B=E4=BB=B6?= =?UTF-8?q?=E4=B8=8A=E6=8A=A5=E7=AC=AC=E4=B8=89=E6=96=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dto/basereport/form/EventInfoFormDTO.java | 7 + .../feign/DataStatisticalOpenFeignClient.java | 3 +- ...ataStatisticalOpenFeignClientFallBack.java | 5 + .../controller/DataReportingController.java | 5 +- .../screen/ScreenProjectDataDao.java | 1 + .../epmet/service/DataReportingService.java | 9 ++ .../screen/ScreenProjectDataService.java | 2 +- .../impl/ScreenProjectDataServiceImpl.java | 5 + .../impl/DataReportingServiceImpl.java | 63 +++++++++ .../screen/ScreenProjectDataDao.xml | 74 +++++++++++ .../EventreportPingyinController.java | 34 +++-- .../opendata/dao/EventreportPingyinDao.java | 2 +- .../OpenDataProjectChangeEventListener.java | 5 +- .../service/EventreportPingyinService.java | 9 ++ .../impl/EventreportPingyinServiceImpl.java | 125 ++++++++++++++++++ .../mapper/EventreportPingyinDao.xml | 3 + 16 files changed, 333 insertions(+), 19 deletions(-) diff --git a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/basereport/form/EventInfoFormDTO.java b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/basereport/form/EventInfoFormDTO.java index 8e6c99d562..c54642b6f1 100644 --- a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/basereport/form/EventInfoFormDTO.java +++ b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/basereport/form/EventInfoFormDTO.java @@ -20,4 +20,11 @@ public class EventInfoFormDTO extends PageFormDTO implements Serializable { * 操作类型【新增:add 修改删除:edit】 */ private String type; + /** + * 是否初始化, 通常用于初期初始化数据,由自己控制 + * 0不初始化,有则更新,没有则新增 + * 1完全初始化,删除全部数据 + * 2在完全初始化之后,由于eventreport_pingyin表没有客户ID,初始化其他客户的数据时候可以设2,直接新增 + */ + private String initFlag = "0"; } diff --git a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/feign/DataStatisticalOpenFeignClient.java b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/feign/DataStatisticalOpenFeignClient.java index 7bdcd41b37..ffd9da0f11 100644 --- a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/feign/DataStatisticalOpenFeignClient.java +++ b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/feign/DataStatisticalOpenFeignClient.java @@ -341,7 +341,8 @@ public interface DataStatisticalOpenFeignClient { */ @PostMapping("/data/stats/datareporting/eventinfo") Result> getEventInfo(@RequestBody EventInfoFormDTO formDTO); - + @PostMapping("/data/stats/datareporting/eventinfoV2") + Result> getEventInfoV2(@RequestBody EventInfoFormDTO formDTO); /** * wangxianzhang * diff --git a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/feign/impl/DataStatisticalOpenFeignClientFallBack.java b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/feign/impl/DataStatisticalOpenFeignClientFallBack.java index b5bb0013c4..a46ceb0635 100644 --- a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/feign/impl/DataStatisticalOpenFeignClientFallBack.java +++ b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/feign/impl/DataStatisticalOpenFeignClientFallBack.java @@ -333,6 +333,11 @@ public class DataStatisticalOpenFeignClientFallBack implements DataStatisticalOp return ModuleUtils.feignConError(ServiceConstant.DATA_STATISTICAL_SERVER, "getEventInfo", formDTO); } + @Override + public Result> getEventInfoV2(EventInfoFormDTO formDTO) { + return ModuleUtils.feignConError(ServiceConstant.DATA_STATISTICAL_SERVER, "getEventInfoV2", formDTO); + } + @Override public Result statsVolunteerDemandServicesDaily(String customerId) { return ModuleUtils.feignConError(ServiceConstant.DATA_STATISTICAL_SERVER, "statsVolunteerDemandServicesDaily", customerId); diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/controller/DataReportingController.java b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/controller/DataReportingController.java index 85706430c4..a61a208f34 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/controller/DataReportingController.java +++ b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/controller/DataReportingController.java @@ -102,5 +102,8 @@ public class DataReportingController { public Result> getEventInfo(@RequestBody(required = false) EventInfoFormDTO formDTO) { return new Result>().ok(dataReportingService.getEventInfo(formDTO)); } - + @PostMapping("eventinfoV2") + public Result> getEventInfoV2(@RequestBody(required = false) EventInfoFormDTO formDTO) { + return new Result>().ok(dataReportingService.getEventInfoV2(formDTO)); + } } diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/screen/ScreenProjectDataDao.java b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/screen/ScreenProjectDataDao.java index db2b42ba5b..36a31e24cc 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/screen/ScreenProjectDataDao.java +++ b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/screen/ScreenProjectDataDao.java @@ -72,6 +72,7 @@ public interface ScreenProjectDataDao extends BaseDao { int updateProjectSatisfactionScore(@Param("projectId")String projectId, @Param("score")BigDecimal score); List selectProjectList(@Param("customerId") String customerId, @Param("projectIds") List projectIds); + List selectProjectListV2(@Param("customerId") String customerId, @Param("projectIds") List projectIds); /** * @Description 查询网格下的项目分类 diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/DataReportingService.java b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/DataReportingService.java index 921a2b3dde..db3012c803 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/DataReportingService.java +++ b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/DataReportingService.java @@ -69,4 +69,13 @@ public interface DataReportingService { */ List getEventInfo(EventInfoFormDTO formDTO); + /** + * 事件上报 + * @Param formDTO + * @Return {@link List} + * @Author zhaoqifeng + * @Date 2021/10/15 14:10 + */ + List getEventInfoV2(EventInfoFormDTO formDTO); + } diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/screen/ScreenProjectDataService.java b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/screen/ScreenProjectDataService.java index c0d124698f..e0b4386790 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/screen/ScreenProjectDataService.java +++ b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/screen/ScreenProjectDataService.java @@ -139,7 +139,7 @@ public interface ScreenProjectDataService extends BaseService getProjectList(String customerId, List projectId, Integer pageNo, Integer pageSize); - + List getProjectListV2(String customerId, List projectId, Integer pageNo, Integer pageSize); /** * 项目变更MQ * @Param msg diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/screen/impl/ScreenProjectDataServiceImpl.java b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/screen/impl/ScreenProjectDataServiceImpl.java index db975af203..f611edf8f7 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/screen/impl/ScreenProjectDataServiceImpl.java +++ b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/screen/impl/ScreenProjectDataServiceImpl.java @@ -309,6 +309,11 @@ public class ScreenProjectDataServiceImpl extends BaseServiceImpl getProjectListV2(String customerId, List projectId, Integer pageNo, Integer pageSize) { + PageHelper.startPage(pageNo, pageSize, false); + return baseDao.selectProjectListV2(customerId, projectId); + } /** * @Description 项目变更MQ diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java index 8b33031420..9501d90fd6 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java +++ b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java @@ -201,12 +201,72 @@ public class DataReportingServiceImpl implements DataReportingService { return list.stream().collect(collectingAndThen(toCollection(() -> new TreeSet<>(Comparator.comparing(EventInfoResultDTO::getId))), ArrayList::new)); } + /** + * 事件上报 + * + * @param formDTO + * @Param formDTO + * @Return {@link List} + * @Author zhaoqifeng + * @Date 2021/10/15 14:10 + */ + @Override + public List getEventInfoV2(EventInfoFormDTO formDTO) { + List list; + //根据入参,获取项目 + long start = System.currentTimeMillis(); + List projectList = screenProjectDataService.getProjectList(formDTO.getCustomerId(), formDTO.getProjectId(), formDTO.getPageNo(), formDTO.getPageSize()); + log.info("事件上报-查询项目列表耗时:{}ms",System.currentTimeMillis()-start); + //项目列表为空,返回空数组 + if(CollectionUtils.isEmpty(projectList)) { + return Collections.emptyList(); + } + start = System.currentTimeMillis(); + Map epmetCodeMap = new HashMap<>(); + Result parentCustomer = operCrmOpenFeignClient.getExternalAndParentCustomerId(formDTO.getCustomerId()); + if (StringUtils.isNotBlank(parentCustomer.getData())) { + epmetCodeMap = customerProjectCategoryDictService.getByCategoryCodeMap(parentCustomer.getData()); + } + Map codeMap = customerProjectCategoryDictService.getByCategoryCodeMap(formDTO.getCustomerId()); + //项目ID不为空时,因为只有一条,可以直接处理 + Map finalEpmetCodeMap = epmetCodeMap; + if (CollectionUtils.isNotEmpty(formDTO.getProjectId())) { + list = projectList.stream().map(project -> { + EventInfoResultDTO dto = getEventInfoResultDTO(project, finalEpmetCodeMap, codeMap); + ScreenCustomerGridDTO grid = screenCustomerGridService.getGridById(project.getOrgId()); + dto.setOrgId(project.getOrgId()); + if (null != grid) { + dto.setOrgCode(grid.getCode()); + dto.setOrgName(grid.getGridName()); + } + return dto; + }).collect(Collectors.toList()); + } else { + //项目ID不为空时,提前取出客户下的组织和网格 + Map agencyMap = screenCustomerAgencyService.getAgencyList(formDTO.getCustomerId()); + Map gridMap = screenCustomerGridService.getGridList(formDTO.getCustomerId()); + list = projectList.stream().map(project -> { + EventInfoResultDTO dto = getEventInfoResultDTO(project, finalEpmetCodeMap, codeMap); + ScreenCustomerGridDTO grid = gridMap.get(project.getOrgId()); + dto.setOrgId(project.getOrgId()); + if (null != grid) { + dto.setOrgCode(grid.getCode()); + dto.setOrgName(grid.getGridName()); + } + return dto; + }).collect(Collectors.toList()); + } + log.info("事件上报-组装数据耗时:{}ms",System.currentTimeMillis()-start); + return list.stream().collect(collectingAndThen(toCollection(() -> new TreeSet<>(Comparator.comparing(EventInfoResultDTO::getId))), ArrayList::new)); + } + private EventInfoResultDTO getEventInfoResultDTO(ScreenProjectDataDTO project, Map epmetCodeMap, Map codeMap) { EventInfoResultDTO dto = new EventInfoResultDTO(); dto.setId(project.getProjectId()); dto.setCustomerId(project.getCustomerId()); dto.setEventName(project.getProjectTitle()); dto.setReporterId(project.getProjectCreator()); + //获取工作人员姓名和身份证 String categoryCode = project.getCategoryCode().split(StrConstant.COMMA)[0]; String parentCode = null == codeMap.get(categoryCode)?null:codeMap.get(categoryCode).getParentCategoryCode(); //如果是孔村、榆山、锦水的项目需要关联分类字典表 @@ -333,4 +393,7 @@ public class DataReportingServiceImpl implements DataReportingService { return userService.getPatrolDetailList(formDTO); } + + + } diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/screen/ScreenProjectDataDao.xml b/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/screen/ScreenProjectDataDao.xml index 6cf57e3109..68e2d9d27f 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/screen/ScreenProjectDataDao.xml +++ b/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/screen/ScreenProjectDataDao.xml @@ -269,6 +269,80 @@ ORDER BY a.CREATED_TIME ASC + + SELECT '370124' AS qxBm, + '平阴县' AS qxMc, + w.SECOND_WORK_TYPE AS workType, + w.GRID_ID, + w.GRID_NAME, + concat(w.HAPPEN_TIME,' 00:00:00') as happenTimeString, + w.WORK_RESULT, + w.WORK_CONTENT, + w.update_time, + w.create_time as recoredInsertTime + FROM base_grid_dailywork w + WHERE w.CUSTOMER_ID = #{customerId} + ORDER BY w.CREATE_TIME ASC + LIMIT #{size},1000 + diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridstaffWorkInfoPingyinDao.xml b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridstaffWorkInfoPingyinDao.xml index 44396702fc..ea3bc11030 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridstaffWorkInfoPingyinDao.xml +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridstaffWorkInfoPingyinDao.xml @@ -18,6 +18,9 @@ + + delete from gridstaff_work_info_pingyin LIMIT 1000 + \ No newline at end of file From fa20c3cbee39c1521527833bf719045654ebe8af Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Fri, 22 Jul 2022 16:23:05 +0800 Subject: [PATCH 012/155] =?UTF-8?q?=E4=B8=8D=E5=90=8C=E6=AD=A5=E4=B8=93?= =?UTF-8?q?=E5=B1=9E=E7=BD=91=E6=A0=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/resources/mapper/org/CustomerGridDao.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/CustomerGridDao.xml b/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/CustomerGridDao.xml index 8622167974..5d6dc4042c 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/CustomerGridDao.xml +++ b/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/CustomerGridDao.xml @@ -162,6 +162,7 @@ AND customer_id = #{customerId} and CODE is not null and CODE !='' + and grid_name not like '%专属网格' #{gridId} From ecf1072176a09418969c22f93c2bec9666a59731 Mon Sep 17 00:00:00 2001 From: zxc <1272811460@qq.com> Date: Fri, 22 Jul 2022 16:41:44 +0800 Subject: [PATCH 013/155] =?UTF-8?q?=E4=BE=8B=E8=A1=8C=E5=B7=A5=E4=BD=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../opendata/service/impl/BaseGridDailyworkServiceImpl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java index 6c2e15dbe2..9542670330 100644 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java @@ -189,7 +189,7 @@ public class BaseGridDailyworkServiceImpl extends BaseServiceImpl Date: Fri, 22 Jul 2022 16:45:45 +0800 Subject: [PATCH 014/155] =?UTF-8?q?=E6=96=B0=E7=89=88=E4=BA=8B=E4=BB=B6?= =?UTF-8?q?=E4=B8=8A=E6=8A=A5=E7=AC=AC=E4=B8=89=E6=96=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/epmet/service/impl/DataReportingServiceImpl.java | 1 + .../service/impl/EventreportPingyinServiceImpl.java | 8 ++++++++ 2 files changed, 9 insertions(+) diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java index 344911d767..22a853c0ed 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java +++ b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java @@ -350,6 +350,7 @@ public class DataReportingServiceImpl implements DataReportingService { dto.setCompleteTime(project.getCloseCaseTime()); dto.setLat(project.getLatitude()); dto.setLng(project.getLongitude()); + dto.setWaysOfResolving(ProjectConstant.PROJECT_SELF_CLOSED); return dto; } diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java index ca06381b14..082b46ae5d 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java @@ -93,6 +93,14 @@ public class EventreportPingyinServiceImpl extends BaseServiceImpl(); + staffWrapper.eq(GridstaffInfoPingyinEntity::getGridCode, item.getOrgCode()); + staffList = gridstaffInfoPingyinDao.selectList(staffWrapper); + if (CollectionUtils.isNotEmpty(staffList)) { + entity.setGridUserCardid(staffList.get(NumConstant.ZERO).getCardNum()); + entity.setGridUserName(staffList.get(NumConstant.ZERO).getNickName()); + } } entity.setReportTime(item.getReportTime()); From 56c91544f17ec85373878c300fd17417ba91a971 Mon Sep 17 00:00:00 2001 From: zhaoqifeng Date: Fri, 22 Jul 2022 16:53:24 +0800 Subject: [PATCH 015/155] =?UTF-8?q?=E6=96=B0=E7=89=88=E4=BA=8B=E4=BB=B6?= =?UTF-8?q?=E4=B8=8A=E6=8A=A5=E7=AC=AC=E4=B8=89=E6=96=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/EventreportPingyinServiceImpl.java | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java index 082b46ae5d..5c097e2a54 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java @@ -98,8 +98,13 @@ public class EventreportPingyinServiceImpl extends BaseServiceImpl Date: Fri, 22 Jul 2022 16:55:46 +0800 Subject: [PATCH 016/155] =?UTF-8?q?=E7=BD=91=E6=A0=BC=E5=91=98=E6=95=B0?= =?UTF-8?q?=E6=8D=AE=E4=B8=8A=E6=8A=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/com/epmet/feign/GovOrgOpenFeignClient.java | 2 +- .../epmet/feign/fallback/GovOrgOpenFeignClientFallback.java | 2 +- .../com/epmet/controller/CustomerStaffGridController.java | 6 +++--- .../java/com/epmet/service/CustomerStaffGridService.java | 2 +- .../epmet/service/impl/CustomerStaffGridServiceImpl.java | 3 ++- .../src/main/resources/mapper/CustomerStaffGridDao.xml | 2 +- .../service/impl/GridstaffInfoPingyinServiceImpl.java | 4 ++-- 7 files changed, 11 insertions(+), 10 deletions(-) diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/GovOrgOpenFeignClient.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/GovOrgOpenFeignClient.java index 8ffbd28528..8967a44663 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/GovOrgOpenFeignClient.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/GovOrgOpenFeignClient.java @@ -696,7 +696,7 @@ public interface GovOrgOpenFeignClient { @PostMapping("/gov/org/coverage/dictinit/{customerId}") Result dictInit(@PathVariable(value = "customerId") String customerId); - @PostMapping("/gov/org/customerstaffgrid/gridstaff") + @PostMapping("/gov/org/customerstaffgrid/gridstafflist") Result> gridStaff(CustomerGridStaffListFormDTO dto); } diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/fallback/GovOrgOpenFeignClientFallback.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/fallback/GovOrgOpenFeignClientFallback.java index c64544ef0f..9f16e0dc8e 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/fallback/GovOrgOpenFeignClientFallback.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/fallback/GovOrgOpenFeignClientFallback.java @@ -447,7 +447,7 @@ public class GovOrgOpenFeignClientFallback implements GovOrgOpenFeignClient { @Override public Result> gridStaff(CustomerGridStaffListFormDTO dto) { - return ModuleUtils.feignConError(ServiceConstant.GOV_ORG_SERVER, "gridStaff", dto); + return ModuleUtils.feignConError(ServiceConstant.GOV_ORG_SERVER, "gridStaffList", dto); } } diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerStaffGridController.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerStaffGridController.java index 392594a1da..1d7206e877 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerStaffGridController.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerStaffGridController.java @@ -161,8 +161,8 @@ public class CustomerStaffGridController { * @Author sun * @Description 网格下工作人员列表 **/ - @PostMapping(value = "gridstaff") - public Result> gridStaff(@RequestBody CustomerGridStaffListFormDTO formDTO) { - return new Result>().ok(customerStaffGridService.gridStaff(formDTO)); + @PostMapping("gridstafflist") + public Result> gridStaffList(@RequestBody CustomerGridStaffListFormDTO formDTO) { + return new Result>().ok(customerStaffGridService.gridStaffList(formDTO)); } } \ No newline at end of file diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/CustomerStaffGridService.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/CustomerStaffGridService.java index 899256eaf4..49ac4b16b4 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/CustomerStaffGridService.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/CustomerStaffGridService.java @@ -144,5 +144,5 @@ public interface CustomerStaffGridService extends BaseService getAllStaffByGridId(String gridId); - List gridStaff(CustomerGridStaffListFormDTO formDTO); + List gridStaffList(CustomerGridStaffListFormDTO formDTO); } diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffGridServiceImpl.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffGridServiceImpl.java index c80d01bb9e..28896d3a8a 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffGridServiceImpl.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffGridServiceImpl.java @@ -206,7 +206,8 @@ public class CustomerStaffGridServiceImpl extends BaseServiceImpl gridStaff(CustomerGridStaffListFormDTO formDTO) { + public List gridStaffList(CustomerGridStaffListFormDTO formDTO) { + //查询客户下未被禁用的工作人员基本信息 return baseDao.getGridStaffByCustomerId(formDTO.getCustomerId()); } diff --git a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerStaffGridDao.xml b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerStaffGridDao.xml index 1cca1f20a0..a6569342fd 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerStaffGridDao.xml +++ b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerStaffGridDao.xml @@ -205,7 +205,7 @@ a.user_id gridUserId FROM customer_staff_grid a - INNER JOIN customer_grid b ON a.grid_id = b.id AND b.del_flag = '0' + INNER JOIN customer_grid b ON a.grid_id = b.id AND b.del_flag = '0' AND b.`code` is not null WHERE a.del_flag = '0' AND a.customer_id = #{customerId} diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java index f8d7b78a79..9af3b733fa 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java @@ -44,7 +44,7 @@ public class GridstaffInfoPingyinServiceImpl extends BaseServiceImpl> orgList = govOrgOpenFeignClient.gridStaff(org); @@ -53,7 +53,7 @@ public class GridstaffInfoPingyinServiceImpl extends BaseServiceImpl> userList = epmetUserOpenFeignClient.customerStaff(user); From e21ccd16cd59d72aadaacebb6d5c1f9a7a06a180 Mon Sep 17 00:00:00 2001 From: zhaoqifeng Date: Fri, 22 Jul 2022 17:19:43 +0800 Subject: [PATCH 017/155] =?UTF-8?q?=E6=96=B0=E7=89=88=E4=BA=8B=E4=BB=B6?= =?UTF-8?q?=E4=B8=8A=E6=8A=A5=E7=AC=AC=E4=B8=89=E6=96=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/EventreportPingyinServiceImpl.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java index 5c097e2a54..db470aacf0 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java @@ -107,7 +107,9 @@ public class EventreportPingyinServiceImpl extends BaseServiceImpl StringUtils.isNotBlank(item.getGridUserCardid())).collect(Collectors.toList()); if (NumConstant.ZERO_STR.equals(initFlag)) { entityList.forEach(entity -> { LambdaQueryWrapper wrapper = new LambdaQueryWrapper<>(); From 1f787e4262a64d71cfa6c4fd3d05f43db71dd770 Mon Sep 17 00:00:00 2001 From: sunyuchao Date: Fri, 22 Jul 2022 17:44:24 +0800 Subject: [PATCH 018/155] =?UTF-8?q?=E7=BD=91=E6=A0=BC=E5=91=98=E6=95=B0?= =?UTF-8?q?=E6=8D=AE=E4=B8=8A=E6=8A=A5=20mq?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dto/user/result/GridUserInfoDTO.java | 7 ++++ .../impl/DataReportingServiceImpl.java | 1 + .../epmet/feign/GovOrgOpenFeignClient.java | 4 +- .../opendata/dao/GridstaffInfoPingyinDao.java | 2 + .../OpenDataStaffChangeEventListener.java | 4 +- .../service/GridstaffInfoPingyinService.java | 7 ++++ .../impl/GridstaffInfoPingyinServiceImpl.java | 41 +++++++++++++++++++ .../mapper/GridstaffInfoPingyinDao.xml | 12 ++++++ .../dto/result/GridStaffUploadResultDTO.java | 13 +++++- .../epmet/feign/EpmetUserOpenFeignClient.java | 4 +- .../resources/mapper/CustomerStaffDao.xml | 4 +- 11 files changed, 91 insertions(+), 8 deletions(-) diff --git a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/user/result/GridUserInfoDTO.java b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/user/result/GridUserInfoDTO.java index c70b0332e4..0cec8927b6 100644 --- a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/user/result/GridUserInfoDTO.java +++ b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/user/result/GridUserInfoDTO.java @@ -20,6 +20,7 @@ package com.epmet.dto.user.result; import lombok.Data; import java.io.Serializable; +import java.util.Date; /** @@ -78,6 +79,12 @@ public class GridUserInfoDTO implements Serializable { */ private String sex; + /** + * 网格员信息编辑插入、更新时间,,县市区填写 + */ + private Date updateTime; + + } diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java index 22a853c0ed..6b75d8d8d7 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java +++ b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java @@ -118,6 +118,7 @@ public class DataReportingServiceImpl implements DataReportingService { st.setUserType(dto.getWorkType().equals("fulltime") ? "01" : "02"); st.setPhonenumber(dto.getMobile()); st.setSex(0 == dto.getGender() ? "9" : dto.getGender().toString()); + st.setUpdateTime(dto.getUpdatedTime()); } }); diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/GovOrgOpenFeignClient.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/GovOrgOpenFeignClient.java index 8967a44663..a1cd92ff01 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/GovOrgOpenFeignClient.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/GovOrgOpenFeignClient.java @@ -21,8 +21,8 @@ import java.util.Set; * @author yinzuomei@elink-cn.com * @date 2020/6/4 13:37 */ -// @FeignClient(name = ServiceConstant.GOV_ORG_SERVER, fallbackFactory = GovOrgOpenFeignClientFallbackFactory.class, url = "localhost:8092") -@FeignClient(name = ServiceConstant.GOV_ORG_SERVER, fallbackFactory = GovOrgOpenFeignClientFallbackFactory.class) + @FeignClient(name = ServiceConstant.GOV_ORG_SERVER, fallbackFactory = GovOrgOpenFeignClientFallbackFactory.class, url = "localhost:8092") +//@FeignClient(name = ServiceConstant.GOV_ORG_SERVER, fallbackFactory = GovOrgOpenFeignClientFallbackFactory.class) public interface GovOrgOpenFeignClient { /** diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridstaffInfoPingyinDao.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridstaffInfoPingyinDao.java index d607093a12..ccbf1d6405 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridstaffInfoPingyinDao.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridstaffInfoPingyinDao.java @@ -14,4 +14,6 @@ import org.apache.ibatis.annotations.Mapper; public interface GridstaffInfoPingyinDao extends BaseDao { void del(); + + void edit(GridstaffInfoPingyinEntity entity); } \ No newline at end of file diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/mq/listener/OpenDataStaffChangeEventListener.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/mq/listener/OpenDataStaffChangeEventListener.java index ad7bd79b62..0171205e28 100644 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/mq/listener/OpenDataStaffChangeEventListener.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/mq/listener/OpenDataStaffChangeEventListener.java @@ -12,6 +12,7 @@ import com.epmet.commons.tools.redis.RedisUtils; import com.epmet.commons.tools.utils.SpringContextUtils; import com.epmet.opendata.dto.form.StaffBaseInfoFormDTO; import com.epmet.opendata.service.ExUserService; +import com.epmet.opendata.service.GridstaffInfoPingyinService; import org.apache.commons.lang3.StringUtils; import org.apache.rocketmq.client.consumer.listener.ConsumeConcurrentlyContext; import org.apache.rocketmq.client.consumer.listener.ConsumeConcurrentlyStatus; @@ -86,7 +87,8 @@ public class OpenDataStaffChangeEventListener implements MessageListenerConcurre List staffIdList = new ArrayList<>(); staffIdList.add(obj.getOrgId()); dto.setStaffIdList(staffIdList); - SpringContextUtils.getBean(ExUserService.class).getStaffBaseInfo(dto); + //SpringContextUtils.getBean(ExUserService.class).getStaffBaseInfo(dto); + SpringContextUtils.getBean(GridstaffInfoPingyinService.class).getStaffBaseInfo(dto); } catch (RenException e) { // 如果是我们手动抛出的异常,说明在业务可控范围内。目前不需要MQ重试 logger.error("【开放数据事件监听器】-工作人员信息变更-初始化客户组织失败:".concat(ExceptionUtils.getErrorStackTrace(e))); diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/GridstaffInfoPingyinService.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/GridstaffInfoPingyinService.java index fc0ae09ed3..9164dad0ac 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/GridstaffInfoPingyinService.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/GridstaffInfoPingyinService.java @@ -2,6 +2,7 @@ package com.epmet.opendata.service; import com.epmet.commons.mybatis.service.BaseService; import com.epmet.opendata.dto.form.GridStaffInfoFormDTO; +import com.epmet.opendata.dto.form.StaffBaseInfoFormDTO; import com.epmet.opendata.entity.GridstaffInfoPingyinEntity; import java.util.Map; @@ -15,4 +16,10 @@ import java.util.Map; public interface GridstaffInfoPingyinService extends BaseService { void gridStaffInfo(GridStaffInfoFormDTO formDTO); + + /** + * @Author sun + * @Description 网格员信息中间库同步 + **/ + void getStaffBaseInfo(StaffBaseInfoFormDTO formDTO); } \ No newline at end of file diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java index 9af3b733fa..eb4bf5adc0 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java @@ -8,10 +8,14 @@ import com.epmet.dto.form.CustomerGridStaffListFormDTO; import com.epmet.dto.form.GridStaffUploadtFormDTO; import com.epmet.dto.result.CustomerGridStaffListResultDTO; import com.epmet.dto.result.GridStaffUploadResultDTO; +import com.epmet.dto.user.result.GridUserInfoDTO; +import com.epmet.feign.DataStatisticalOpenFeignClient; import com.epmet.feign.EpmetUserOpenFeignClient; import com.epmet.feign.GovOrgOpenFeignClient; import com.epmet.opendata.dao.GridstaffInfoPingyinDao; import com.epmet.opendata.dto.form.GridStaffInfoFormDTO; +import com.epmet.opendata.dto.form.StaffBaseInfoFormDTO; +import com.epmet.opendata.entity.ExUserEntity; import com.epmet.opendata.entity.GridstaffInfoPingyinEntity; import com.epmet.opendata.service.GridstaffInfoPingyinService; import lombok.extern.slf4j.Slf4j; @@ -39,6 +43,8 @@ public class GridstaffInfoPingyinServiceImpl extends BaseServiceImpl> result = dataStatisticalOpenFeignClient.getStaffBaseInfo(formDTO1); + if (!result.success()) { + throw new RenException(result.getInternalMsg()); + } + + //2.中间库新增/修改数据【基本一个人一条数据,程序按批量处理】 + result.getData().forEach(r -> { + GridstaffInfoPingyinEntity entity = ConvertUtils.sourceToTarget(r, GridstaffInfoPingyinEntity.class); + entity.setQxBm("370124"); + entity.setQxMc("平阴县"); + entity.setGridCode(r.getCode()); + entity.setGridName(r.getGridName()); + entity.setUserType("01"); + entity.setIsLeave("N"); + if (!"staff_create".equals(formDTO.getType())) { + baseDao.edit(entity); + }else { + insert(entity); + } + }); + + + } + + } \ No newline at end of file diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridstaffInfoPingyinDao.xml b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridstaffInfoPingyinDao.xml index 50b086ad03..9929895e9e 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridstaffInfoPingyinDao.xml +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridstaffInfoPingyinDao.xml @@ -3,6 +3,18 @@ + + UPDATE gridstaff_info_pingyin + SET grid_name = #{gridName}, + nick_name = #{nickName}, + card_num = #{cardNum}, + phonenumber = #{phonenumber}, + sex = #{sex} + WHERE + grid_user_id = #{gridUserId} + AND grid_code = #{gridCode} + + delete from gridstaff_info_pingyin diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/result/GridStaffUploadResultDTO.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/result/GridStaffUploadResultDTO.java index bc1c086578..16d0d386f5 100644 --- a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/result/GridStaffUploadResultDTO.java +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/result/GridStaffUploadResultDTO.java @@ -1,9 +1,8 @@ package com.epmet.dto.result; -import com.fasterxml.jackson.annotation.JsonIgnore; import lombok.Data; -import java.util.List; +import java.util.Date; /** * @description: 网格工作人员数据上报-查询客户网格下有效工作人员信息数据 @@ -36,4 +35,14 @@ public class GridStaffUploadResultDTO { */ private String sex; + /** + * 网格员类型,符合《标准》10.3 + */ + private String userType; + + /** + * 网格员信息编辑插入、更新时间,,县市区填写 + */ + private Date updateTime; + } diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java index ff820d789f..9469423a92 100644 --- a/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java @@ -25,8 +25,8 @@ import java.util.Set; * @author yinzuomei@elink-cn.com * @date 2020/6/4 13:09 */ -//@FeignClient(name = ServiceConstant.EPMET_USER_SERVER, fallbackFactory = EpmetUserOpenFeignClientFallbackFactory.class, url = "localhost:8087") -@FeignClient(name = ServiceConstant.EPMET_USER_SERVER, fallbackFactory = EpmetUserOpenFeignClientFallbackFactory.class) +@FeignClient(name = ServiceConstant.EPMET_USER_SERVER, fallbackFactory = EpmetUserOpenFeignClientFallbackFactory.class, url = "localhost:8087") +//@FeignClient(name = ServiceConstant.EPMET_USER_SERVER, fallbackFactory = EpmetUserOpenFeignClientFallbackFactory.class) public interface EpmetUserOpenFeignClient { /** diff --git a/epmet-user/epmet-user-server/src/main/resources/mapper/CustomerStaffDao.xml b/epmet-user/epmet-user-server/src/main/resources/mapper/CustomerStaffDao.xml index 4335ca3468..e5d2289e5b 100644 --- a/epmet-user/epmet-user-server/src/main/resources/mapper/CustomerStaffDao.xml +++ b/epmet-user/epmet-user-server/src/main/resources/mapper/CustomerStaffDao.xml @@ -462,7 +462,9 @@ real_name nickName, id_card cardNum, gender sex, - mobile phonenumber + mobile phonenumber, + IF(work_type = 'fulltime', '01', '02') userType, + updated_time updateTime FROM customer_staff WHERE From adcdda9cbf772352544aef5df0eafd164082909b Mon Sep 17 00:00:00 2001 From: sunyuchao Date: Fri, 22 Jul 2022 17:50:02 +0800 Subject: [PATCH 019/155] =?UTF-8?q?=E9=94=99=E6=8F=90=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/java/com/epmet/feign/GovOrgOpenFeignClient.java | 4 ++-- .../main/java/com/epmet/feign/EpmetUserOpenFeignClient.java | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/GovOrgOpenFeignClient.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/GovOrgOpenFeignClient.java index a1cd92ff01..de9a14c512 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/GovOrgOpenFeignClient.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/GovOrgOpenFeignClient.java @@ -21,8 +21,8 @@ import java.util.Set; * @author yinzuomei@elink-cn.com * @date 2020/6/4 13:37 */ - @FeignClient(name = ServiceConstant.GOV_ORG_SERVER, fallbackFactory = GovOrgOpenFeignClientFallbackFactory.class, url = "localhost:8092") -//@FeignClient(name = ServiceConstant.GOV_ORG_SERVER, fallbackFactory = GovOrgOpenFeignClientFallbackFactory.class) + //@FeignClient(name = ServiceConstant.GOV_ORG_SERVER, fallbackFactory = GovOrgOpenFeignClientFallbackFactory.class, url = "localhost:8092") +@FeignClient(name = ServiceConstant.GOV_ORG_SERVER, fallbackFactory = GovOrgOpenFeignClientFallbackFactory.class) public interface GovOrgOpenFeignClient { /** diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java index 9469423a92..ff820d789f 100644 --- a/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java @@ -25,8 +25,8 @@ import java.util.Set; * @author yinzuomei@elink-cn.com * @date 2020/6/4 13:09 */ -@FeignClient(name = ServiceConstant.EPMET_USER_SERVER, fallbackFactory = EpmetUserOpenFeignClientFallbackFactory.class, url = "localhost:8087") -//@FeignClient(name = ServiceConstant.EPMET_USER_SERVER, fallbackFactory = EpmetUserOpenFeignClientFallbackFactory.class) +//@FeignClient(name = ServiceConstant.EPMET_USER_SERVER, fallbackFactory = EpmetUserOpenFeignClientFallbackFactory.class, url = "localhost:8087") +@FeignClient(name = ServiceConstant.EPMET_USER_SERVER, fallbackFactory = EpmetUserOpenFeignClientFallbackFactory.class) public interface EpmetUserOpenFeignClient { /** From c34398b8febb465ac0a80ce395c783859a74e9d7 Mon Sep 17 00:00:00 2001 From: jianjun Date: Fri, 22 Jul 2022 18:17:24 +0800 Subject: [PATCH 020/155] =?UTF-8?q?=E4=BE=8B=E8=A1=8C=E5=B7=A5=E4=BD=9C?= =?UTF-8?q?=E5=8E=BB=E6=8E=89=20=E7=BD=91=E6=A0=BC=E7=A9=BA=E7=9A=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/BaseGridDailyworkServiceImpl.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java index 9542670330..bcb4df6f14 100644 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java @@ -281,7 +281,12 @@ public class BaseGridDailyworkServiceImpl extends BaseServiceImpl list){ List insertList = new ArrayList<>(); - list.forEach(o-> insertList.add(buildNewEntity(o))); + list.forEach(o-> { + if (StringUtils.isBlank(o.getGridCode())){ + return; + } + insertList.add(buildNewEntity(o)); + }); //insert if (CollectionUtils.isEmpty(insertList)){ log.error("新构建要插入的数据为空,param:{}", JSON.toJSONString(list)); From 09550bd81c877556ea6376b7022fae2700bfcc52 Mon Sep 17 00:00:00 2001 From: zhaoqifeng Date: Fri, 22 Jul 2022 18:20:05 +0800 Subject: [PATCH 021/155] =?UTF-8?q?=E6=96=B0=E7=89=88=E4=BA=8B=E4=BB=B6?= =?UTF-8?q?=E4=B8=8A=E6=8A=A5=E7=AC=AC=E4=B8=89=E6=96=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/EventreportPingyinServiceImpl.java | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java index db470aacf0..d1a61e8de3 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java @@ -138,8 +138,15 @@ public class EventreportPingyinServiceImpl extends BaseServiceImpl StringUtils.isNotBlank(item.getGridUserCardid())).collect(Collectors.toList()); + //过滤掉必填字段为空的数据 + entityList = entityList.stream().filter(item -> + StringUtils.isNotBlank(item.getGridCode()) && StringUtils.isNotBlank(item.getGridName()) && + StringUtils.isNotBlank(item.getEventCategory()) && StringUtils.isNotBlank(item.getGridUserName()) && + StringUtils.isNotBlank(item.getGridUserCardid()) && null != item.getReportTime() && + null != item.getHappenTime() && StringUtils.isNotBlank(item.getHappenPlace()) && + StringUtils.isNotBlank(item.getGridUserCardid()) && StringUtils.isNotBlank(item.getEventDescription()) && + StringUtils.isNotBlank(item.getWaysOfResolving()) && null != item.getLng() && null != item.getLat() + ).collect(Collectors.toList()); if (NumConstant.ZERO_STR.equals(initFlag)) { entityList.forEach(entity -> { LambdaQueryWrapper wrapper = new LambdaQueryWrapper<>(); From 4c95d193732ed4ba9976649472153f256b6695c0 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Fri, 22 Jul 2022 19:22:13 +0800 Subject: [PATCH 022/155] =?UTF-8?q?=E5=AE=9E=E6=97=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../opendata/dto/form/ExractGridInfoPingYinFormDTO.java | 4 +++- .../opendata/service/impl/GridInfoPingyinServiceImpl.java | 8 ++++---- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/epmet-module/open-data-worker/open-data-worker-client/src/main/java/com/epmet/opendata/dto/form/ExractGridInfoPingYinFormDTO.java b/epmet-module/open-data-worker/open-data-worker-client/src/main/java/com/epmet/opendata/dto/form/ExractGridInfoPingYinFormDTO.java index d57c25a387..b4324bb2ee 100644 --- a/epmet-module/open-data-worker/open-data-worker-client/src/main/java/com/epmet/opendata/dto/form/ExractGridInfoPingYinFormDTO.java +++ b/epmet-module/open-data-worker/open-data-worker-client/src/main/java/com/epmet/opendata/dto/form/ExractGridInfoPingYinFormDTO.java @@ -30,9 +30,11 @@ public class ExractGridInfoPingYinFormDTO implements Serializable { private List orgIdList; /** - * 操作类型【新增:add 修改删除:edit 初始化所有数据:all】 + * 废弃:这个不对。操作类型【新增:add 修改删除:edit 初始化所有数据:all】 + * 操作类型【组织新增:agency_create 组织变更:agency_change 网格新增:grid_create 网格变更:grid_change 人员新增:staff_create 人员变更:staff_change】 */ @NotBlank(message = "操作类型【新增:add 修改删除:edit 初始化所有数据:all】不能为空", groups = {GridInfo.class}) + private String type; } diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java index d9e505adef..b7a15afd09 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java @@ -80,11 +80,11 @@ public class GridInfoPingyinServiceImpl extends BaseServiceImpl { this.insertBatch(list); }); - } else if ("add".equals(formDTO.getType())) { + } else if (formDTO.getType().contains("create")) { // 单独新增组织 this.insertBatch(gridInfoList); - } else if ("edit".equals(formDTO.getType())) { + } else if (formDTO.getType().contains("change")) { // 修改组织时,先根据code查询,如果有数据,更新 for (GridInfoPingyinEntity entity : gridInfoList) { From 426ea1a2902158b478b4daea9931248b51276457 Mon Sep 17 00:00:00 2001 From: zhaoqifeng Date: Fri, 22 Jul 2022 19:31:44 +0800 Subject: [PATCH 023/155] =?UTF-8?q?=E6=96=B0=E7=89=88=E4=BA=8B=E4=BB=B6?= =?UTF-8?q?=E4=B8=8A=E6=8A=A5=E7=AC=AC=E4=B8=89=E6=96=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../opendata/service/impl/EventreportPingyinServiceImpl.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java index d1a61e8de3..1924b99d49 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java @@ -76,6 +76,7 @@ public class EventreportPingyinServiceImpl extends BaseServiceImpl entityList = list.stream().map(item -> { EventreportPingyinEntity entity = new EventreportPingyinEntity(); entity.setQxBm("370124"); @@ -138,6 +139,7 @@ public class EventreportPingyinServiceImpl extends BaseServiceImpl StringUtils.isNotBlank(item.getGridCode()) && StringUtils.isNotBlank(item.getGridName()) && From 6e9b8ee5f5aae91a2e6d396216adcbca053d3d10 Mon Sep 17 00:00:00 2001 From: zhaoqifeng Date: Fri, 22 Jul 2022 19:38:23 +0800 Subject: [PATCH 024/155] =?UTF-8?q?log=E7=BA=A7=E5=88=AB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/resources/logback-spring.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/logback-spring.xml b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/logback-spring.xml index 36ddc6f222..151f385f11 100644 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/logback-spring.xml +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/logback-spring.xml @@ -188,12 +188,12 @@ - + - + From b8476c1add9fb36404a6cb646ab3d3cb67f9f033 Mon Sep 17 00:00:00 2001 From: zhaoqifeng Date: Fri, 22 Jul 2022 19:41:36 +0800 Subject: [PATCH 025/155] =?UTF-8?q?log=E7=BA=A7=E5=88=AB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../opendata/service/impl/EventreportPingyinServiceImpl.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java index 1924b99d49..08d3ffccf7 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java @@ -76,7 +76,7 @@ public class EventreportPingyinServiceImpl extends BaseServiceImpl entityList = list.stream().map(item -> { EventreportPingyinEntity entity = new EventreportPingyinEntity(); entity.setQxBm("370124"); @@ -149,6 +149,7 @@ public class EventreportPingyinServiceImpl extends BaseServiceImpl { LambdaQueryWrapper wrapper = new LambdaQueryWrapper<>(); From aed1d0a9c48bf282cee8e84101d8585ed02073da Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Fri, 22 Jul 2022 19:43:48 +0800 Subject: [PATCH 026/155] editgrid --- .../src/main/resources/mapper/CustomerGridDao.xml | 4 +++- .../opendata/mq/listener/OpenDataOrgChangeEventListener.java | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerGridDao.xml b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerGridDao.xml index bd6f04bbc8..c3d15d75e0 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerGridDao.xml +++ b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerGridDao.xml @@ -240,7 +240,9 @@ set grid_name = #{gridName}, manage_district = #{manageDistrict}, - code = #{code}, + + code = #{code}, + grid_type = #{gridType}, contacts = #{contacts}, mobile = #{mobile}, diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/mq/listener/OpenDataOrgChangeEventListener.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/mq/listener/OpenDataOrgChangeEventListener.java index 02fc563a78..deb7384c61 100644 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/mq/listener/OpenDataOrgChangeEventListener.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/mq/listener/OpenDataOrgChangeEventListener.java @@ -95,7 +95,9 @@ public class OpenDataOrgChangeEventListener implements MessageListenerConcurrent extractFormDto.setCustomerId(obj.getCustomerId()); extractFormDto.setType(obj.getType()); List orgIdList = new ArrayList<>(); - orgIdList.add(obj.getOrgId()); + if(StringUtils.isNotBlank(obj.getOrgId())){ + orgIdList.add(obj.getOrgId()); + } extractFormDto.setOrgIdList(orgIdList); if ("agency".equals(obj.getOrgType())) { SpringContextUtils.getBean(GridInfoPingyinService.class).exractAgency(extractFormDto); From 77c215872805a7606b47f34302f342a869138603 Mon Sep 17 00:00:00 2001 From: zhaoqifeng Date: Fri, 22 Jul 2022 20:19:25 +0800 Subject: [PATCH 027/155] =?UTF-8?q?log=E7=BA=A7=E5=88=AB=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/EventreportPingyinServiceImpl.java | 6 ------ .../src/main/resources/logback-spring.xml | 4 ++-- 2 files changed, 2 insertions(+), 8 deletions(-) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java index 08d3ffccf7..85eda36cfb 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java @@ -76,7 +76,6 @@ public class EventreportPingyinServiceImpl extends BaseServiceImpl entityList = list.stream().map(item -> { EventreportPingyinEntity entity = new EventreportPingyinEntity(); entity.setQxBm("370124"); @@ -108,9 +107,6 @@ public class EventreportPingyinServiceImpl extends BaseServiceImpl StringUtils.isNotBlank(item.getGridCode()) && StringUtils.isNotBlank(item.getGridName()) && @@ -149,7 +144,6 @@ public class EventreportPingyinServiceImpl extends BaseServiceImpl { LambdaQueryWrapper wrapper = new LambdaQueryWrapper<>(); diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/logback-spring.xml b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/logback-spring.xml index 151f385f11..36ddc6f222 100644 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/logback-spring.xml +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/logback-spring.xml @@ -188,12 +188,12 @@ - + - + From eb8f40088f0b4ee44da4f7f00674278ce1e21347 Mon Sep 17 00:00:00 2001 From: jianjun Date: Fri, 22 Jul 2022 20:23:18 +0800 Subject: [PATCH 028/155] =?UTF-8?q?=E5=8E=BB=E6=8E=89id?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../opendata/entity/EventreportPingyinEntity.java | 7 ------- .../epmet/opendata/entity/GridInfoPingyinEntity.java | 7 ------- .../opendata/entity/GridstaffInfoPingyinEntity.java | 11 ++--------- .../service/impl/BaseGridDailyworkServiceImpl.java | 2 ++ 4 files changed, 4 insertions(+), 23 deletions(-) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/EventreportPingyinEntity.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/EventreportPingyinEntity.java index 84cddbe1d3..0dc15d325a 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/EventreportPingyinEntity.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/EventreportPingyinEntity.java @@ -1,8 +1,6 @@ package com.epmet.opendata.entity; import com.baomidou.mybatisplus.annotation.TableName; - -import com.epmet.commons.mybatis.entity.BaseEpmetEntity; import lombok.Data; import lombok.EqualsAndHashCode; @@ -22,11 +20,6 @@ public class EventreportPingyinEntity { private static final long serialVersionUID = 1L; - /** - * 数据库主键自增字段,请勿指定 - */ - private Long id; - /** * 上报区县代码,参照6位行政区划代码 */ diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridInfoPingyinEntity.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridInfoPingyinEntity.java index 6051db5f01..9f64f9175d 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridInfoPingyinEntity.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridInfoPingyinEntity.java @@ -1,8 +1,6 @@ package com.epmet.opendata.entity; import com.baomidou.mybatisplus.annotation.TableName; - -import com.epmet.commons.mybatis.entity.BaseEpmetEntity; import lombok.Data; import lombok.EqualsAndHashCode; @@ -22,11 +20,6 @@ public class GridInfoPingyinEntity { private static final long serialVersionUID = 1L; - /** - * 数据库主键自增字段,请勿指定 - */ - private Long id; - /** * 上报区县代码,参照6位行政区划代码 */ diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridstaffInfoPingyinEntity.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridstaffInfoPingyinEntity.java index 0a53873f89..ef5fc9d982 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridstaffInfoPingyinEntity.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridstaffInfoPingyinEntity.java @@ -1,8 +1,6 @@ package com.epmet.opendata.entity; import com.baomidou.mybatisplus.annotation.TableName; - -import com.epmet.commons.mybatis.entity.BaseEpmetEntity; import lombok.Data; import lombok.EqualsAndHashCode; @@ -21,11 +19,6 @@ public class GridstaffInfoPingyinEntity { private static final long serialVersionUID = 1L; - /** - * 数据库主键自增字段,请勿指定 - */ - private Long id; - /** * 上报区县代码,参照6位行政区划代码 */ @@ -97,7 +90,7 @@ public class GridstaffInfoPingyinEntity { private String education; /** - * 入职时间,格式为“YYYY-MM-DD” + * 入职时间,格式为“YYYY-MM-DD” */ private Date entryDate; @@ -107,7 +100,7 @@ public class GridstaffInfoPingyinEntity { private String isLeave; /** - * 离职时间,格式为“YYYY-MM-DD” + * 离职时间,格式为“YYYY-MM-DD” */ private Date leaveDate; diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java index bcb4df6f14..4cc15727fb 100644 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java @@ -209,6 +209,7 @@ public class BaseGridDailyworkServiceImpl extends BaseServiceImpl data; do { Result> record = epmetUserOpenFeignClient.getPatrolRoutineWorkListV2(midPatrolFormDTO); + midPatrolFormDTO.setPageNo(midPatrolFormDTO.getPageNo() + 1); if (record == null || !record.success()) { log.error("获取例行工作记录V2失败,param:{}", JSON.toJSONString(midPatrolFormDTO)); throw new EpmetException(EpmetErrorCode.SERVER_ERROR.getCode()); @@ -231,6 +232,7 @@ public class BaseGridDailyworkServiceImpl extends BaseServiceImpl Date: Fri, 22 Jul 2022 21:03:30 +0800 Subject: [PATCH 029/155] log --- .../opendata/service/impl/EventreportPingyinServiceImpl.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java index 85eda36cfb..8a7a330b06 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java @@ -135,6 +135,7 @@ public class EventreportPingyinServiceImpl extends BaseServiceImpl StringUtils.isNotBlank(item.getGridCode()) && StringUtils.isNotBlank(item.getGridName()) && @@ -144,6 +145,7 @@ public class EventreportPingyinServiceImpl extends BaseServiceImpl { LambdaQueryWrapper wrapper = new LambdaQueryWrapper<>(); From d6c25932dfbbe552c828e33ec95700fcc08e08a0 Mon Sep 17 00:00:00 2001 From: zhaoqifeng Date: Fri, 22 Jul 2022 21:07:45 +0800 Subject: [PATCH 030/155] log --- .../opendata/service/impl/EventreportPingyinServiceImpl.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java index 8a7a330b06..3a695437ba 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java @@ -154,8 +154,7 @@ public class EventreportPingyinServiceImpl extends BaseServiceImpl Date: Fri, 22 Jul 2022 21:14:41 +0800 Subject: [PATCH 031/155] id --- .../service/impl/GridstaffInfoPingyinServiceImpl.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java index eb4bf5adc0..6c58d2565a 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java @@ -15,7 +15,6 @@ import com.epmet.feign.GovOrgOpenFeignClient; import com.epmet.opendata.dao.GridstaffInfoPingyinDao; import com.epmet.opendata.dto.form.GridStaffInfoFormDTO; import com.epmet.opendata.dto.form.StaffBaseInfoFormDTO; -import com.epmet.opendata.entity.ExUserEntity; import com.epmet.opendata.entity.GridstaffInfoPingyinEntity; import com.epmet.opendata.service.GridstaffInfoPingyinService; import lombok.extern.slf4j.Slf4j; @@ -118,6 +117,7 @@ public class GridstaffInfoPingyinServiceImpl extends BaseServiceImpl Date: Fri, 22 Jul 2022 21:21:18 +0800 Subject: [PATCH 032/155] id --- .../java/com/epmet/opendata/dao/GridInfoPingyinDao.java | 4 ++-- .../opendata/service/impl/GridInfoPingyinServiceImpl.java | 6 +++--- .../src/main/resources/mapper/GridInfoPingyinDao.xml | 6 +++--- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridInfoPingyinDao.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridInfoPingyinDao.java index e070cc30ce..0ae3ac01e9 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridInfoPingyinDao.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridInfoPingyinDao.java @@ -23,9 +23,9 @@ public interface GridInfoPingyinDao extends BaseDao { List selectByGridCode(String gridCode); - int updateSomeCol(@Param("id") Long id, + int updateSomeCol(@Param("gridCode") String gridCode, @Param("gridName")String gridName, @Param("gridLevel")Integer gridLevel, @Param("lng")BigDecimal lng, @Param("lat")BigDecimal lat); -} \ No newline at end of file +} diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java index b7a15afd09..454ef351fc 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java @@ -94,7 +94,7 @@ public class GridInfoPingyinServiceImpl extends BaseServiceImpl select g.* from grid_info_pingyin g - where g.grid_code = #{gridCode} + where g.grid_code = #{gridCode} and is_del = 'N' @@ -42,6 +42,6 @@ grid_level = #{gridLevel}, lng = #{lng}, lat = #{lat} - where id = #{id} + where grid_code = #{gridCode} and is_del = 'N' - \ No newline at end of file + From e42b5c11e6ef9a47be72d2bcc627a88126bda9af Mon Sep 17 00:00:00 2001 From: jianjun Date: Fri, 22 Jul 2022 21:31:11 +0800 Subject: [PATCH 033/155] id --- .../opendata/service/impl/BaseGridDailyworkServiceImpl.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java index 4cc15727fb..d23eddb40e 100644 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java @@ -226,7 +226,8 @@ public class BaseGridDailyworkServiceImpl extends BaseServiceImpl { GridInfoCache gridInfo = CustomerOrgRedis.getGridInfo(d.getGridId()); if (null == gridInfo){ - throw new EpmetException("未查询到网格信息:"+ d.getGridId()); + log.warn("未查询到网格信息:"+ d.getGridId()); + return; } d.setGridCode(gridInfo.getCode()); d.setGridName(gridInfo.getGridName()); From 47dee44a4129625ba44efe00c29a0c697b705db9 Mon Sep 17 00:00:00 2001 From: jianjun Date: Fri, 22 Jul 2022 21:53:45 +0800 Subject: [PATCH 034/155] =?UTF-8?q?=E4=B8=8D=E7=9F=A5=E9=81=93?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../commons/tools/constant/NumConstant.java | 2 +- .../epmet/commons/tools/utils/StrUtil.java | 29 +++++++++++++++++++ .../impl/BaseGridDailyworkServiceImpl.java | 3 ++ .../impl/EventreportPingyinServiceImpl.java | 14 +++++---- 4 files changed, 42 insertions(+), 6 deletions(-) create mode 100644 epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/utils/StrUtil.java diff --git a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/constant/NumConstant.java b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/constant/NumConstant.java index 0d18e6f706..95158b2929 100644 --- a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/constant/NumConstant.java +++ b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/constant/NumConstant.java @@ -49,7 +49,7 @@ public interface NumConstant { BigDecimal ONE_HUNDRED_DECIMAL = new BigDecimal(100); BigDecimal ZERO_DECIMAL = new BigDecimal(0); int ONE_THOUSAND = 1000; - int TEN_THOUSAND = 10000; + int THREE_THOUSAND = 3000; int MAX = 99999999; int EIGHTY_EIGHT = 88; int EIGHTY = 80; diff --git a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/utils/StrUtil.java b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/utils/StrUtil.java new file mode 100644 index 0000000000..055b7a2ae2 --- /dev/null +++ b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/utils/StrUtil.java @@ -0,0 +1,29 @@ +package com.epmet.commons.tools.utils; + +import java.util.regex.Matcher; +import java.util.regex.Pattern; + +/** + * desc: + * + * @author: LiuJanJun + * @date: 2022/7/22 9:45 下午 + * @version: 1.0 + */ +public class StrUtil { + + private static final Pattern emoji = Pattern.compile("[\ud83c\udc00-\ud83c\udfff]|[\ud83d\udc00-\ud83d\udfff]|[\u2600-\u27ff]", Pattern.UNICODE_CASE | Pattern.CASE_INSENSITIVE); + + public static String filterEmoji(String source) { + + if (source != null) { + Matcher emojiMatcher = emoji.matcher(source); + if (emojiMatcher.find()) { + source = emojiMatcher.replaceAll(""); + return source; + } + return source; + } + return source; + } +} diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java index d23eddb40e..c02ed2d50f 100644 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java @@ -11,6 +11,7 @@ import com.epmet.commons.tools.redis.common.bean.GridInfoCache; import com.epmet.commons.tools.utils.ConvertUtils; import com.epmet.commons.tools.utils.DateUtils; import com.epmet.commons.tools.utils.Result; +import com.epmet.commons.tools.utils.StrUtil; import com.epmet.commons.tools.validator.ValidatorUtils; import com.epmet.commons.tools.validator.group.AddGroup; import com.epmet.dto.form.patrol.PatrolQueryFormDTO; @@ -229,6 +230,8 @@ public class BaseGridDailyworkServiceImpl extends BaseServiceImpl NumConstant.ONE_THOUSAND) { - eventDescription = eventDescription.substring(NumConstant.ZERO, NumConstant.ONE_THOUSAND); + //如果不为空 长度控制3000以内 + if (StringUtils.isNotBlank(eventDescription) && eventDescription.length() > NumConstant.THREE_THOUSAND) { + eventDescription = eventDescription.substring(NumConstant.ZERO, NumConstant.THREE_THOUSAND); } + eventDescription = StrUtil.filterEmoji(eventDescription); entity.setEventDescription(eventDescription); entity.setWaysOfResolving(item.getWaysOfResolving()); //业务不确定 @@ -163,4 +167,4 @@ public class EventreportPingyinServiceImpl extends BaseServiceImpl Date: Fri, 22 Jul 2022 22:21:47 +0800 Subject: [PATCH 035/155] =?UTF-8?q?=E5=88=A0=E9=99=A4=E7=BD=91=E6=A0=BC?= =?UTF-8?q?=E5=88=A0=E9=99=A4=E7=BB=84=E7=BB=87=E5=8F=91=E9=80=81=E6=B6=88?= =?UTF-8?q?=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../rocketmq/messages/OrgOrStaffMQMsg.java | 1 + .../dto/org/form/GridBaseInfoFormDTO.java | 2 +- .../resources/mapper/org/CustomerGridDao.xml | 6 +- .../mapper/org/StatsCustomerAgencyDao.xml | 6 +- .../epmet/controller/AgencyController.java | 11 +++- .../com/epmet/controller/GridController.java | 13 +++- .../dto/constant/DataWorkerConstant.java | 8 +++ .../form/ExractGridInfoPingYinFormDTO.java | 2 +- .../impl/GridInfoPingyinServiceImpl.java | 59 ++++++++++++++++--- 9 files changed, 91 insertions(+), 17 deletions(-) create mode 100644 epmet-module/open-data-worker/open-data-worker-client/src/main/java/com/epmet/opendata/dto/constant/DataWorkerConstant.java diff --git a/epmet-commons/epmet-commons-rocketmq/src/main/java/com/epmet/commons/rocketmq/messages/OrgOrStaffMQMsg.java b/epmet-commons/epmet-commons-rocketmq/src/main/java/com/epmet/commons/rocketmq/messages/OrgOrStaffMQMsg.java index 14a5a24ff8..bda7f50a7a 100644 --- a/epmet-commons/epmet-commons-rocketmq/src/main/java/com/epmet/commons/rocketmq/messages/OrgOrStaffMQMsg.java +++ b/epmet-commons/epmet-commons-rocketmq/src/main/java/com/epmet/commons/rocketmq/messages/OrgOrStaffMQMsg.java @@ -18,6 +18,7 @@ public class OrgOrStaffMQMsg implements Serializable { //数据类型【组织:agency 网格:grid 人员:staff】 private String orgType; //操作类型【组织新增:agency_create 组织变更:agency_change 网格新增:grid_create 网格变更:grid_change 人员新增:staff_create 人员变更:staff_change】 + //删除网格:grid_delete;删除组织:agency_delete private String type; diff --git a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/org/form/GridBaseInfoFormDTO.java b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/org/form/GridBaseInfoFormDTO.java index 9d39ef6b81..768fad2827 100644 --- a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/org/form/GridBaseInfoFormDTO.java +++ b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/org/form/GridBaseInfoFormDTO.java @@ -28,7 +28,7 @@ public class GridBaseInfoFormDTO implements Serializable { * 操作类型【新增:add 修改删除:edit 初始化所有数据:all】 */ private String type; - + private String delFlag; public interface Grid extends CustomerClientShowGroup {} } diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/CustomerGridDao.xml b/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/CustomerGridDao.xml index 5d6dc4042c..edab6411d7 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/CustomerGridDao.xml +++ b/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/CustomerGridDao.xml @@ -158,8 +158,10 @@ * FROM customer_grid - WHERE del_flag = '0' - AND customer_id = #{customerId} + WHERE customer_id = #{customerId} + + AND del_flag = #{delFlag} + and CODE is not null and CODE !='' and grid_name not like '%专属网格' diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/StatsCustomerAgencyDao.xml b/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/StatsCustomerAgencyDao.xml index 105a4efcc7..fec3627bc0 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/StatsCustomerAgencyDao.xml +++ b/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/StatsCustomerAgencyDao.xml @@ -214,10 +214,12 @@ * FROM customer_agency - WHERE del_flag = '0' - AND customer_id = #{customerId} + WHERE customer_id = #{customerId} and CODE is not null and CODE !='' + + AND del_flag = #{delFlag} + #{agencyId} diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/AgencyController.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/AgencyController.java index ae07816fa2..893bc95cda 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/AgencyController.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/AgencyController.java @@ -201,7 +201,16 @@ public class AgencyController { public Result removeAgency(@LoginUser TokenDto tokenDTO, @RequestBody RemoveAgencyFormDTO formDTO) { ValidatorUtils.validateEntity(formDTO); formDTO.setCustomerId(tokenDTO.getCustomerId()); - return agencyService.removeAgency(formDTO); + Result result= agencyService.removeAgency(formDTO); + //2021-11-30 推送mq,数据同步到中介库 start + OrgOrStaffMQMsg mq = new OrgOrStaffMQMsg(); + mq.setCustomerId(tokenDTO.getCustomerId()); + mq.setOrgId(formDTO.getAgencyId()); + mq.setOrgType("agency"); + mq.setType("agency_delete"); + SendMqMsgUtil.build().openFeignClient(epmetMessageOpenFeignClient).sendOrgStaffMqMsg(mq); + //2021-11-30 end + return result; } /** diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/GridController.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/GridController.java index 8f026e9f44..171197d40e 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/GridController.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/GridController.java @@ -100,7 +100,18 @@ public class GridController { @RequirePermission(requirePermission = RequirePermissionEnum.ORG_GRID_DELETE) public Result deleteGrid(@LoginUser TokenDto tokenDto, @RequestBody DeleteGridFormDTO deleteGridFormDTO){ deleteGridFormDTO.setCustomerId(tokenDto.getCustomerId()); - return customerGridService.deleteGrid(tokenDto,deleteGridFormDTO); + Result result =customerGridService.deleteGrid(tokenDto,deleteGridFormDTO); + //2021-10-18 推送mq,数据同步到中介库 start + if (result.success()) { + OrgOrStaffMQMsg mq = new OrgOrStaffMQMsg(); + mq.setCustomerId(tokenDto.getCustomerId()); + mq.setOrgId(deleteGridFormDTO.getGridId()); + mq.setOrgType("grid"); + mq.setType("grid_delete"); + SendMqMsgUtil.build().openFeignClient(epmetMessageOpenFeignClient).sendOrgStaffMqMsg(mq); + } + //2021-10-18 end + return result; } /** diff --git a/epmet-module/open-data-worker/open-data-worker-client/src/main/java/com/epmet/opendata/dto/constant/DataWorkerConstant.java b/epmet-module/open-data-worker/open-data-worker-client/src/main/java/com/epmet/opendata/dto/constant/DataWorkerConstant.java new file mode 100644 index 0000000000..df1781038f --- /dev/null +++ b/epmet-module/open-data-worker/open-data-worker-client/src/main/java/com/epmet/opendata/dto/constant/DataWorkerConstant.java @@ -0,0 +1,8 @@ +package com.epmet.opendata.dto.constant; + +public interface DataWorkerConstant { + String ALL = "all"; + String CREATE = "create"; + String CHANGE = "change"; + String DELETE = "delete"; +} diff --git a/epmet-module/open-data-worker/open-data-worker-client/src/main/java/com/epmet/opendata/dto/form/ExractGridInfoPingYinFormDTO.java b/epmet-module/open-data-worker/open-data-worker-client/src/main/java/com/epmet/opendata/dto/form/ExractGridInfoPingYinFormDTO.java index b4324bb2ee..970f98e1ab 100644 --- a/epmet-module/open-data-worker/open-data-worker-client/src/main/java/com/epmet/opendata/dto/form/ExractGridInfoPingYinFormDTO.java +++ b/epmet-module/open-data-worker/open-data-worker-client/src/main/java/com/epmet/opendata/dto/form/ExractGridInfoPingYinFormDTO.java @@ -32,9 +32,9 @@ public class ExractGridInfoPingYinFormDTO implements Serializable { /** * 废弃:这个不对。操作类型【新增:add 修改删除:edit 初始化所有数据:all】 * 操作类型【组织新增:agency_create 组织变更:agency_change 网格新增:grid_create 网格变更:grid_change 人员新增:staff_create 人员变更:staff_change】 + * 删除网格grid_delete,删除组织agency_delete */ @NotBlank(message = "操作类型【新增:add 修改删除:edit 初始化所有数据:all】不能为空", groups = {GridInfo.class}) - private String type; } diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java index b7a15afd09..1056aa8361 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java @@ -1,6 +1,7 @@ package com.epmet.opendata.service.impl; import com.epmet.commons.mybatis.service.impl.BaseServiceImpl; +import com.epmet.commons.tools.constant.Constant; import com.epmet.commons.tools.constant.NumConstant; import com.epmet.commons.tools.exception.RenException; import com.epmet.commons.tools.utils.ConvertUtils; @@ -10,11 +11,13 @@ import com.epmet.dto.org.result.CustomerAgencyDTO; import com.epmet.dto.org.result.CustomerGridDTO; import com.epmet.feign.DataStatisticalOpenFeignClient; import com.epmet.opendata.dao.GridInfoPingyinDao; +import com.epmet.opendata.dto.constant.DataWorkerConstant; import com.epmet.opendata.dto.form.ExractGridInfoPingYinFormDTO; import com.epmet.opendata.entity.GridInfoPingyinEntity; import com.epmet.opendata.service.GridInfoPingyinService; import org.apache.commons.collections4.CollectionUtils; import org.apache.commons.collections4.ListUtils; +import org.apache.commons.lang3.StringUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; @@ -44,6 +47,15 @@ public class GridInfoPingyinServiceImpl extends BaseServiceImpl> result = dataStatisticalOpenFeignClient.getAgencyBaseInfo(formDTO1); if (!result.success()) { throw new RenException(result.getInternalMsg()); @@ -59,11 +71,11 @@ public class GridInfoPingyinServiceImpl extends BaseServiceImpl orginList = baseDao.selectByGridCode(entity.getGridCode()); + if (CollectionUtils.isNotEmpty(orginList)) { + for (GridInfoPingyinEntity oigin : orginList) { + baseDao.deleteById(oigin.getId()); + } + } + } } } @@ -115,6 +137,15 @@ public class GridInfoPingyinServiceImpl extends BaseServiceImpl> result = dataStatisticalOpenFeignClient.getGridBaseInfo(formDTO1); if (!result.success()) { throw new RenException(result.getInternalMsg()); @@ -145,7 +176,7 @@ public class GridInfoPingyinServiceImpl extends BaseServiceImpl { this.insertBatch(list); }); - } else if (formDTO.getType().contains("create")) { + } else if (formDTO.getType().contains(DataWorkerConstant.CREATE)) { // 单独新增组织 this.insertBatch(gridInfoList); - } else if (formDTO.getType().contains("change")) { + } else if (formDTO.getType().contains(DataWorkerConstant.CHANGE)) { // 修改组织时,先根据code查询,如果有数据,更新 for (GridInfoPingyinEntity entity : gridInfoList) { @@ -175,6 +206,16 @@ public class GridInfoPingyinServiceImpl extends BaseServiceImpl orginList = baseDao.selectByGridCode(entity.getGridCode()); + if (CollectionUtils.isNotEmpty(orginList)) { + for (GridInfoPingyinEntity oigin : orginList) { + baseDao.deleteById(oigin.getId()); + } + } + } } } From 8cf2da63a313ae9ce75bb4bd6d589612367dc4e2 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Fri, 22 Jul 2022 22:26:52 +0800 Subject: [PATCH 036/155] =?UTF-8?q?=E6=A0=B9=E6=8D=AEcode=E5=88=A0?= =?UTF-8?q?=E9=99=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/com/epmet/opendata/dao/GridInfoPingyinDao.java | 2 ++ .../opendata/service/impl/GridInfoPingyinServiceImpl.java | 4 ++-- .../src/main/resources/mapper/GridInfoPingyinDao.xml | 5 +++++ 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridInfoPingyinDao.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridInfoPingyinDao.java index 0ae3ac01e9..986b8f2ff7 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridInfoPingyinDao.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridInfoPingyinDao.java @@ -28,4 +28,6 @@ public interface GridInfoPingyinDao extends BaseDao { @Param("gridLevel")Integer gridLevel, @Param("lng")BigDecimal lng, @Param("lat")BigDecimal lat); + + int deleteByCode(String gridCode); } diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java index 21886ce34f..2f54aecee6 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java @@ -120,7 +120,7 @@ public class GridInfoPingyinServiceImpl extends BaseServiceImpl orginList = baseDao.selectByGridCode(entity.getGridCode()); if (CollectionUtils.isNotEmpty(orginList)) { for (GridInfoPingyinEntity oigin : orginList) { - baseDao.deleteById(oigin.getId()); + baseDao.deleteByCode(oigin.getGridCode()); } } } @@ -212,7 +212,7 @@ public class GridInfoPingyinServiceImpl extends BaseServiceImpl orginList = baseDao.selectByGridCode(entity.getGridCode()); if (CollectionUtils.isNotEmpty(orginList)) { for (GridInfoPingyinEntity oigin : orginList) { - baseDao.deleteById(oigin.getId()); + baseDao.deleteByCode(oigin.getGridCode()); } } } diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridInfoPingyinDao.xml b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridInfoPingyinDao.xml index a6f7c2ef5a..c79ef11f2a 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridInfoPingyinDao.xml +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridInfoPingyinDao.xml @@ -44,4 +44,9 @@ lat = #{lat} where grid_code = #{gridCode} and is_del = 'N' + + + update grid_info_pingyin set is_del = 'Y' + where grid_code = #{gridCode} + From 90823cfdbb56b7985f0ff39c4a2d5fcd12db7b62 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Fri, 22 Jul 2022 22:44:18 +0800 Subject: [PATCH 037/155] int TEN_THOUSAND = 10000; --- .../main/java/com/epmet/commons/tools/constant/NumConstant.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/constant/NumConstant.java b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/constant/NumConstant.java index 95158b2929..1f0d76e14f 100644 --- a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/constant/NumConstant.java +++ b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/constant/NumConstant.java @@ -49,6 +49,8 @@ public interface NumConstant { BigDecimal ONE_HUNDRED_DECIMAL = new BigDecimal(100); BigDecimal ZERO_DECIMAL = new BigDecimal(0); int ONE_THOUSAND = 1000; + int TEN_THOUSAND = 10000; + int THREE_THOUSAND = 3000; int MAX = 99999999; int EIGHTY_EIGHT = 88; From 6fc8b0b3836498a0ab59e3302cae1083d5e38762 Mon Sep 17 00:00:00 2001 From: jianjun Date: Fri, 22 Jul 2022 22:49:26 +0800 Subject: [PATCH 038/155] zhuanzhuanzhuan --- .../epmet/commons/tools/utils/StrUtil.java | 32 ++++++++++++------- 1 file changed, 20 insertions(+), 12 deletions(-) diff --git a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/utils/StrUtil.java b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/utils/StrUtil.java index 055b7a2ae2..8a6b63230c 100644 --- a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/utils/StrUtil.java +++ b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/utils/StrUtil.java @@ -1,10 +1,9 @@ package com.epmet.commons.tools.utils; -import java.util.regex.Matcher; -import java.util.regex.Pattern; +import org.apache.commons.lang3.StringUtils; /** - * desc: + * desc:utf8mb4转为utf8 * * @author: LiuJanJun * @date: 2022/7/22 9:45 下午 @@ -12,18 +11,27 @@ import java.util.regex.Pattern; */ public class StrUtil { - private static final Pattern emoji = Pattern.compile("[\ud83c\udc00-\ud83c\udfff]|[\ud83d\udc00-\ud83d\udfff]|[\u2600-\u27ff]", Pattern.UNICODE_CASE | Pattern.CASE_INSENSITIVE); + private static final int LAST_BMP = 0xFFFF; public static String filterEmoji(String source) { - - if (source != null) { - Matcher emojiMatcher = emoji.matcher(source); - if (emojiMatcher.find()) { - source = emojiMatcher.replaceAll(""); - return source; - } + if (StringUtils.isBlank(source)) { return source; } - return source; + StringBuilder sb = new StringBuilder(source.length()); + for (int i = 0; i < source.length(); i++) { + int codePoint = source.codePointAt(i); + if (codePoint < LAST_BMP) { + sb.appendCodePoint(codePoint); + } else { + i++; + } + } + return sb.toString(); + } + + + public static void main(String[] args) { + String x = StrUtil.filterEmoji("😀😁😆😅🥹🥹😇😗😀😂666"); + System.out.println(x); } } From a87b60005041a36114125d001483d336f0f56792 Mon Sep 17 00:00:00 2001 From: jianjun Date: Fri, 22 Jul 2022 23:31:45 +0800 Subject: [PATCH 039/155] =?UTF-8?q?=E4=BE=8B=E8=A1=8C=E5=B7=A5=E4=BD=9C?= =?UTF-8?q?=E4=BF=AE=E6=94=B9=E4=BD=8D=E7=BD=AE=20=E8=BF=98=E5=8E=9F?= =?UTF-8?q?=E5=8E=9F=E6=9C=89=E7=9A=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../OpenDataPatrolChangeEventListener.java | 4 +- .../service/BaseGridDailyworkService.java | 17 -- .../GridstaffWorkInfoPingyinService.java | 12 +- .../impl/BaseGridDailyworkServiceImpl.java | 166 +++--------------- .../GridstaffWorkInfoPingyinServiceImpl.java | 134 +++++++++++++- 5 files changed, 165 insertions(+), 168 deletions(-) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/mq/listener/OpenDataPatrolChangeEventListener.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/mq/listener/OpenDataPatrolChangeEventListener.java index e5e7a1f577..5c3bbb4404 100644 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/mq/listener/OpenDataPatrolChangeEventListener.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/mq/listener/OpenDataPatrolChangeEventListener.java @@ -15,7 +15,7 @@ import com.epmet.commons.tools.redis.RedisUtils; import com.epmet.commons.tools.utils.SpringContextUtils; import com.epmet.constant.SystemMessageType; import com.epmet.opendata.dto.form.UpsertPatrolRecordForm; -import com.epmet.opendata.service.BaseGridDailyworkService; +import com.epmet.opendata.service.GridstaffWorkInfoPingyinService; import lombok.extern.slf4j.Slf4j; import org.apache.commons.lang3.StringUtils; import org.apache.rocketmq.client.consumer.listener.ConsumeConcurrentlyContext; @@ -99,7 +99,7 @@ public class OpenDataPatrolChangeEventListener implements MessageListenerConcurr break; case SystemMessageType.PATROL_ROUTINE_WORK_ADD: // aBoolean = SpringContextUtils.getBean(BaseGridDailyworkService.class).insertBaseGridWorkRecord(patrolRecordForm); - aBoolean = SpringContextUtils.getBean(BaseGridDailyworkService.class).insertBaseGridWorkRecordV2(patrolRecordForm); + aBoolean = SpringContextUtils.getBean(GridstaffWorkInfoPingyinService.class).insertBaseGridWorkRecordV2(patrolRecordForm); break; default: log.error("错误的消息类型:{}", tags); diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/BaseGridDailyworkService.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/BaseGridDailyworkService.java index 6fccfe29e7..010b698d63 100644 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/BaseGridDailyworkService.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/BaseGridDailyworkService.java @@ -18,7 +18,6 @@ package com.epmet.opendata.service; import com.epmet.commons.mybatis.service.BaseService; -import com.epmet.opendata.dto.form.HistoryDataSyncFormDTO; import com.epmet.opendata.dto.form.UpsertPatrolRecordForm; import com.epmet.opendata.entity.BaseGridDailyworkEntity; @@ -37,14 +36,6 @@ public interface BaseGridDailyworkService extends BaseService { + /** + * Desc: 2022-07-22 新表 例行工作同步 + * @param formDTO + * @author zxc + * @date 2022/7/22 11:16 + */ + Boolean insertBaseGridWorkRecordV2(UpsertPatrolRecordForm formDTO); - Integer delAllGridStaffWorkInfoPY(); - -} \ No newline at end of file +} diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java index c02ed2d50f..b8232b5ca1 100644 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/BaseGridDailyworkServiceImpl.java @@ -1,3 +1,20 @@ +/** + * Copyright 2018 人人开源 https://www.renren.io + *

+ * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + *

+ * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + *

+ * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + package com.epmet.opendata.service.impl; import com.alibaba.fastjson.JSON; @@ -6,12 +23,7 @@ import com.epmet.commons.tools.constant.NumConstant; import com.epmet.commons.tools.constant.StrConstant; import com.epmet.commons.tools.exception.EpmetErrorCode; import com.epmet.commons.tools.exception.EpmetException; -import com.epmet.commons.tools.redis.common.CustomerOrgRedis; -import com.epmet.commons.tools.redis.common.bean.GridInfoCache; -import com.epmet.commons.tools.utils.ConvertUtils; -import com.epmet.commons.tools.utils.DateUtils; import com.epmet.commons.tools.utils.Result; -import com.epmet.commons.tools.utils.StrUtil; import com.epmet.commons.tools.validator.ValidatorUtils; import com.epmet.commons.tools.validator.group.AddGroup; import com.epmet.dto.form.patrol.PatrolQueryFormDTO; @@ -20,18 +32,15 @@ import com.epmet.feign.EpmetUserOpenFeignClient; import com.epmet.opendata.dao.BaseGridDailyworkDao; import com.epmet.opendata.dto.ExDeptDTO; import com.epmet.opendata.dto.ExUserDTO; -import com.epmet.opendata.dto.form.HistoryDataSyncFormDTO; import com.epmet.opendata.dto.form.UpsertPatrolRecordForm; import com.epmet.opendata.entity.BaseGridDailyworkEntity; -import com.epmet.opendata.entity.GridstaffWorkInfoPingyinEntity; -import com.epmet.opendata.service.*; +import com.epmet.opendata.service.BaseGridDailyworkService; +import com.epmet.opendata.service.ExDeptService; +import com.epmet.opendata.service.ExUserService; import lombok.extern.slf4j.Slf4j; -import org.apache.commons.collections4.ListUtils; -import org.apache.commons.lang3.StringUtils; import org.jetbrains.annotations.NotNull; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; -import org.springframework.transaction.annotation.Transactional; import org.springframework.util.CollectionUtils; import java.util.ArrayList; @@ -55,12 +64,6 @@ public class BaseGridDailyworkServiceImpl extends BaseServiceImpl list, Map deptMap, Map userMap){ List insertList = new ArrayList<>(); list.forEach(o-> insertList.add(buildEntity(o, deptMap, userMap))); @@ -128,6 +130,7 @@ public class BaseGridDailyworkServiceImpl extends BaseServiceImpl deptMap, Map userMap) { BaseGridDailyworkEntity entity = new BaseGridDailyworkEntity(); entity.setCustomerId(record.getCustomerId()); @@ -175,132 +178,9 @@ public class BaseGridDailyworkServiceImpl extends BaseServiceImpl data; - do { - Result> record = epmetUserOpenFeignClient.getPatrolRoutineWorkListV2(midPatrolFormDTO); - midPatrolFormDTO.setPageNo(midPatrolFormDTO.getPageNo() + 1); - if (record == null || !record.success()) { - log.error("获取例行工作记录V2失败,param:{}", JSON.toJSONString(midPatrolFormDTO)); - throw new EpmetException(EpmetErrorCode.SERVER_ERROR.getCode()); - } - data = record.getData(); - if (CollectionUtils.isEmpty(data)) { - //数据已被删除了 - //暂时设置error 用于排错 - log.error("获取例行工作记录返回为空,param:{}", JSON.toJSONString(midPatrolFormDTO)); - int effectRow = baseDao.deleteById(patrolRecordForm.getId()); - log.warn("del effectRow:{}", effectRow); - throw new EpmetException(EpmetErrorCode.SERVER_ERROR.getCode()); - } - data.forEach(d -> { - GridInfoCache gridInfo = CustomerOrgRedis.getGridInfo(d.getGridId()); - if (null == gridInfo){ - log.warn("未查询到网格信息:"+ d.getGridId()); - return; - } - String s = StrUtil.filterEmoji(d.getWorkContent()); - d.setWorkContent(s); - d.setGridCode(gridInfo.getCode()); - d.setGridName(gridInfo.getGridName()); - }); - insertNewRecordBatch(data); - - }while (data.size() == NumConstant.ONE_THOUSAND); - return true; - } - - /** - * Desc: 历史数据处理 - * @param formDTO - * @author zxc - * @date 2022/7/22 13:24 - */ - @Override - public void historyDataSync(HistoryDataSyncFormDTO formDTO) { - Integer pageSize = NumConstant.ONE_THOUSAND; - Integer pageNo = NumConstant.ONE; - List baseGridDailyWork; - do { - baseGridDailyWork = baseDao.getBaseGridDailyWork(formDTO.getCustomerId(),(pageNo - NumConstant.ONE) * pageSize); - List newEntities = ConvertUtils.sourceToTarget(baseGridDailyWork, GridstaffWorkInfoPingyinEntity.class); - newEntities.forEach(n -> { - GridInfoCache gridInfo = CustomerOrgRedis.getGridInfo(n.getGridId()); - if (null == gridInfo){ - throw new EpmetException("未查询到网格信息:"+ n.getGridId()); - } - n.setGridCode(gridInfo.getCode()); - n.setHappenTime(DateUtils.parseDate(n.getHappenTimeString(),DateUtils.DATE_PATTERN)); - n.setIsDel(NumConstant.ZERO_STR); - }); - insertGridStaffWorkInfoPY(newEntities); - pageNo++; - }while (baseGridDailyWork.size() == NumConstant.ONE_THOUSAND); - } - - /** - * Desc: 数据存入 - * @param newEntities - * @author zxc - * @date 2022/7/22 14:17 - */ - @Transactional(rollbackFor = Exception.class) - public void insertGridStaffWorkInfoPY(List newEntities){ - if (!CollectionUtils.isEmpty(newEntities)){ - List> partition = ListUtils.partition(newEntities, NumConstant.ONE_HUNDRED); - partition.forEach(p -> { - pingYinService.insertBatch(p); - }); - } - } - - private Boolean insertNewRecordBatch(List list){ - List insertList = new ArrayList<>(); - list.forEach(o-> { - if (StringUtils.isBlank(o.getGridCode())){ - return; - } - insertList.add(buildNewEntity(o)); - }); - //insert - if (CollectionUtils.isEmpty(insertList)){ - log.error("新构建要插入的数据为空,param:{}", JSON.toJSONString(list)); - return false; - } - insertGridStaffWorkInfoPY(insertList); -// pingYinService.saveOrUpdateBatch(insertList, NumConstant.ONE_HUNDRED); - return true; - } - } diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffWorkInfoPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffWorkInfoPingyinServiceImpl.java index db80164c1d..ffa08d0286 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffWorkInfoPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffWorkInfoPingyinServiceImpl.java @@ -1,10 +1,36 @@ package com.epmet.opendata.service.impl; +import com.alibaba.fastjson.JSON; import com.epmet.commons.mybatis.service.impl.BaseServiceImpl; +import com.epmet.commons.tools.constant.NumConstant; +import com.epmet.commons.tools.exception.EpmetErrorCode; +import com.epmet.commons.tools.exception.EpmetException; +import com.epmet.commons.tools.redis.common.CustomerOrgRedis; +import com.epmet.commons.tools.redis.common.bean.GridInfoCache; +import com.epmet.commons.tools.utils.ConvertUtils; +import com.epmet.commons.tools.utils.DateUtils; +import com.epmet.commons.tools.utils.Result; +import com.epmet.commons.tools.utils.StrUtil; +import com.epmet.commons.tools.validator.ValidatorUtils; +import com.epmet.commons.tools.validator.group.AddGroup; +import com.epmet.dto.form.patrol.PatrolQueryFormDTO; +import com.epmet.dto.result.PatrolRoutineWorkResult; +import com.epmet.feign.EpmetUserOpenFeignClient; import com.epmet.opendata.dao.GridstaffWorkInfoPingyinDao; +import com.epmet.opendata.dto.form.UpsertPatrolRecordForm; import com.epmet.opendata.entity.GridstaffWorkInfoPingyinEntity; import com.epmet.opendata.service.GridstaffWorkInfoPingyinService; +import lombok.extern.slf4j.Slf4j; +import org.apache.commons.collections4.ListUtils; +import org.apache.commons.lang3.StringUtils; +import org.jetbrains.annotations.NotNull; +import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; +import org.springframework.transaction.annotation.Transactional; +import org.springframework.util.CollectionUtils; + +import java.util.ArrayList; +import java.util.List; /** * 平阴区网格员例行工作信息 @@ -12,12 +38,114 @@ import org.springframework.stereotype.Service; * @author generator generator@elink-cn.com * @since v1.0.0 2022-07-22 */ +@Slf4j @Service public class GridstaffWorkInfoPingyinServiceImpl extends BaseServiceImpl implements GridstaffWorkInfoPingyinService { + @Autowired + private EpmetUserOpenFeignClient epmetUserOpenFeignClient; @Override - public Integer delAllGridStaffWorkInfoPY() { - return baseDao.delAllGridStaffWorkInfoPY(); + public Boolean insertBaseGridWorkRecordV2(UpsertPatrolRecordForm patrolRecordForm) { + log.info("insertBaseGridWorkRecordV2 param:{}", JSON.toJSONString(patrolRecordForm)); + ValidatorUtils.validateEntity(patrolRecordForm, AddGroup.class); + // 构建传参 + PatrolQueryFormDTO midPatrolFormDTO = buildParam(patrolRecordForm); + if (StringUtils.isBlank(patrolRecordForm.getId())) { + Integer row; + do { + row = baseDao.delAllGridStaffWorkInfoPY(); + } while (row == NumConstant.ONE_THOUSAND); + } + List data; + do { + Result> record = epmetUserOpenFeignClient.getPatrolRoutineWorkListV2(midPatrolFormDTO); + midPatrolFormDTO.setPageNo(midPatrolFormDTO.getPageNo() + 1); + if (record == null || !record.success()) { + log.error("获取例行工作记录V2失败,param:{}", JSON.toJSONString(midPatrolFormDTO)); + throw new EpmetException(EpmetErrorCode.SERVER_ERROR.getCode()); + } + data = record.getData(); + if (CollectionUtils.isEmpty(data)) { + //数据已被删除了 + //暂时设置error 用于排错 + log.error("获取例行工作记录返回为空,param:{}", JSON.toJSONString(midPatrolFormDTO)); + int effectRow = baseDao.deleteById(patrolRecordForm.getId()); + log.warn("del effectRow:{}", effectRow); + throw new EpmetException(EpmetErrorCode.SERVER_ERROR.getCode()); + } + data.forEach(d -> { + GridInfoCache gridInfo = CustomerOrgRedis.getGridInfo(d.getGridId()); + if (null == gridInfo) { + log.warn("未查询到网格信息:" + d.getGridId()); + return; + } + String s = StrUtil.filterEmoji(d.getWorkContent()); + d.setWorkContent(s); + d.setGridCode(gridInfo.getCode()); + d.setGridName(gridInfo.getGridName()); + }); + insertNewRecordBatch(data); + + } while (data.size() == NumConstant.ONE_THOUSAND); + return true; + } + + /** + * Desc: 数据存入 + * + * @param newEntities + * @author zxc + * @date 2022/7/22 14:17 + */ + @Transactional(rollbackFor = Exception.class) + public void insertGridStaffWorkInfoPY(List newEntities) { + if (!CollectionUtils.isEmpty(newEntities)) { + List> partition = ListUtils.partition(newEntities, NumConstant.ONE_HUNDRED); + partition.forEach(p -> { + this.insertBatch(p); + }); + } + } + + private Boolean insertNewRecordBatch(List list) { + List insertList = new ArrayList<>(); + list.forEach(o -> { + if (StringUtils.isBlank(o.getGridCode())) { + return; + } + insertList.add(buildNewEntity(o)); + }); + //insert + if (CollectionUtils.isEmpty(insertList)) { + log.error("新构建要插入的数据为空,param:{}", JSON.toJSONString(list)); + return false; + } + insertGridStaffWorkInfoPY(insertList); + return true; + } + + private GridstaffWorkInfoPingyinEntity buildNewEntity(PatrolRoutineWorkResult record) { + GridstaffWorkInfoPingyinEntity entity = ConvertUtils.sourceToTarget(record, GridstaffWorkInfoPingyinEntity.class); + entity.setQxBm("370124"); + entity.setQxMc("平阴县"); + entity.setHappenTime(DateUtils.parseDate(record.getHappenTime().concat(" 00:00:00"), DateUtils.DATE_PATTERN)); + entity.setWorkResult(NumConstant.ONE == record.getIsNormal() ? "Y" : "N"); + entity.setWorkType(record.getWorkTypeSecondCode()); + entity.setRecoredInsertTime(record.getCreatedTime()); + entity.setUpdateTime(record.getUpdatedTime()); + entity.setId(null); + entity.setIsDel(NumConstant.ZERO_STR); + return entity; + } + + @NotNull + private PatrolQueryFormDTO buildParam(UpsertPatrolRecordForm patrolRecordForm) { + PatrolQueryFormDTO midPatrolFormDTO = new PatrolQueryFormDTO(); + midPatrolFormDTO.setCustomerId(patrolRecordForm.getCustomerId()); + midPatrolFormDTO.setId(StringUtils.isBlank(patrolRecordForm.getId()) ? "" : patrolRecordForm.getId()); + midPatrolFormDTO.setPageNo(patrolRecordForm.getPageNo()); + midPatrolFormDTO.setPageSize(NumConstant.ONE_THOUSAND); + return midPatrolFormDTO; } -} \ No newline at end of file +} From 50a12a841aaf23bc07475d0cd9fcd19edc4595cf Mon Sep 17 00:00:00 2001 From: jianjun Date: Fri, 22 Jul 2022 23:37:10 +0800 Subject: [PATCH 040/155] =?UTF-8?q?=E5=8F=98=E5=BC=82=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controller/BaseGridDailyworkController.java | 17 ++++------------- 1 file changed, 4 insertions(+), 13 deletions(-) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/BaseGridDailyworkController.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/BaseGridDailyworkController.java index a57bd5c201..7bb809d167 100644 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/BaseGridDailyworkController.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/BaseGridDailyworkController.java @@ -21,9 +21,9 @@ package com.epmet.opendata.controller; import com.epmet.commons.tools.utils.Result; import com.epmet.commons.tools.validator.ValidatorUtils; import com.epmet.commons.tools.validator.group.DefaultGroup; -import com.epmet.opendata.dto.form.HistoryDataSyncFormDTO; import com.epmet.opendata.dto.form.UpsertPatrolRecordForm; import com.epmet.opendata.service.BaseGridDailyworkService; +import com.epmet.opendata.service.GridstaffWorkInfoPingyinService; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestBody; @@ -43,6 +43,8 @@ public class BaseGridDailyworkController { @Autowired private BaseGridDailyworkService baseGridDailyworkService; + @Autowired + private GridstaffWorkInfoPingyinService gridstaffWorkInfoPingyinService; /** * @Author sun @@ -64,20 +66,9 @@ public class BaseGridDailyworkController { @PostMapping("syncV2") public Result getStaffBaseInfoV2(@RequestBody(required = false) UpsertPatrolRecordForm formDTO) { ValidatorUtils.validateEntity(formDTO, DefaultGroup.class); - baseGridDailyworkService.insertBaseGridWorkRecordV2(formDTO); + gridstaffWorkInfoPingyinService.insertBaseGridWorkRecordV2(formDTO); return new Result(); } - /** - * Desc: 历史数据处理 - * @param formDTO - * @author zxc - * @date 2022/7/22 13:24 - */ - @PostMapping("historyDataSync") - public Result historyDataSync(@RequestBody HistoryDataSyncFormDTO formDTO){ - baseGridDailyworkService.historyDataSync(formDTO); - return new Result(); - } } From bb0da98c51ecf970ab7610b1fd0916141271270e Mon Sep 17 00:00:00 2001 From: sunyuchao Date: Mon, 25 Jul 2022 10:42:37 +0800 Subject: [PATCH 041/155] =?UTF-8?q?=E7=A8=8B=E5=BA=8F=E5=AE=8C=E5=96=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/epmet/dto/user/result/CustomerStaffDTO.java | 5 +++++ .../java/com/epmet/dto/user/result/GridUserInfoDTO.java | 5 ++++- .../com/epmet/service/impl/DataReportingServiceImpl.java | 1 + .../service/impl/GridstaffInfoPingyinServiceImpl.java | 9 +++++---- 4 files changed, 15 insertions(+), 5 deletions(-) diff --git a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/user/result/CustomerStaffDTO.java b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/user/result/CustomerStaffDTO.java index a5458793dd..7328788cb6 100644 --- a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/user/result/CustomerStaffDTO.java +++ b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/user/result/CustomerStaffDTO.java @@ -134,4 +134,9 @@ public class CustomerStaffDTO implements Serializable { */ private String roleName; + /** + * 身份证号 + */ + private String idCard; + } diff --git a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/user/result/GridUserInfoDTO.java b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/user/result/GridUserInfoDTO.java index 0cec8927b6..71c7ded5b4 100644 --- a/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/user/result/GridUserInfoDTO.java +++ b/epmet-module/data-statistical/data-statistical-client/src/main/java/com/epmet/dto/user/result/GridUserInfoDTO.java @@ -84,7 +84,10 @@ public class GridUserInfoDTO implements Serializable { */ private Date updateTime; - + /** + * 身份证号 + */ + private String idCard; } diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java index 6b75d8d8d7..f993b0d3c4 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java +++ b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java @@ -119,6 +119,7 @@ public class DataReportingServiceImpl implements DataReportingService { st.setPhonenumber(dto.getMobile()); st.setSex(0 == dto.getGender() ? "9" : dto.getGender().toString()); st.setUpdateTime(dto.getUpdatedTime()); + st.setIdCard(dto.getIdCard()); } }); diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java index 6c58d2565a..a1a5df7991 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java @@ -73,11 +73,13 @@ public class GridstaffInfoPingyinServiceImpl extends BaseServiceImpl> result = dataStatisticalOpenFeignClient.getStaffBaseInfo(formDTO1); if (!result.success()) { @@ -115,9 +117,9 @@ public class GridstaffInfoPingyinServiceImpl extends BaseServiceImpl Date: Mon, 25 Jul 2022 11:16:49 +0800 Subject: [PATCH 042/155] =?UTF-8?q?screen=5Fproject=5Fdata=E8=A1=A8?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E6=8A=BD=E5=8F=96=E6=B7=BB=E5=8A=A0=E9=80=BB?= =?UTF-8?q?=E8=BE=91=E4=BF=AE=E6=94=B9=20eventreport=5Fpingyin=E8=A1=A8?= =?UTF-8?q?=E6=89=B9=E9=87=8F=E6=8F=92=E5=85=A5=E6=94=B9=E6=88=90=E5=8D=95?= =?UTF-8?q?=E6=9D=A1=E6=8F=92=E5=85=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../screen/ScreenProjectDataDao.java | 2 ++ .../impl/ScreenProjectDataServiceImpl.java | 17 ++++++++++++++--- .../screen/ScreenProjectDataDao.xml | 6 ++++++ .../impl/EventreportPingyinServiceImpl.java | 8 +++++++- 4 files changed, 29 insertions(+), 4 deletions(-) diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/screen/ScreenProjectDataDao.java b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/screen/ScreenProjectDataDao.java index 36a31e24cc..1809319a3c 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/screen/ScreenProjectDataDao.java +++ b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/dao/evaluationindex/screen/ScreenProjectDataDao.java @@ -133,4 +133,6 @@ public interface ScreenProjectDataDao extends BaseDao { * @Date 2022/3/16 9:48 */ void updateHistoryData(CustomerStaffGridDTO dto); + + int getProjectCount(@Param("customerId") String customerId,@Param("dateId") String dateId); } diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/screen/impl/ScreenProjectDataServiceImpl.java b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/screen/impl/ScreenProjectDataServiceImpl.java index f611edf8f7..27b5255863 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/screen/impl/ScreenProjectDataServiceImpl.java +++ b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/screen/impl/ScreenProjectDataServiceImpl.java @@ -260,10 +260,21 @@ public class ScreenProjectDataServiceImpl extends BaseServiceImpl NumConstant.ZERO) { - affectedRows = baseDao.deleteByProjectTimeAndCustomerId(customerId, dateId); + int count = baseDao.getProjectCount(customerId, dateId); + if (meta.size() < count) { + //meta的数据量小于表里的数据量,意味着指定部分数据进行重新抽取,只需要删除指定的项目数据即可 + List projectIds = meta.stream().map(ScreenProjectDataDTO::getProjectId).collect(Collectors.toList()); + List> projectPartition = ListUtils.partition(projectIds, NumConstant.FIFTY); + projectPartition.forEach(part -> { + baseDao.deleteByProjectIds(customerId, part); + }); + } else { + int affectedRows = baseDao.deleteByProjectTimeAndCustomerId(customerId,dateId); + while (affectedRows > NumConstant.ZERO) { + affectedRows = baseDao.deleteByProjectTimeAndCustomerId(customerId, dateId); + } } + List> partition = ListUtils.partition(meta, NumConstant.ONE_HUNDRED); partition.forEach(part -> { List list = ConvertUtils.sourceToTarget(part, ScreenProjectDataEntity.class); diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/screen/ScreenProjectDataDao.xml b/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/screen/ScreenProjectDataDao.xml index 68e2d9d27f..64b783c786 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/screen/ScreenProjectDataDao.xml +++ b/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/evaluationindex/screen/ScreenProjectDataDao.xml @@ -539,4 +539,10 @@ AND ORG_ID = #{agencyId} AND ORIGIN = 'agency' + diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java index df1d77eca2..fbf68fc8c5 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java @@ -162,7 +162,13 @@ public class EventreportPingyinServiceImpl extends BaseServiceImpl Date: Mon, 25 Jul 2022 13:53:21 +0800 Subject: [PATCH 043/155] =?UTF-8?q?screen=5Fproject=5Fdata=E8=A1=A8?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E6=8A=BD=E5=8F=96=E6=B7=BB=E5=8A=A0=E9=80=BB?= =?UTF-8?q?=E8=BE=91=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../impl/ScreenProjectDataServiceImpl.java | 19 +++++-------------- 1 file changed, 5 insertions(+), 14 deletions(-) diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/screen/impl/ScreenProjectDataServiceImpl.java b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/screen/impl/ScreenProjectDataServiceImpl.java index 27b5255863..004085496a 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/screen/impl/ScreenProjectDataServiceImpl.java +++ b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/screen/impl/ScreenProjectDataServiceImpl.java @@ -260,20 +260,11 @@ public class ScreenProjectDataServiceImpl extends BaseServiceImpl projectIds = meta.stream().map(ScreenProjectDataDTO::getProjectId).collect(Collectors.toList()); - List> projectPartition = ListUtils.partition(projectIds, NumConstant.FIFTY); - projectPartition.forEach(part -> { - baseDao.deleteByProjectIds(customerId, part); - }); - } else { - int affectedRows = baseDao.deleteByProjectTimeAndCustomerId(customerId,dateId); - while (affectedRows > NumConstant.ZERO) { - affectedRows = baseDao.deleteByProjectTimeAndCustomerId(customerId, dateId); - } - } + List projectIds = meta.stream().map(ScreenProjectDataDTO::getProjectId).collect(Collectors.toList()); + List> projectPartition = ListUtils.partition(projectIds, NumConstant.FIFTY); + projectPartition.forEach(part -> { + baseDao.deleteByProjectIds(customerId, part); + }); List> partition = ListUtils.partition(meta, NumConstant.ONE_HUNDRED); partition.forEach(part -> { From 7129953a647c4ea65c729d75e806c42b6b7cdb08 Mon Sep 17 00:00:00 2001 From: zhaoqifeng Date: Mon, 25 Jul 2022 15:46:46 +0800 Subject: [PATCH 044/155] =?UTF-8?q?eventreport=5Fpingyin=E8=A1=A8=E5=88=A0?= =?UTF-8?q?=E9=99=A4=E5=AD=97=E6=AE=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../opendata/entity/EventreportPingyinEntity.java | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/EventreportPingyinEntity.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/EventreportPingyinEntity.java index 0dc15d325a..1298790b7c 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/EventreportPingyinEntity.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/EventreportPingyinEntity.java @@ -130,16 +130,6 @@ public class EventreportPingyinEntity { */ private String relatedUnites; - /** - * 出租人姓名 - */ - private String lessorName; - - /** - * 出租屋巡查结果,符合《标准》10.24 - */ - private String rentingResult; - /** * 重点场所类别,符合《标准》10.25 */ From 02e5ff85028e1c51f318e641238001658aa3956d Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Mon, 25 Jul 2022 15:47:06 +0800 Subject: [PATCH 045/155] gridLevel String --- .../java/com/epmet/opendata/dao/GridInfoPingyinDao.java | 2 +- .../com/epmet/opendata/entity/GridInfoPingyinEntity.java | 2 +- .../opendata/service/impl/GridInfoPingyinServiceImpl.java | 8 ++++---- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridInfoPingyinDao.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridInfoPingyinDao.java index 986b8f2ff7..0aae21b99f 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridInfoPingyinDao.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridInfoPingyinDao.java @@ -25,7 +25,7 @@ public interface GridInfoPingyinDao extends BaseDao { int updateSomeCol(@Param("gridCode") String gridCode, @Param("gridName")String gridName, - @Param("gridLevel")Integer gridLevel, + @Param("gridLevel")String gridLevel, @Param("lng")BigDecimal lng, @Param("lat")BigDecimal lat); diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridInfoPingyinEntity.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridInfoPingyinEntity.java index 9f64f9175d..d469072534 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridInfoPingyinEntity.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/entity/GridInfoPingyinEntity.java @@ -43,7 +43,7 @@ public class GridInfoPingyinEntity { /** * 网格层级,应符合10.1组织层级,所有层级上报 */ - private Integer gridLevel; + private String gridLevel; /** * 专属网格类型,应符合10.28专属网格类型 diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java index 2f54aecee6..18c2f11420 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java @@ -72,11 +72,11 @@ public class GridInfoPingyinServiceImpl extends BaseServiceImpl 10) { entity.setLat(new BigDecimal(ag.getLatitude().substring(0, 10))); } else { From ffc127b5dd671fb46f55857fd1693b3284a6ab70 Mon Sep 17 00:00:00 2001 From: sunyuchao Date: Mon, 25 Jul 2022 16:42:15 +0800 Subject: [PATCH 046/155] =?UTF-8?q?=E7=A8=8B=E5=BA=8F=E8=B0=83=E6=95=B4?= =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../rocketmq/messages/OrgOrStaffMQMsg.java | 4 ++++ .../service/impl/CustomerGridServiceImpl.java | 13 +++++++++++++ .../resources/mapper/CustomerStaffGridDao.xml | 2 +- .../opendata/dao/GridstaffInfoPingyinDao.java | 3 +++ .../OpenDataStaffChangeEventListener.java | 5 +++-- .../impl/GridstaffInfoPingyinServiceImpl.java | 6 ++++-- .../resources/mapper/GridstaffInfoPingyinDao.xml | 16 ++++++++++++++++ .../controller/CustomerStaffController.java | 9 +++++++-- 8 files changed, 51 insertions(+), 7 deletions(-) diff --git a/epmet-commons/epmet-commons-rocketmq/src/main/java/com/epmet/commons/rocketmq/messages/OrgOrStaffMQMsg.java b/epmet-commons/epmet-commons-rocketmq/src/main/java/com/epmet/commons/rocketmq/messages/OrgOrStaffMQMsg.java index bda7f50a7a..fdd9e5d860 100644 --- a/epmet-commons/epmet-commons-rocketmq/src/main/java/com/epmet/commons/rocketmq/messages/OrgOrStaffMQMsg.java +++ b/epmet-commons/epmet-commons-rocketmq/src/main/java/com/epmet/commons/rocketmq/messages/OrgOrStaffMQMsg.java @@ -3,6 +3,7 @@ package com.epmet.commons.rocketmq.messages; import lombok.Data; import java.io.Serializable; +import java.util.List; /** * 组织、网格、人员中间库数据上报MQ @@ -21,5 +22,8 @@ public class OrgOrStaffMQMsg implements Serializable { //删除网格:grid_delete;删除组织:agency_delete private String type; + //工作人员Id集合 + private List staffIdList; + } diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerGridServiceImpl.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerGridServiceImpl.java index 431200b560..af626daac1 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerGridServiceImpl.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerGridServiceImpl.java @@ -24,6 +24,7 @@ import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; import com.epmet.commons.mybatis.service.impl.BaseServiceImpl; +import com.epmet.commons.rocketmq.messages.OrgOrStaffMQMsg; import com.epmet.commons.tools.constant.FieldConstant; import com.epmet.commons.tools.constant.NumConstant; import com.epmet.commons.tools.constant.StrConstant; @@ -55,6 +56,7 @@ import com.epmet.entity.CustomerStaffGridEntity; import com.epmet.entity.StaffOrgRelationEntity; import com.epmet.feign.*; import com.epmet.resi.partymember.feign.ResiPartyMemberOpenFeignClient; +import com.epmet.send.SendMqMsgUtil; import com.epmet.service.CustomerAgencyService; import com.epmet.service.CustomerGridService; import com.epmet.util.ModuleConstant; @@ -112,6 +114,8 @@ public class CustomerGridServiceImpl extends BaseServiceImpl { CustomerStaffRedis.delStaffInfoFormCache(staffListFormDTO.getCustomerId(), staffId); }); + //22.7.25 网格添加工作人员推送mq 同步工作人员信息到中间库 start + OrgOrStaffMQMsg mq = new OrgOrStaffMQMsg(); + mq.setCustomerId(staffListFormDTO.getCustomerId()); + mq.setStaffIdList(staffListFormDTO.getSelectedList()); + mq.setOrgType("staff"); + mq.setType("staff_create"); + SendMqMsgUtil.build().openFeignClient(epmetMessageOpenFeignClient).sendOrgStaffMqMsg(mq); + //22.7.25 网格添加工作人员推送mq 同步工作人员信息到中间库 end return new Result(); } } + return new Result().error(); } diff --git a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerStaffGridDao.xml b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerStaffGridDao.xml index a6569342fd..5cfece3eb1 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerStaffGridDao.xml +++ b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerStaffGridDao.xml @@ -205,7 +205,7 @@ a.user_id gridUserId FROM customer_staff_grid a - INNER JOIN customer_grid b ON a.grid_id = b.id AND b.del_flag = '0' AND b.`code` is not null + INNER JOIN customer_grid b ON a.grid_id = b.id AND b.del_flag = '0' AND a.customer_id = b.customer_id AND b.`code`!= '' AND b.`code` is not null WHERE a.del_flag = '0' AND a.customer_id = #{customerId} diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridstaffInfoPingyinDao.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridstaffInfoPingyinDao.java index ccbf1d6405..0df03ede97 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridstaffInfoPingyinDao.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/GridstaffInfoPingyinDao.java @@ -3,6 +3,7 @@ package com.epmet.opendata.dao; import com.epmet.commons.mybatis.dao.BaseDao; import com.epmet.opendata.entity.GridstaffInfoPingyinEntity; import org.apache.ibatis.annotations.Mapper; +import org.apache.ibatis.annotations.Param; /** * 平阴区网格员基础信息 @@ -16,4 +17,6 @@ public interface GridstaffInfoPingyinDao extends BaseDao staffIdList = new ArrayList<>(); + /*List staffIdList = new ArrayList<>(); staffIdList.add(obj.getOrgId()); dto.setStaffIdList(staffIdList); - //SpringContextUtils.getBean(ExUserService.class).getStaffBaseInfo(dto); + SpringContextUtils.getBean(ExUserService.class).getStaffBaseInfo(dto);*/ + dto.setStaffIdList(obj.getStaffIdList()); SpringContextUtils.getBean(GridstaffInfoPingyinService.class).getStaffBaseInfo(dto); } catch (RenException e) { // 如果是我们手动抛出的异常,说明在业务可控范围内。目前不需要MQ重试 diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java index a1a5df7991..a4a9909efa 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java @@ -120,9 +120,11 @@ public class GridstaffInfoPingyinServiceImpl extends BaseServiceImpl + + \ No newline at end of file diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java index 586bacf3c2..702469ea31 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java @@ -43,6 +43,7 @@ import org.springframework.beans.factory.annotation.Autowired; import org.springframework.web.bind.annotation.*; import javax.servlet.http.HttpServletResponse; +import java.util.ArrayList; import java.util.List; import java.util.Map; @@ -221,7 +222,9 @@ public class CustomerStaffController { if (result.success()) { OrgOrStaffMQMsg mq = new OrgOrStaffMQMsg(); mq.setCustomerId(fromDTO.getCustomerId()); - mq.setOrgId(result.getData().getUserId()); + List st = new ArrayList<>(); + st.add(result.getData().getUserId()); + mq.setStaffIdList(st); mq.setOrgType("staff"); mq.setType("staff_create"); SendMqMsgUtil.build().openFeignClient(epmetMessageOpenFeignClient).sendOrgStaffMqMsg(mq); @@ -245,7 +248,9 @@ public class CustomerStaffController { if (result.success()) { OrgOrStaffMQMsg mq = new OrgOrStaffMQMsg(); mq.setCustomerId(fromDTO.getCustomerId()); - mq.setOrgId(fromDTO.getStaffId()); + List st = new ArrayList<>(); + st.add(fromDTO.getStaffId()); + mq.setStaffIdList(st); mq.setOrgType("staff"); mq.setType("staff_change"); SendMqMsgUtil.build().openFeignClient(epmetMessageOpenFeignClient).sendOrgStaffMqMsg(mq); From d4599288a80a1774c2020187a119a0cd97fd64d0 Mon Sep 17 00:00:00 2001 From: sunyuchao Date: Mon, 25 Jul 2022 17:35:36 +0800 Subject: [PATCH 047/155] =?UTF-8?q?=E7=A8=8B=E5=BA=8F=E8=B0=83=E6=95=B4?= =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/epmet/service/impl/DataReportingServiceImpl.java | 1 + .../opendata/service/impl/GridstaffInfoPingyinServiceImpl.java | 3 +++ 2 files changed, 4 insertions(+) diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java index f993b0d3c4..bf042e7c91 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java +++ b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java @@ -120,6 +120,7 @@ public class DataReportingServiceImpl implements DataReportingService { st.setSex(0 == dto.getGender() ? "9" : dto.getGender().toString()); st.setUpdateTime(dto.getUpdatedTime()); st.setIdCard(dto.getIdCard()); + st.setStaffId(dto.getUserId()); } }); diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java index a4a9909efa..95a48de722 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java @@ -1,5 +1,6 @@ package com.epmet.opendata.service.impl; +import com.alibaba.fastjson.JSON; import com.epmet.commons.mybatis.service.impl.BaseServiceImpl; import com.epmet.commons.tools.exception.RenException; import com.epmet.commons.tools.utils.ConvertUtils; @@ -103,6 +104,7 @@ public class GridstaffInfoPingyinServiceImpl extends BaseServiceImpl> result = dataStatisticalOpenFeignClient.getStaffBaseInfo(formDTO1); @@ -122,6 +124,7 @@ public class GridstaffInfoPingyinServiceImpl extends BaseServiceImpl Date: Mon, 25 Jul 2022 17:41:47 +0800 Subject: [PATCH 048/155] =?UTF-8?q?=E7=A8=8B=E5=BA=8F=E8=B0=83=E6=95=B4?= =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/resources/mapper/GridstaffInfoPingyinDao.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridstaffInfoPingyinDao.xml b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridstaffInfoPingyinDao.xml index e15c75a5a7..81143e89e0 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridstaffInfoPingyinDao.xml +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridstaffInfoPingyinDao.xml @@ -30,8 +30,8 @@ FROM gridstaff_info_pingyin WHERE - grid_user_id = #{gridUserId} - AND grid_code = #{gridCode} + grid_user_id = #{staffId} + AND grid_code = #{code} LIMIT 1 From 9cadbc8e5ee7904866cf3effc56a8f77592b3758 Mon Sep 17 00:00:00 2001 From: sunyuchao Date: Tue, 26 Jul 2022 09:43:09 +0800 Subject: [PATCH 049/155] =?UTF-8?q?=E7=A8=8B=E5=BA=8F=E8=B0=83=E6=95=B4?= =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/epmet/service/impl/DataReportingServiceImpl.java | 3 +++ .../src/main/resources/mapper/org/CustomerGridDao.xml | 2 +- .../opendata/service/impl/GridstaffInfoPingyinServiceImpl.java | 3 +++ 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java index bf042e7c91..a7cceb6fa2 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java +++ b/epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/impl/DataReportingServiceImpl.java @@ -100,6 +100,9 @@ public class DataReportingServiceImpl implements DataReportingService { public List getStaffBaseInfo(StaffBaseInfoFormDTO formDTO) { //1.查询工作人员所属网格信息 List resultList = customerGridService.getStaffGrid(formDTO); + if (CollectionUtils.isEmpty(resultList)) { + return new ArrayList<>(); + } //2.查询工作人员基础信息 List staffDTOList = userService.getStaffBaseInfo(formDTO); diff --git a/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/CustomerGridDao.xml b/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/CustomerGridDao.xml index edab6411d7..061b1e43bf 100644 --- a/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/CustomerGridDao.xml +++ b/epmet-module/data-statistical/data-statistical-server/src/main/resources/mapper/org/CustomerGridDao.xml @@ -181,7 +181,7 @@ cg.`code` code FROM customer_staff_grid csg - INNER JOIN customer_grid cg ON csg.grid_id = cg.id + INNER JOIN customer_grid cg ON csg.grid_id = cg.id AND cg.`CODE` != '' AND cg.`CODE` is not null WHERE csg.del_flag = '0' AND csg.customer_id = #{customerId} diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java index 95a48de722..060a9ec449 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java @@ -111,6 +111,9 @@ public class GridstaffInfoPingyinServiceImpl extends BaseServiceImpl { From 0eeb3edec714076f128ee98339c6709f5dd1e53d Mon Sep 17 00:00:00 2001 From: zxc <1272811460@qq.com> Date: Tue, 26 Jul 2022 14:59:01 +0800 Subject: [PATCH 050/155] =?UTF-8?q?=E5=85=AC=E5=85=B1=E6=9C=8D=E5=8A=A1?= =?UTF-8?q?=E5=9B=BE=E5=B1=82=EF=BC=8C=E5=9F=8E=E5=B8=82=E7=AE=A1=E7=90=86?= =?UTF-8?q?=E5=9B=BE=E5=B1=82=E6=96=B0=E5=A2=9E=E8=81=94=E7=B3=BB=E4=BA=BA?= =?UTF-8?q?=E5=92=8C=E8=81=94=E7=B3=BB=E7=94=B5=E8=AF=9D=E5=AD=97=E6=AE=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/resources/db/migration/V0.0.36__add_city_public.sql | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 epmet-module/gov-org/gov-org-server/src/main/resources/db/migration/V0.0.36__add_city_public.sql diff --git a/epmet-module/gov-org/gov-org-server/src/main/resources/db/migration/V0.0.36__add_city_public.sql b/epmet-module/gov-org/gov-org-server/src/main/resources/db/migration/V0.0.36__add_city_public.sql new file mode 100644 index 0000000000..8c622ec0f8 --- /dev/null +++ b/epmet-module/gov-org/gov-org-server/src/main/resources/db/migration/V0.0.36__add_city_public.sql @@ -0,0 +1,4 @@ +alter table ic_city_management add COLUMN PRINCIPAL VARCHAR(32) comment '联系人' AFTER ADDRESS; +alter table ic_city_management add COLUMN MOBILE VARCHAR(32) comment '联系方式' AFTER PRINCIPAL; +alter table ic_public_service add COLUMN PRINCIPAL VARCHAR(32) comment '联系人' AFTER ADDRESS; +alter table ic_public_service add COLUMN MOBILE VARCHAR(32) comment '联系方式' AFTER PRINCIPAL; \ No newline at end of file From 8ca9f38655a3b3113e63d7a81fecfef148a90c8f Mon Sep 17 00:00:00 2001 From: zxc <1272811460@qq.com> Date: Tue, 26 Jul 2022 15:00:17 +0800 Subject: [PATCH 051/155] =?UTF-8?q?=E5=85=AC=E5=85=B1=E6=9C=8D=E5=8A=A1?= =?UTF-8?q?=E5=9B=BE=E5=B1=82=EF=BC=8C=E5=9F=8E=E5=B8=82=E7=AE=A1=E7=90=86?= =?UTF-8?q?=E5=9B=BE=E5=B1=82=E6=96=B0=E5=A2=9E=E8=81=94=E7=B3=BB=E4=BA=BA?= =?UTF-8?q?=E5=92=8C=E8=81=94=E7=B3=BB=E7=94=B5=E8=AF=9D=E5=AD=97=E6=AE=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ...{V0.0.36__add_city_public.sql => V0.0.37__add_city_public.sql} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename epmet-module/gov-org/gov-org-server/src/main/resources/db/migration/{V0.0.36__add_city_public.sql => V0.0.37__add_city_public.sql} (100%) diff --git a/epmet-module/gov-org/gov-org-server/src/main/resources/db/migration/V0.0.36__add_city_public.sql b/epmet-module/gov-org/gov-org-server/src/main/resources/db/migration/V0.0.37__add_city_public.sql similarity index 100% rename from epmet-module/gov-org/gov-org-server/src/main/resources/db/migration/V0.0.36__add_city_public.sql rename to epmet-module/gov-org/gov-org-server/src/main/resources/db/migration/V0.0.37__add_city_public.sql From 08a5630c654c343722c58cbceecd5529031b2d59 Mon Sep 17 00:00:00 2001 From: zxc <1272811460@qq.com> Date: Tue, 26 Jul 2022 15:26:38 +0800 Subject: [PATCH 052/155] =?UTF-8?q?=E5=85=AC=E5=85=B1=E6=9C=8D=E5=8A=A1?= =?UTF-8?q?=E5=9B=BE=E5=B1=82=EF=BC=8C=E5=9F=8E=E5=B8=82=E7=AE=A1=E7=90=86?= =?UTF-8?q?=E5=9B=BE=E5=B1=82=E6=96=B0=E5=A2=9E=E8=81=94=E7=B3=BB=E4=BA=BA?= =?UTF-8?q?=E5=92=8C=E8=81=94=E7=B3=BB=E7=94=B5=E8=AF=9D=E5=AD=97=E6=AE=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../entity/govorg/IcCityManagementEntity.java | 10 ++++++++++ .../entity/govorg/IcPublicServiceEntity.java | 10 ++++++++++ .../com/epmet/dto/IcCityManagementDTO.java | 13 ++++++++++++- .../com/epmet/dto/IcPublicServiceDTO.java | 10 ++++++++++ .../form/IcCityManagementAddEditFormDTO.java | 10 ++++++++++ .../form/IcPublicServiceAddEditFormDTO.java | 10 ++++++++++ .../result/IcCityManagementListResultDTO.java | 10 ++++++++++ .../result/IcPublicServiceListResultDTO.java | 10 ++++++++++ .../epmet/entity/IcCityManagementEntity.java | 13 ++++++++++--- .../epmet/entity/IcPublicServiceEntity.java | 13 ++++++++++--- .../epmet/excel/IcCityManagementExcel.java | 8 ++++++++ .../com/epmet/excel/IcPublicServiceExcel.java | 8 ++++++++ .../IcCityManagementExcelImportListener.java | 2 ++ .../IcPublicServiceExcelImportListener.java | 2 ++ .../excel/public_service_template.xlsx | Bin 9096 -> 9133 bytes .../resources/mapper/IcCityManagementDao.xml | 4 +++- .../resources/mapper/IcPublicServiceDao.xml | 4 +++- 17 files changed, 128 insertions(+), 9 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCityManagementEntity.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCityManagementEntity.java index a1baff300a..fff25b16f4 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCityManagementEntity.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCityManagementEntity.java @@ -73,4 +73,14 @@ public class IcCityManagementEntity extends BaseEpmetEntity { */ private String latitude; + /** + * 联系人 + */ + private String principal; + + /** + * 联系电话 + */ + private String mobile; + } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcPublicServiceEntity.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcPublicServiceEntity.java index 6a454c446b..1422ac76ad 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcPublicServiceEntity.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcPublicServiceEntity.java @@ -73,4 +73,14 @@ public class IcPublicServiceEntity extends BaseEpmetEntity { */ private String latitude; + /** + * 联系人 + */ + private String principal; + + /** + * 联系电话 + */ + private String mobile; + } diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/IcCityManagementDTO.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/IcCityManagementDTO.java index 7e36b065b9..a10cbd4ad8 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/IcCityManagementDTO.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/IcCityManagementDTO.java @@ -1,8 +1,9 @@ package com.epmet.dto; +import lombok.Data; + import java.io.Serializable; import java.util.Date; -import lombok.Data; /** @@ -76,6 +77,16 @@ public class IcCityManagementDTO implements Serializable { */ private String latitude; + /** + * 联系人 + */ + private String principal; + + /** + * 联系电话 + */ + private String mobile; + /** * 删除标识 */ diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/IcPublicServiceDTO.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/IcPublicServiceDTO.java index 64045ddd17..d516ccf863 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/IcPublicServiceDTO.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/IcPublicServiceDTO.java @@ -76,6 +76,16 @@ public class IcPublicServiceDTO implements Serializable { */ private String latitude; + /** + * 联系人 + */ + private String principal; + + /** + * 联系电话 + */ + private String mobile; + /** * 删除标识 */ diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/IcCityManagementAddEditFormDTO.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/IcCityManagementAddEditFormDTO.java index ab73efa810..ff0aac0dc2 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/IcCityManagementAddEditFormDTO.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/IcCityManagementAddEditFormDTO.java @@ -62,6 +62,16 @@ public class IcCityManagementAddEditFormDTO implements Serializable { @Length(max = 50, message = "地址不能超过50位", groups = AddGroup.class) private String address; + /** + * 联系人 + */ + private String principal; + + /** + * 联系电话 + */ + private String mobile; + private String customerId; private String userId; diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/IcPublicServiceAddEditFormDTO.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/IcPublicServiceAddEditFormDTO.java index fb9cbf6b26..226bb921f1 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/IcPublicServiceAddEditFormDTO.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/IcPublicServiceAddEditFormDTO.java @@ -62,6 +62,16 @@ public class IcPublicServiceAddEditFormDTO implements Serializable { @Length(max = 50, message = "地址不能超过50位", groups = AddGroup.class) private String address; + /** + * 联系人 + */ + private String principal; + + /** + * 联系电话 + */ + private String mobile; + private String customerId; private String userId; diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/IcCityManagementListResultDTO.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/IcCityManagementListResultDTO.java index 6c40cb030c..ee36eb853d 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/IcCityManagementListResultDTO.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/IcCityManagementListResultDTO.java @@ -65,4 +65,14 @@ public class IcCityManagementListResultDTO implements Serializable { */ private String address; + /** + * 联系人 + */ + private String principal; + + /** + * 联系电话 + */ + private String mobile; + } diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/IcPublicServiceListResultDTO.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/IcPublicServiceListResultDTO.java index 859b36faca..3fcae16a22 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/IcPublicServiceListResultDTO.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/IcPublicServiceListResultDTO.java @@ -65,4 +65,14 @@ public class IcPublicServiceListResultDTO implements Serializable { */ private String address; + /** + * 联系人 + */ + private String principal; + + /** + * 联系电话 + */ + private String mobile; + } diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcCityManagementEntity.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcCityManagementEntity.java index 8a90c40380..170449ea1a 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcCityManagementEntity.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcCityManagementEntity.java @@ -1,13 +1,10 @@ package com.epmet.entity; import com.baomidou.mybatisplus.annotation.TableName; - import com.epmet.commons.mybatis.entity.BaseEpmetEntity; import lombok.Data; import lombok.EqualsAndHashCode; -import java.util.Date; - /** * 城市管理图层 * @@ -76,4 +73,14 @@ public class IcCityManagementEntity extends BaseEpmetEntity { */ private String latitude; + /** + * 联系人 + */ + private String principal; + + /** + * 联系电话 + */ + private String mobile; + } diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcPublicServiceEntity.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcPublicServiceEntity.java index 5c0e35ec89..30b8513f4b 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcPublicServiceEntity.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcPublicServiceEntity.java @@ -1,13 +1,10 @@ package com.epmet.entity; import com.baomidou.mybatisplus.annotation.TableName; - import com.epmet.commons.mybatis.entity.BaseEpmetEntity; import lombok.Data; import lombok.EqualsAndHashCode; -import java.util.Date; - /** * 公共服务图层 * @@ -76,4 +73,14 @@ public class IcPublicServiceEntity extends BaseEpmetEntity { */ private String latitude; + /** + * 联系人 + */ + private String principal; + + /** + * 联系电话 + */ + private String mobile; + } diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/excel/IcCityManagementExcel.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/excel/IcCityManagementExcel.java index ffda552a3f..bdd6f5b587 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/excel/IcCityManagementExcel.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/excel/IcCityManagementExcel.java @@ -38,6 +38,14 @@ public class IcCityManagementExcel { @NotBlank(message = "地址为必填项") private String address; + @ExcelProperty(value = "联系人") + @ColumnWidth(20) + private String principal; + + @ExcelProperty(value = "联系电话") + @ColumnWidth(20) + private String mobile; + @Data public static class RowRemarkMessage { diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/excel/IcPublicServiceExcel.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/excel/IcPublicServiceExcel.java index 3b9762b677..872b2fd61b 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/excel/IcPublicServiceExcel.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/excel/IcPublicServiceExcel.java @@ -38,6 +38,14 @@ public class IcPublicServiceExcel { @NotBlank(message = "地址为必填项") private String address; + @ExcelProperty(value = "联系人") + @ColumnWidth(20) + private String principal; + + @ExcelProperty(value = "联系电话") + @ColumnWidth(20) + private String mobile; + @Data public static class RowRemarkMessage { diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/excel/handler/IcCityManagementExcelImportListener.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/excel/handler/IcCityManagementExcelImportListener.java index 5d08ce792c..df763d3c79 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/excel/handler/IcCityManagementExcelImportListener.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/excel/handler/IcCityManagementExcelImportListener.java @@ -95,6 +95,8 @@ public class IcCityManagementExcelImportListener implements ReadListener%{ohaN{(l0)2wnI^J?Yao`N@tgkBhHHeI5BF|S_ILSLr(yqoiocu%043X#Z`Lmob zn{XDSUV(*-M&o_5MXq>Ani;5DvN$D7hLtXPnX?9*wgrO-mEebI8w7Urx8J%oFE>rU z-BfT&XqXw!_N`#P1MAMfVj7%HUFip2=)--QD*vK+t zpG-#`9S{H6Y}v6Cj1z<9@2Ou{w2V0;vnYD%%Hhhr_glZQvG=Rf6Nga04Vk*#@rs(2 z=*zE~!OfPlp;TXPi|EsgY3~Sk{S&wfe6v7v9#kas>*P~RC-|WrArUpnrBpS4?Xufi?__+7ylFf(G z7aiFvmAx>xaK6fs%ZUi#nbCPOZ&;&ZA@I?N)`%WaxA}6M=Rt^f_on)@Me`s~3M&Rl zq)Jvqgl~isf1lV73FJM7#q_T2rPwYA?Pm>jHV zT3oDcn7a787{*xbCv{Jj#k=I&B)hep9u-H%hl?Eunx1YP^-^s#0V(}LSQBXN!`H;4 zjbe_SHRyy5jew$J;+(3e;aFtJ{AopMYH@n1H;gPCl}~48?P$YSW2aszOlsR%u(M{9 z<}rfetNbKb7F#N~&I-l!rcw8kAefp7?B)m(G|}+plIYYQ#3Ys4%Ju$l$uCZj_=^!- z>+VN~%Pf9bDux%-7E2U@USh4(aBZt2K#4jxtICD2LJG*BZ=Njs489g%hh-_xY zXWv@s{$KL((E@qHs}j@s6#dYH9+|l~%-Dk67CR^ohZNI`4blwcWtbKvd7&rm!7gR3-R`Ox<|~TZ zu{msZH;<^+xz5x^<)4WkD>89#=tifq#?!kgzbZam2wB1h0ZN+>v!{}gNk08Ygmd0= z^=*Y8(fAWw=k8t$o^we`*x(6SPxaisLY_+#-cC5B#v}OLB3l))V=hM}BAgl;1!=@b zNGRdV-jH+c zW2;@zNjuXgj@9;CZ6Tm>EmB{?XT5b=`)sq-o7i|$9y?8RD)~@18{^Z);vD4{KQ+f+ zGCYxuRPQlXXsaI+^L=7CBbfgC{H5EB4CJ&S_2Xm7WO5CmvG+hFy}%KKfuzL9G>#&b zK~cOHXf!Lc8X9kOSo|x~DT^S4P+R>(TeXmZ;JC2wDw@sg}!d!O})X?c^$O|jsq@Fu4{ z_ZBi%nzwN{J`2UfqSd%3WVjN~B@J3BS-iOy%FVI@lH$6b%t7rAe-E zk!&akc_r;FI>}^6w?6GB?ZHSZGjDDNxCYxh)SDfIA00-BD(UVAgm9+6Dw@n?RO&

ig6-J5hylkrAB>3%};838N=tc+QdqY@Eo<3TM3#p^s4?O&CNS z=UC4QK0ncHdBmdk$U3-IL60_c6}71Mh#JZ?M@r)PjWpA^AJrce#ux0-xM>~=D1Zh2 zI(caS=NC@4X!XX&#vn#s>s_)K3dCNtrZ_BO$#oc^cWa)Gde#rijNzikB~p<_ z6W@7$sgD48_<>N91c>MKup3J9UU3d zXJ~|_QnBW@^pdP~MDE6kK%82EsMUoAwoN{v29I0j#BvXB!dN}GS86>#qP0c7fj*?t z1;;6=E?)IbGrl{){_xgXSC`*~3+nNm%JNMgb$7?Paz&p~m$}NyZ~WF>=vCi5)xxgi z;jiXA#OT%(lW5jm=vtBZyWmB)Egw3^ZrJ8Rd1~mZ z`x04z-QBkw^K@Z#$*mTI~ zH4@&9AkeUh#AdyYlW=zgWlH-{`=QJRo>D%qG7#QF3DJ0gERYX0k!)W&NSh;(p7o8$ zx$VH|aLV1=>`&jqFGv*l*q?){NSyf?M|n`%0-x5npWhyuv}A?@39Ug0FXj80SO%Z? zcc$ZYaEa(`e2qnk8|qoCJg+98FsQn}J0`Fc&1m4R%U#Hu@QwJqZLp>j(}Zwmv3glzir9kJhT{?I zCQr>Aw7Ozo;Gy?|pn$}}wMQxjB2Ao#&Pzs<$L?AxXB=P(a!~i~1MNKn>sp;}QR~f0 zA!j~kr|g-TV!Mg1H>?m`D(_BGo`km@v6u5CcAW;D)w~2Su)KtPC57wL-YpMU8rPke z;Mb4(^qmppqasYAiR3=Ak>ovM8w6DE2%Zr=l?arn@IGE|!o&MXWJAs_R!*;+cxhx! zB#DQgkn*xR1xCmh$)zeM#V55;in}SVh0lI6XUfI3D^^|toXPoDQt0@s@2?2<5!npF zq4760k`(~S)!VMf`n!JrT+iRvlroY{j6IlxHb@!w5?|=`5}Tr5#V7r$5*r~| zE_FrQIFfSHaZzuh66B{#cn*MyyIi^7Q4~tgnBSJWnxC%rO)@h~b8?M21fEP~I3~YZ zfAOu`iVGYI3N!!t;)_$yv~t&ZC6i&kMCL&4MC5CrjPKNQAJv&P9?{ zz}UD?D&i3Lf}&nb|Mx(bA)o&>r_P6oOUau7bv}2V_UGr;onwrM<6jdP@aNCxUf_K$ zmM;%4Ut*Fwts4g(hHrU+MJsIh^QF<5JbWU5(ho*qR~Y)<6bd%en2qB@{!RY<2YdIB zMKIv^0jIvTl!LPxyRmXNno3-(zZRX}^C~Ls`-m4&QDP0-`t6A)MS|66m{G_FnFk+| z#<7g= z3^)xsIye5n#bVUMds|yF?gd-7U5Uz+2__RrekX_tH3 zjGkz$YfLyQ%+W5U;U^4;matFfAENX5N-$)MrCUd3-C7eDZ{>RdeO*=6sS0@~EfG0Z z5*WG#=KJC5+_RHM&U}m*rL66t9nliX5QZ;=K^YiHveHEK$L1BZ2;0HLugYczxd3&= zRrx!}6w0&_HKI^_tV!J)mJZp^2}A02$H zpB=v2D~4+f_2+0<x3x&X$$W&lk zAV@jXUwyet=4iM1;$+Vc+tlC!IH#4?FH|wNnN~JB&nc#5jn6F3NLs{|`h?fniwumSR`5* zuMjkW8$ZT4zYD>*ZM*!pTrR65lR5vxGoSsD%zs2Q@DJgH+j!Z(F!u3sa(DcPceM~0$eu6SF(u?hc{$+Kr`&?0LzDEVxEn$N3kiCttL*xzTTzJD0GD0QiV|~Bpsl(Io4i9)85T% zLuVDyy(f)KfIIM+D(_^Mp>j8fT<#wjUPV*x?FQBL-LG*#*EGl}=DMX58Z-XXbJ|;+ zqDs!jdsbc=%~qUNRGbC$>$=xp0d~HCVsl@Sq#vQ;mE}nNb7c0fT95z6%Z>;k&He|g zfj@)lU;NzP!^_3i!^7oohMs6N^am+w9Q2Ut>tZ?PnEQ2>iCXA4VpD=Zxx>=B?-{Nc zsa=k_WP_-Qz!OQu2CFxQ_Zti;jP6>f-xUlkbOUlt{GRuo&rOVo*1n2NQ&WtW4YG;! z^$u=gwUiH%_qW!twxbNz4H*bF+g-akeuG}>BxV3^#n2ZHDHO?J zNne4nRd1WbQ&lUoHg4(DK8)8mva1P-beI%OY;S<_;Q$(>Pri(VsBK`XP+^sg?ieLP z$7(n%3flz}GMH?4G6H*q7`PLL?f8{>#$*H`T_2jYt*}gX8v69~RS6x5Tu;EVN?RqR z6ompuq6N0v?z+RBG|AHAIBcLps1?U5hPDNgbai(T$A$n|PQ{Rr!rvq*tPQ3R6(WLD zcFaCI1Ez{oh{zi9$EWe+X2cwDvVtQqjOyr(hsZZpeQu6cC8{@0vgHuRG%~kD2B$C0O^nzN|2T= z0qK%@-gn=-_uY3s><|0w_1|mlz1LZ1|0)#26su8Kco7@KkIhgiSaitf1Uc1i0gC>E zz@^;vpX~c?F=HM%wJ4m<@Ks*6cSbeps^t3~pvwn0fS*zk96$!#_9%IoP}`O%VrfG3 z`tAL}r~CJ8d!x0JXuLuc9Qy5o&_(tb&gMd%dotd!&#VYy$5VBEK$aE+z4h|sSjXEy z2kInI<)~rL)v%Rv@grG;go|>h?O%jM*^WvSQ1+t-Q)={uJMq@05!hl(1(AXRY69I( zcy5u&VR}lPMwZU`6SPcXp%l;KpcYFfN3qi%22Znz8){dE$p!iM)INVnM|6T}+(+Fe zXoqS~2Q}!sH!qGh4%f>WrqnGPz$Ba`c*SrmL3BjB3B#vRAo4ueE8oyTz-sQ%er^AQ zux{^GUn8ESgBK=L*_s#3cNIo9((>~7D>JX^Q_U;jZZR>6I1~hIgzyRX+aR)?F{Yeg zxbEn?GkvafNF&h^@XfOR%UaC~A5f1lQ>E*>`>0D0Oce*00ssII0zPW2%HC$Dq;X&Y z03_G|z+(UaC4@tTv=0)X2t6RU1}0pm04+W%@Y)$tx6GJjUgXtK3dOT|fGzI*xQso`*NtKc&%^wIjt_U)T4M{$9jO{X5Br1f1aZCsCr$hhq)mAOE4}9yHBn)Sgb4M zN&Q0K)h4~ycX71~e7LYyepK9}VFs0q#)C%wbC6JF&p zPZ2r&kH|S(cK!70VgmizOpwv=?U)|qJ}zIZAdYm&Z<51uVCJ33wr|-GYaK9-78Q;w zM*`ES6|uwt0FDR%0BQirkChhLplcL4sY2>cHG(9>bQTMz4qI)l4u?rPYr#mXMx~W8 z1+y9w9-izi?;d`{;l5<@>f~5)!j&6i%t5~OT;#a#D*dhI;*l|BOiEzgtYd6?cA=|l z7pm{^_&1L%H~R$H(IUPx6R|?i#8ucrdy`+OB3+>^trnj)b-Xleeee<)`>-4Gjh+(6 zhJdxe?&X_`x`3@xfzV)XeapDj0kv_NcYwDzzre zH4nB;n~tXj+XrYU>p?b<8d=6&9W)W?&qq$Pl8nf(Z;=^!oC_>EjwyVvGnC?%&SW)R z3Khs<>H}UjU?(G=HS->U$fDDj;Mp+v8Nsw~pvUgf2f190J$m(G&j9%n<}N+v7~6nS zQpvs}{4`qjMt1=++mcyq_KvGCL~fIhTZcUb^P=v=K zd!BrH&IWJtn`m3UXJ4K?Et+zEznC3ls7hK%S+e!#?ZTulJw(N{EfF9?D4{V1!u8Kz+;tO;51~mEFK!#K{#sRzac;kx>{oyFW$>23P)z5~ zwD-H)9pGV$#^q{0e0xZ-%7pRe_UaNN1M06@Lf)R9URGUzzR1U9RMKy`?h%@_+8z+5mv5zUJi&UxI^r` z0p(px53(BGNzkK)==XN^d|rs6QB`_qSgHWQeq}}ewlBc~*ry++@=@r4 zYxc?#fo>o0YNl%U?^4+@zN`FBza#w)+$-1IB%P(ACza{4-)FgwAYDiN+#4(DW2H74 zA446NJzx3h=uq|_5a3M9Y?myx*uJaReH!upE@um`?Yov{hSJx@+o>vq!cq9vf|y%| zK>+(rNj^j0(fE`h?=MD)e3N<_I`J32f{(hi_(Nk?b9@=fTtu~DKDf98*b-_t`ilD=pIttF~ z{`|6N4~H7XU#|rw@sxK<>t;jn_NQ&!nwmlbMgtKxq*iWL?~!01BlP0Q2c$#oKeKxWp55eD<06H{Ymp8h4a<|g>0)T2%2Cv za@I9tLOpVm_w&8jTT564aZQ%NA)z}%$B?nUnz%m`Z9nIX zbG)s_czT)ry>Z`bSR8 zf$`zH-a8*Cn#o+O-tU%B^=oX;A2vXimZZc3<0F7LNK1-k+611~Yo@)-ZG7t<7i_I% zG*0kp&QNTu*#dQo&2Ve3L&E0y4soT7Qw%+|nCQ_=NgtN!6H7e~{Z}o^c*RCjt%gU>B*Q9H>WqiASLu2E>I5x7z2%)QAzsmT6aKetRJ@!@CP zcSh&~Dz7A9jtttj(e6`NWsE<} zl`>6r=+&-i99((tntmW;w(c8dOtsUT7Z(ki=M#L~V=(s51u>g0?_~_tzaR`F{VUTd zd+#%D?FTo{`WUM&%AMjAY=3aSMRZVBG*r`6Az8|Qro*Y~p9q?IKMCY$6iE6B?7~7k z<8t%t4}8souK&6r-c7w3pZne^?5?kqEKL{RnJ#J>)3HyF>pvRQ)bNt!Dw56Ip2#Ct z!p=9$GyWTdgns#edOL*BK)y+vURA|Rih3jg8z9yBwE*|o@fpJMv&GQdH)Wo;tQ^$^ z(a4ORS`kQ`urEs}MU=kbV$}%Nh)iGsx&n*u{QKwN`HxHJz-Skd!#q zK#avUpfmviesi7Dq}RUEot=DNDe-H*#~z6j)(hU2!Nh?%K}3@{0^`flvT^>NQph<^ z2q-(s3^3Rm)_BPUHF#r1-MKP@bcq5Vra$20F4A}kQPaqQzY*yoOi-XDY+;(%s3rUG z6fudVA0nG}$un#fDbAfP)Z#9X1G!rtV*7YZ8R+=Qc-FjTIe~)nCmJ45RqHDLZJYOL zMaS!H4Jr!mnt4+>f?noz!iU$flt^{30kQIemohf6|BjE|(x9^yVFJbBO*8!zLMl2a)&9Y*9w z|HWO-Yp9&#oA(1eyfDC57E0(f4gMsT^#snQxd(GaOdW|Wr zSugVk?R*k&Ubj<7Ygp-PBE>an?M-=0kJ1k;!CCVmqHUAxtu9hGwJk@meKrvD?6CSA zM;-O^!a%itS6atHIjZv+V9=N!NaPTWgLS2dTW!=qwy=VGWCQsnf+r39p~az@J;KnQ zUsMFXwwMlDJMAHJ8fF0tTwkmWe9yj>z1Ct0vg1T`Zqe2~4?Pz~TFIyS-p%eYdKS0K zWJ-B^-Hj8}nfm3)Lddh3G;5&0)>pdMz3@UL-rt$I9B8owxTGq}W~W37$IFKIvK`Wt z@{A4Kw(w^yX5SoBZ5_1tr-tDNsF7!rVpP&X*z*$2qbHBzI}u=%<|ui+jat8>Xo3I6 z3cE`Qsi62xwVNJNwT=`_i(dm(L%ZI)9^7=E?7W)@Ti&;2e;U0qB=dscK;!<-1eO%}KsL{xtAzDdc6U|6vpI6|4YwD;}m6O6pJ=ro^0L zqPmwMeMb!!{CXmmuTh{SKgeoFM**m61ecv+hwdFfdM$<~+9AFlXa7@BCH!M_u3KyiZa-HzZuvD1IvUkdr4Ym@q zv~&cK&+f=*7JJ^MFZZHIp+v`|PRSG~#nFlD-nK_jadOHnPyf5s9n`Cr1#!%Uu*$d0 z1wD0MHiL0#+8FZDqMMKX)mI4)O1ox!BtN2*o;x9PdT`Kw^!Cto&~P0aW<5`NN1N&j z>R-bKYKIGzr#{*(2!X9G)N9DT#Yj?_DG$dB#pw}l%U$6w*Jl(2z>(F~Fa5j7V9J8% zJ2OmJMu;ms!J2Ke0HMIqet8rynTr-P5M+6)UTWkz#Q!%-IhVRzxVY`>AjIS0_)U#U zqoGZp06NYeDW~$pEd9=UAkdf3+5c|DG`p|y)(R&O2wp9OFt=a2?DwiHx9QujA5S<)_8+B_Nzq~>lbp9bCbReU>&q9V=Vxr}CHINzehZ0| z_l^99cJKY(`#qOzZL^pSk(QV7_Bb;T)!*_zN35TBGZBRzSu--2KM0j?IvBn`Ox3MR z$bJz7t%NcxP-AQ(F2IE&d0Jk8k}49iHl~LNsuNEcAZbs8XatROp==Qdl}7(3Yw0T$HIEzW80d zCCgnzDs$}G_X;0$OD+lWixZ20E6$%pw>(?-p_0n1TiIAp82wa*Y%gBh8NrMe?fcF( zZ(6+{y_U|TE}P!>ZL>c?8MkDq_r4hlEp`QwN}L9~Xu<*f-)cNumHmY!zQX+%5iFp1 zX{nI$LmJ%zqzV^GH$fZH?g=k!KC>s0GBwL3aauX7DqBqP&+>60N5!Am?(QM|C!+@FHZ z9;{Wlqp)*%uyM{*Sv=8sH#AuCVo>o}Iil;t;BtajU9KS} ziC!hw4m>-2CAyt2tD_oD&`##9`9ojCvi3&8Z(QlRLWWw8(_6J`OdkEmE?5$sAj z)BznG7^aGaO#%2f!1>p({_W5|y#F}=l;}W_uyBC>|7!H_`%n~&MFL9)70Duk<%8;C xVW<07r~hgJ|6A#Qwbp4+xU7;`(I{C~X3&2kkAKGfGbI}3%L>M~XZ(lnzW@oafBpaf diff --git a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcCityManagementDao.xml b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcCityManagementDao.xml index 2ed22909f9..051d742db4 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcCityManagementDao.xml +++ b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcCityManagementDao.xml @@ -74,7 +74,9 @@ CONCAT(capacity,'人') capacityName, address address, longitude longitude, - latitude latitude + latitude latitude, + PRINCIPAL AS principal, + MOBILE AS mobile FROM ic_city_management WHERE diff --git a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcPublicServiceDao.xml b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcPublicServiceDao.xml index 295ee69e36..3894594840 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcPublicServiceDao.xml +++ b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcPublicServiceDao.xml @@ -74,7 +74,9 @@ CONCAT(capacity,'人') capacityName, address address, longitude longitude, - latitude latitude + latitude latitude, + PRINCIPAL AS principal, + MOBILE AS mobile FROM ic_public_service WHERE From da0bcc370844e66c9069fd8fc96662610d370229 Mon Sep 17 00:00:00 2001 From: zxc <1272811460@qq.com> Date: Tue, 26 Jul 2022 15:50:05 +0800 Subject: [PATCH 053/155] =?UTF-8?q?=E6=A8=A1=E6=9D=BF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../excel/city_management_template.xlsx | Bin 9069 -> 9090 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/epmet-module/gov-org/gov-org-server/src/main/resources/excel/city_management_template.xlsx b/epmet-module/gov-org/gov-org-server/src/main/resources/excel/city_management_template.xlsx index 5d98937f402e3b7aff1177e63120896be75cf338..b9db105bdcbd52e1c214660a192579876630fa37 100644 GIT binary patch delta 5055 zcmZ8lWmpv6o1LMXp<}3_q#J4J9ubi45QYZn5C)KLm|6+N z)yvKR{WH;p{qBpB%BYXUiwGO+XG82turc(CGU|(gS1uI>s~Bc9&hamuQLO<2{6|e( ziu;sE2Mr}MBe>eG)vb?fz&W0NmAg2PHX2Ud;#w6a*FqT2RM?rPo-ul=M}oY zgFX|CE#jE2jMf0XVj!;>qKp=NWN$ZSS$xi5$|WuNK~=D_9A~Qb$!#}okMGYjJ(3I! zr3@?LZBIfj?R;N-OLD0wUZKLIjLj$GjM!HiwiZlH+=1izD1EP*15Z?bVQW5oNpNdJ zEx59sc+s6Yf3-6c8V5hX`8LtOj@b_7Y09^)%?}_+&446?&R@7oH1vk8cb3j`)PgW1O4?cJd=dVXg z1P29@l1_){G=*hiN+yh*nw1G131ca}Tt0Ux9N76eY!9Mcs%)ccA?KFG$DCjM`Se6` zPY>EggCiLw!YykeQwI{cWqD!$iiS7KH#j5NZ=*%M3w{tRz%vQsMyg_M;2kfT@b?}Q z;tKZ6e!iz#bO~z{?f&WP+hux!FCU@vt?%iYx$1aTadvQNinic;#kC>Zo>QTZ*_5T< z2ZQcNJ_K5Ef-2Rz_5-%28dLnmlLUu#79$(e(5hBcwk4S2;padsBQ_}42> z(X(rXk2%+7x9|5pWV*pT5<8i{6=a8vl0oBXuG5(>ed!ukEznoGSrU%SY4nJAEJcz= z=hT;vF#!NJJOF?efRJOOhqoFo=`1OLLhHZ68;lGK6FeiLN;N_3QLI$>XG(<<=j>Jv zKgGKbXsvi#A9Uj{?g3RG(mOC#;pbxx9D6g}YO|&b|7~wa$C0~QL>gE-Eg{}XfnkOd zN9E0tsTgxwDl?~R-k@%-+LJBTNT3w9YFo^7;n{Nt4G#c~;}Z839*$);A~&vY1%Mcq z$3X@VIcbpD4y2Fv5P4-GVf1%z_ip!Sq-rS|jd=DM;wZZP!6Z-|{;NY$K!+!ED)?i6T97`M@J#t5rE0I*u_jkPS6SuyqTL9aXaj+a zKw_#94UbQfGZj*BOOeAJh%9oh;kPJ}GD=2yz)hj8VC9Xnm%KWIu*PgbXVKoNoY#@q zWwxu`3#oj9#?kPb4hLA5k3xBRa4x?sRzB&d72)^~$@YlnVm5}R(iF?n7M}qdj#FAdcY>u}dnvAjGUO6g z3f2#_cJh^RguSMm~L8T>u9}i^y@see`LqLKclbEs{)#nKxiSk^M8~suoD@r0)R2+3m zv_U5QLO(*U`=JEz~tW^G9Y}0q4LwHnpcw=ITj#aYl@d zODZ+=^`1v)T$D(D#(hg!z{cl;ArVkU+0!svjIXCD*y|f519*i@oP)$F=xI9Fe#tdN{gsq?(^KYv6R4cqR6}U(n{68i&_u!HUalBZqdFCKnxVHEeM|9{PM^b_Ps)3HyJElr+?JJb`){=3ZQ#(>(^f*=P z@-R=H?rIIpah|$zTwtDHmZECgH_T_PcG_RBvk0UXy`Vx#UvPA%X~uu5Ay5BG>^|JL z8TtP1TkDWoZu9L9vTS$g`%Yi-A@nXRLS$>S+dMCHRXg9!>4$?i+`-l7GR3=lL+N&J zP}y?z43i^D2t#m&*9vCSEHe!254%4F_8z>YAc9=e+77YLI~}S9kT6V>jt+?+(gnB| z{xXJgu&n>>L|W;D-~Nx+iuO2O4&ZmWtexHucA5Vz}8bb zsSQ(<{NitmR}jC^)dPvHnyPbiXYwCFlgJYG85M8jjlg5k?*h>*6vin0tuNgducsP4 z&|g2P37uM2sJAS5ZrtNtccCG2KAKB5hv&s$hI$zDB3g3Z$WIkh3>FqT zvnh85&vM=x(og1ocH5;_C65rfJ-l3=?zVCgTKr%zU! zso52CgB$$ic*Zco&PrUArJATqnBT%}!S7mGo}& z!at=vB_!SLq7zLbWS0a+2}d4Jib~?O!=hQXIq*_IPniNy@y4tHj-_wwD&9kGPW5LxBaSZIlQ?&y=pmuWj&%^A`8F5z6IJr=E&CmZT1&{ol?u~15%RTEM$GFg|@ z);2eCZ!(O@&Vp{dScC8;#j%2u;#k;{;Bj_jNqU{p>&vZ{7dY=KUQEIO2ES8}ai)Q!QhZP8Q#_|Jqka-d6QH-?kT-PwdPi zhP)??_ZXPEMpnVZ=ZEi$Z-^_YPxl`)hGhIXXv7&SYsZvt>4q!=73WH=l{K3ZnBm;` zsr3X^>`MBvol3&#Q5C5Sp9q}to$!C&VZe8`R|y7#iYfE?bY0vPod71-`d^~*O{_R+ zGpLaWc6I*Is!cv?S-n15p>}@I8+LV+(K72t(*>oJP!hy6#uYxAOPH(KNM+{UU;S}`MrJ7-Dp=m^XYe|1I3A@dOvBP?cQ_h$7AV4nbRB(r<{X`n z1oA~M3h468zh#@{#L&?t(-Eoe=&cLt*INjZr^iers@80}`ZDRFYnJYfgd^V$Dds6> z=c=@7$38-qXd7Xobxk)A2@+ST}>bY1=s?GeCohF(zv{ z-(8j-QRYV%5JHS;&fftC^qi6*Sk!^iu`ltX*>d#dn5R(*uk`llgoo{Q!772+ie!dt8rL@P#8`ZQYr^A|&!S z%NqLdGT`I}al8?`Q}{~kZWcz6R5bB~ycZwAvn(JwKBTdMVVLp~vcO?sv(NikwHUkN zQGCko;!V5GSA7Ubzob}r5 zW6i`@FW`gPni7xZK$(&RKFkr*OWkd-L9{GQ6QpqpVk2q$qH$a3LZXp+3c@7ycj_Sm zGxhl*ppgWJq-hN~Z|<&!7L^4|iR1!#_#x>mX_W$MjC^ohP1^j`tE)ecQaho-hc?F1 zQS9Q26g%;2FfDtVSJ%iyDz@pgl|mjAm`F+>>W$deqX*fX?^m9Di=dB5y(ZG&+KuVy z%R4)R50CNj6%fyUL+^d1`yRTFd%F>-{hKXzTy$UJ*u@Vw33WuC50*N3o*a)|J%a0! z(+<9mh{k}&r_87qzA5aH@BD+8aKBm7|1!dE!k|pLJUH?Z^YW97D4CnuI8zh0-k=n; zoGdd1xVBn!RL@jL z-rh!k68xr*mMt^qG6ToK#bHaCGKt8fk9&F!en&NcG#5ZUT5yCk%8E-XGF9(UHOd;6 zxv^(v&PzC9V$GJJ%YwrXfSmS^4Y|{NfXbXZPT`p-Cx&-i#-jl}TWRTxFXNKA9Vo`OA$C(Lx!>oodwG*&BMqGW%Xp@Fd7Kg#6{fU>Y@Fqc z&x(9Lv^2Qjw2b-Un%y*D3VNaoMta&~-|sHoO^p(Jo(P(|c;8xHv*KKGbsf0xv@z>b z^NUM`CHA-teCiLS>=Tcoq5jb?LXeNTo`Em_4EBM|i)azMck7Ap`nP_q@%W9batsN9 zjkvhP%!Sd2#N2K#&ay4%-z+yr%n;uet&&P~9g!ri{+6)}xzC!;-EzELg1z6|M@M%@ zjxK0ifyY`=2|C%=lmfb7g~Vho(kss<_dDkQYlSPS3B+#xem8-Zh#p!n+&!&P=dTx5 z4Pd{Aoaivp0w7Dv*VsouBfDIUc*d<9f;JIAtqMoXz*mj9GQ#3_tTCl`3=Hkh;SoX* zr;&hZxvnp4KMy3mgIS|>H4{k81-zq9k<6b2RB3h!UO(Rq-~O_bo)K9L23Agh< zSM{CVx2nsks_UQ;Esv&qxV@iD+fcEvKc>vR#blFpOx{I<=U-wd|5r$0j}<7&_%|dN zL;Rqlf$NR`11&XT3jzZFe-HKVCUXRcRT{{J&}MxMe1?c*VTK2XgdVbN~PV delta 5001 zcmZ9QbyU>f*2ZUO>FyeGkOm2d9vr$$TDn6@O8nB&HFU=SG6=#@k_t$tAR-_l46P_2 zg7oX}eeYWLy?3v5_FvEW=X3ViYduf2`hi*#5{$2q5Gd?`%m=dqsaY!8gJQHJKcm+w zHox#4NaxH3m1B^&{fQgGJib=Vn%dL{PgwrkxdMHWPvWOw$9t2asub_uu|TFk)VX55|6@iwQAHoqAeQXaL4e@)0x5bBrc7aF9S z6=mkKgy8#T45dzcM1EzI$S8l=Z%?_w@d{sfs*J1+vz}d7Lg!Os`dPRAt9G-WzV0&P z1cr3njBRj>;%MvZ=1cYkebY8Ua%ductu<~-r(T~eJHreG@Z()bm8G|s<1qPWjJiO= zpamwRNc783McbV+{WI~K201r{!7S2&fVy4(_%{FdFc|x(A$2D7c&wD;2ZiPXId82| z)8AKSK#spfMm^;%r`mc(D|B!6Nvn!AZWiq9bVj2OY@m&cM+*Xhh(OQvHk50}o9&@s z5QrQH1foGo;xYodo-xX_h_kpG!h&mAj%N>Im|3L^y4))2!kI=M%rf~6w^p3I35FNu zigdZ>r3c?HzO==JvJvh;T~-APa5fyi5{;RzOhgcu23s+L)r-{Hr^-#$P|TxSF7jZoDWPYJ+&FzqYj|Ig^6elXRb1u>>qUbWv=-7#Gj$9I(Ouex1Gxx62Y@U~EIVXtBE-kwb7N+)<`DE_? zPlfnr%G*FOTo7oD5cvU56u1+M(xc=-AnsD{$0_=L*X(gPkm~-%Xe-!uYmj($142_$ zT(jVny|;J-hnJU|rEY%z@x5T8fGItu0U2v0nUR#(sxQC7OOL8ZFozu=^*MqUr4y^~ z>2i-Fh$H-olf1}El}Lyo=_aJ*!mSx-#l*Jhu(YZHMryQIrb?0wKm(ycA3ev2jLF@%K-l)V0LkInIlFB1bv{bgE}Of)&TmnUAxN<2Q#>BqJ>6ym4?M zJZquE-J{uTH9@oh$(>^u`L2CqtA?71u>{dLF{_3vUkP2Xb;m5*7nCn+7sPau58Lj4wKRbV&wM$&efa^M^VmBZ)_#^? z)NMAsfej z&`V#p*%cx{lG>pn4Zi2~m0+4wo9SahiD_&{3S%SJmGe6{y7!i9b}e60s}$5_H5%L- zlRRTnCV$++i%4$wRH0QZ=ej%*hrM2fH zqV3Bx8s)WLIFu9ZVOR7C59n=)YMgv9dH*+oXnH^e@aR#5T=)Gque<*E2R%98zqou= z^o!&7`u5J^w}}e_dtBE>R@n)Nk}@PZgEt$yk{N}vv^yFuCjk|A-D-IyygRhujqiQT z;@bO*aCNIJJo&g;N8iEtUGyNZE&&($bA_LGfAP}%b445yI+(ju>p$LfE34CV{n`I! z)Fa!JkXIOkX&8oMKZtaQKf4dE-zhYdp@Pd07W*x%`Uu=>3A%A-zaseic_1yCM4SZp zbZZ4*UZf8>GvJxNV$O7v_6}&W?te~K@F^|8FIb`)$)v48Vp)fK~g}yh2BENrDMVmA=P6-sdojaa`L!#eHxu z5M5Y#4?Wm;FfO<9!_AF+PxG0b)Z%WjS_i!$}eN=^qT(Y2(E|GqX zM_=7z@*!MTuwP48=$*VR(l+W<>9(9Bc&DqNTVQee^Nz{7f=y~=cZ__4jO>vjrgq@4=L8Jw(bTihBSQ^YGWm;}fZ75=zMHni{(36RbOhTYBXqfaS`X`hBhADAIpu3JB8oSTZYq%bysbiGJDi? zs|xvTfUub3_eaUM1@{Eo!|Bh<`hn(CeqL{25&8nP&eXJ!M@wKd1c&*%*EajoFE~4X zHGbL9vgIheHyCIk>aN88X~5v(E%58I=^YQEUXCEeVXV5udxSYw%;n@@ko!dDB<(%X z9Eqwg5n)7k_->~SA$h$x;)=m=V2<`Bylv}{=oMF{dk&FAAbV{Rd#ckW>g|PHkUw?g zM)Q~Z0tuOUEmXQkNT#zMX$jhMFDD}ZU)Wi{x#YOq^plb7dt z#j0v@pMq@LsMf(4=aAWm=W+5MtyQe!&Ii16bJ%@cy4@uapQzpQ-{uryd%9~R4Ymnq zD&;wQ4^4B9Kt`}*P#~W<1*I+^#>{Tsml&*OfSj}VLVyBo`Qq(>@>W^inl;i&}G(aWBI7k(rPMhYrnE4&H+?vl_uC~QJJ|w#3y)MT-@O=h z$}wBkLQAB@4$jrk0pA|hNMZ!;R@qLt@G^Q3N$WW0CsBKlPM1BTeogN%#0y3nFPWm4 zJ-)u~!ME?2g&4am;LPUoen{bf>~EcL8|QL{zDN_}DZviY?GVlT_-pn5ZW9>V6!v0q zkjM9azntyBM{Xy|P(|CC6p(#a*3_N-MfDVJjvw!0b!6ifE1+M9kY=-JV6hfWPMQ>} z9PVs3iF6{!VwMSnB6CSOJHw3m*b3kca5mJGdO@}mYhAzJd5+LxEPbp*>9n1^#R`#r zEDIBlK>Mhme54>l-@D1rZy|b&iBl=}}9B%~qYqSZuSE7Ow61eTk z5QTOZuST%7N`Te5pH9rae09I?7RvqJmX#5L88{yTPJRaSzma263Jp2h8<~Fuh=5ZP z^fPLqNaoN5@h^|4>R=H!c29pA>O@g$2$XA1evqnBjv>*Ck|D3AV_SQ3xv_M8^y*pY z(R;#_M7QB6qm7bkcddwu#22nA1s@JCIow6Cx5XpNmFvtAtZKeEm*zo^FcSqRTWFoc z*61)CurX}WDA;w_xw-r@6tja|Nmz-t{qCLi3S3W~8A1aoW z0zpTIS6k{o^;}WMvs7I{$1`uNi+l4DHY;#FNUV$YxGB{+llezpY)e6e_{xfHo?e9C zDQBQMGT{1&Uvp5Rc>e3p^%%J)YR;7v0*y5oIML7fg_2`Zyt~F@-yh+G5z^ z%LR2J_AZ9-5p{_ILrisbyq)(i)CdS%E;j;;QSW#rjHg z{c1`8-Ne=T``x8M(()yVF5`P&rCCRTZ=;UqELPpAM?U%AJi%T__4_(NY{~juKU( z9JAYFJRP+Xl{%jzO=N9STB0%g!D9{TneD6Ey8~@yJbNgr_R9>e_WZ97rQ9C7y^->* z&8Rb(UlzHKzf)AsfDI#fYh=!IF=OI~CNjHK%EsD>gm0)q^Bt9qdU&&SpCyeDka+bfu|0ytt^KYj| z9&`GEy^u~2X)qF51QBNW?-~BLwi=0r@c+v){oR&eQzS1J49tbJ Date: Tue, 26 Jul 2022 16:02:39 +0800 Subject: [PATCH 054/155] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E5=85=B6=E4=BB=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../excel/city_management_template.xlsx | Bin 9090 -> 9099 bytes .../excel/public_service_template.xlsx | Bin 9133 -> 9178 bytes 2 files changed, 0 insertions(+), 0 deletions(-) diff --git a/epmet-module/gov-org/gov-org-server/src/main/resources/excel/city_management_template.xlsx b/epmet-module/gov-org/gov-org-server/src/main/resources/excel/city_management_template.xlsx index b9db105bdcbd52e1c214660a192579876630fa37..261a5daa08f5f1cf1fd371af10af37bbd9adf1d8 100644 GIT binary patch delta 4030 zcmV;v4?*yPM~g?WlK})ny7K#zmjNGt%SyyB6o&VL?@+RD(~ENi~Hl>>qm#a&3w z%oN+SB+<_727Ce^z@1BR<-&#F%Q)y`n0799P!O`o`Tz6fKZk^aS)N(9AXQq32zic+ zED)^VshC9QJQ>=3WGPJrr&%E&LUT}P5by7WtR$?Ea4L%uq)tIuh9neWWrU`GT9*W4 z#io!`F(%BiNf2HNG8h}KBXw#f2EW(|Nd3>oAg zw8Ea_;UBLCnX5k=8l~mTQ#~)uOzXI9HfJkw>z=7}Ypkluse&ek$?xII(aBjes-22@ zR}4@baz>a0stXx^y*w_TAIu48ajRNyFr!M3%(BNR@WXk$d|NEv?>=4^pHKH8{;eBm zGsB7u+%l=iYKDz+5gZ*SLlpb2@7r$I_IioeC!GW0x>xn{JN@lg%I+vo-^i0e}48JBLaG007_!000;O004MwFL!Tp zYjbF2Wpr~db7*B{bTKY?ZEUqx+iuf95Pe7DAFLJPiTai_X@X-!8wyAuA+FCGdlIj@ z_L|*w+`b~gCmT0lf{_IA$foSE6RgIk9wx7HvP6WNS- zwtq`3$RZK5Y&9d#p6+k$5KC#A#gvN-X55tR2RevKLEQqSnTrb1u&7mDZj&?0@-}vPcRgmfDU)>eR0FRZg5qM`s%K4E-Wl zDU}CBzJ-Q!6t`fU=_4bTgng#Lqd+i*>&g!&KfHr+8|85bP-+`vDdfZcM6jrZhI2;B_u9Z|3Co5||k)P9?U-vLld0|W{H0F#Iu8na0VAO;2e z{FU`BlWqXNzussB`MN-r)wVcJW2^8pt0?B{@+YrbSWfP!CkE8;- zLxF5*=B+~p4C$7wD6p=Dmpv@r)(vaWHR(SSDe_bQg?;B7@?5AxiB2qvwjL}|{BFPR za=vq+Hm)BIUFD7)gpTjERefDk72E6ieaG8tt3SA9f2}oDC5*aWzw7#*-Byq6P`$qS z&2Mak(UEK4+_&vW0Ty1^R`;Xm;98{;_V(>zH(d7*Y!AK}_`$Fn!N*{)5*`G0w;v*+ zp<6LDtzH>+9Z%id@J2&x7==pDA9+z*HR&aVeDh`>E}E)BxOMzKsB&BR_D@HC^v2g; zosc(If0ZlWxpGBY*Rmj-08Xye>wuY=evHOL=Z;cWqif!4sCMBfB5t_FP=TbckOqB5TcI|R!wvb$6kEr z(DD2LU91op*^+|2-L`63){VxtrXh-j;_zLsChS~hy}q0awPzPWob9S=F6{KYt{P=X zi`}KcpJn9|nG;6Aye8r-L}Ib#HNm{*g?dlsxfshu}gFGZ6%7T&OIgQabZ%O2b00i-dAc(t*?TVw0|r z0gh%kD$oT%iL$M6K`DUSg%COu$8~8#3S$jdLCMMiox+ zyh<*Tsjb&q@KPD-nYuKFS%Wol=moKIuYZ{3Mwe<#o+0^UJX0v5hb?mm~o7rOW zi}fb06gyk3PBAX!uwId^mepCdtud}QYUouAu5}heRfyq6t=6pREyL6cOVzjve->Sl zk{C8Dcol{9a;slrlGSN+c8W4-Med7xOgf0Js08E5<`OG??9xts$12LDwG~$cZd6-I zMS^ux(wD6$q_~l8)%LGMK9|zP%4g-X(<*56<6?a!9b`d`DpyigVrHZ8!EhyJa+T{f zdt^MZg{kzeAM|01Nr`uNS}=<$-nwhY+ir1NdCld79a)x%_84anN*`~ro^E$I( zY7Mhy)N!AfTXtehw2ybn1XH#Q^g>}-L2$%4=A^)wW5{z7fO8VxPqwkM~yLMpV^9EQ8e02+tJ?!(1L<4r|?ZA)hUW89Tpgrl= zP!jFl$4bJINI7-nfULqPhH@$i3r7@51LiVJOK4B#xVtd->Vi@bfAe#cT3HNM%athP z1ka)>L6Eedny?hLAgS1=V)5kiMTaQ}i^P>X9p%WvqFZ7(jnbAM&gZbHRwkcw11+cI zWzf;M3?rfe>qaHYaL(Ikz)5-w*c#-tT;+(!#h?M@sGQINKnZg2wwyY0oudJumQzU` zQaC{pj&GJ!OAboCf3*HaDV#tlAPH$crR(MS_v@+?ZX_U3XM5XMXDm`n_I=LRn7UU0;=;>E>_8`YBOI) z(enjpY@(8L>83PXoh(-mWTN)$(!t3!y64EJ!ebS5OR(kIf1*pGF&DCWdD~5{ala(E za`Pe7K9#eLN0FN}CjzdZ{k%a|Sdv?A1I5LsQQ97!cXqi7Kk{%~_cyJUSynm!YC z^_OlqMfE*NcOl!$)Ae&PS_N&(Sv9j-Xi$D$(JXMn&N&*CEhmb+tIMh*H+dHl2Cf(E z=?cI5PWIxte{FczDd+*rwmN?Lbo%%`m71>XjvN=x=Mo^`d`Oz0u6;{cQ^sF@ zG5zPg$sdl#Pad6p^3n9ypDEDl6Z^m-j!6xl!b)>7f3mnhdJ--OJEjUueqE?cTSMiC?H2upzJs^dkjO->9V5a| z)TC)Lf5Qd*8;1+3B#cWHKdqRX4Zt0<5yQ@uLMB0g=^;iO47U>hXPN`jV?D&cgM$X= zVMD_guZ=QP;DCUH&GhsyFHav)$ztfiSs)3C1OcYH7*wK6ysPijfB!sOJ$&4aPe)e+*<;q?E9k{Ofpf_kW3Gyfe>8$b+Tn zXdQokO79n=3Qp|EM0|R8^5>KBgWr$u->}AR1JpT0T`2ES<$58YqAN`#Q6l10))iE;wX!7BcObk}?OBiWbW4&pP zf8hBqBO;H~rHQ7vO8!Xu3DsDP9jQYy%RH5h7qppdSWlE-HhysL#j^)cGtWN!AQ6vG zmN7y(-RGZ8Pro{Qbo%nc_on~7fA;YC^X`Rn+1?~5@~O~scqC^IW79im`lf8gbt@@)P0-ylq>}$qK!g^j>K_nOevdKHVqK~mM4NuZi#G(qZq=e7?WmKrlV*@1#Njfe<0^2 zdXTi9srt~l@U(F5258xI2U`263lDGLlgG5ThrsCDgYL+UZqYB>DtrGu{2&JSD8B1$ z=Z+s?7HyTie+xZqLdw5=7`+w3a})4i83j&T{n^e|qqV(b8EZ{#tGQ-Y?b=$awza)h zGdo+`+g3|6w9dPbG3YnXt{v*;Kg{o*4V_-#hyEa1@4+)H{$Swr?Ac#FYgJmwZ=V5^ zYoQBw1+lTQ@;BMFw#t1V>SMS-Z2&DXq7u^IWZV2dv%VP71_9QSkRLz+K9kWOGXY|g z1t60IL%Q<&lbj&O0g97kAvOWAlbaz&0mqZ$Atwd={FU`BlMf;l0dJEfB02#)lVBn? k0b`SwB0vH3lh`6&3H;wXhe`tg0N|59BRvLg9{>OV0N$dw?f?J) delta 4047 zcmV;=4>0hHM}kMNlK})B0^*{RmjNGt%}T^D6ovPK?@+RD({^S$8rlx1%*p}5isCLL zcgA9ymL%Gl-GEQv1GsZ3u3Wefd>IFQ4Aah!9TbFYa?iP6&b=fYO!LgT1*y_PM96bo zWPxA>PsJocXUWjsLzdE1aGDhYA~XYq2J!Ar$V$Qr2`92BLFyEgWk^C1Rz~Q5O6!tf ztk@OgR5`{Wj5sc2PPMtp2`(wSrW3%v>jpRnO*z#R*Fd}65YY8_cNEBeU#r3jAOeFW%;h_q&hR`RCJph=1z_ z+RU&d1Gh{nvYcV9oOce7k|BzH*Y|BVu)Tibxun-6u6tQOztvx-To&?Gh<}NF+Yb`2 zN4oo@8?=aPK-}cs{u%K%vls)i0S>Wgk8w5w001Kh000;OlUpMif3;QHPTN2beXrDi zuvS%{if@60q)8AYgd!CQ^+KOF_9R|q?KQjW7+x#2|4@nd{s5{F5B(bipV9Fp24h-K zt6H-6cII+sX2<=llaL!rkcx?DKpfL121K6lSu`Jzj~^y$o5WC>Mn2^tf&n=NMYe{| zpY>BA7b*bI25N}Ze}Dv9$34qZUH~CgridZJlbMhq)wq;%OT`kXp9_WDa&5b9g_K34 z(9n}l(II9t=D}EaNeGcHlt|!IqyH*kv07<6@t>s6mo!DLD}U~|I4({qea?ErzmR!S zC^6HfCqk=mt;w=$b!$9Buc7FHV1-mJl6Vaj$4G9OdLvTMw95G1Mow=du^gVF!H29cnVq`g-3bDw5`?zIix^qCLk$RdfVFa8H z$X*M};5fH|Q#4>z7Vgeh)+Tw@52fM5j3!)<1pmZ*9Slg9toGiC^bN3ipwX4KiDf1d z%~=F*VF?@se+HzT8S(^2t@t%UmQ^S*LV8koUubkYW@m#KUZS)JODlN{DjBzw!7(jl zT8`Ov|15-rb3-_;ggU14h|qc|gkve>Za!)W{m3ohxU$rGRH$7Fbt)m(HrrjdWp|1% z9yCK@717LdH>R2n`%h zlrtQ&j$?QtiL$_95b8&UK8>+oa;7vfDCZ*G;WS$0QB#3P_oFz`2cQ(4BP??QH+Q8J zvbI^=f4Q9(P7hyueRHGJMpIc=O*nOiFOL(UUtfJayE(tOy7+u`cKPc1+s~Wx@8#m= z$CvBNa#3LWRwdlG>Ms9=f)5@GDaQ*MgQQwu0Zc)s0NApiJIdg~I z`eWasTujrG*rb8r@L#x$kqf?m!KLE*5Q}@XJg^zYSTYAx&KcGphZ&Ziowq<)bkky? zMVyz_RA}sr`82@4FJSg;6I;zp2)$Zhn=Q^J`DWJMtKa+Z7myyaS_mTse`eyJhd2rV z0NG6d01W^D0C;RKb98xZWpgfgZEV$C-H+Q?6@N$Kf3RG^10oaKalX2fDV@w%T4_Nm zwMa;Ss!Za{SaR&aajKa`D;2tBU{R4!7YeJDSavm(2Rgul*lO8!|CuJuJn=7Z?!ET) zxyg0nwiCxQc^KRA`TCuYe|xU)bvCaZ4P5269Sj}cYpME%rYg4A^?Q!D-%`JS(<(Jo zWf*q6UdQ!4yQLo6L-pF$*T1$o43Ay=#(`~z3b62oE%hJ_53iQX!|s7S=nOafL)(LI z`hGCzgm4<{mxqUe-RTVp(ZDSmnpP_hI*zAqZF-}DH3)}F*B^Ode@iv_C53(SW)Cjv zs=~On{T`@tOZk>^<=a=TXt$I%$nlR#`0SfM8TsKGCH9Zr@ts?WT8>3wzQ!zHM)be0 zPT2t#GxrsiI`<{JkV%QktP+vb4QZH>`eWBfimUD zyIY%m-%FfqXy9dXe`RZP_>OYB<3jxD#6w-*^#dh@Faj^rD_&<{vpdFTzkdGo0ln*> z6AU5x7-7XE*J$iTcMcrS56HzblaVed*xzfZmStV9?`RsKSSpU*^=iT*v+|OY4Ze)_ zj0nUMS49A7@Ml@81~B%PMZ{gCusv*DgK!oCv64xao;47ce_+`F;~J|oZ$8g1*gOHu zd1)6KmJW6tk`+Zt-6Ee%-piN=X~snYD;D|WC=hBF{H;u2m2h5VE-b7mHGPF?J|8Xl zi~>=lG~1BowUs%J=Jc8z*KF6S7wfnMQ9|;qenB|Wc3}veiQ~GwA%&{Wu54`{cEZpO zJPW>7qT`##e}~Yic+emdSC$Fo(!2MA&arOL)XGLM^j)V%wAgRs{s{WI&>=l@N!wuT z_M#gcuV)|G&^XsA3YGVId!i;CIwy_rck^Hsb zUtbsg@l3+7;FC{DL$(!RD2-53S@>wyYvHPI)ZMRn}E1I>V5h-8yMYgtUyHwdvaZ5C(w2**_rv zL;sKr2Ywj(132h8oqgZyxNumGDdPVNC}G747N=Tj&mZl%Hb`U7Ksc80aFssz0iHzA zYs(qfJ!drFa-uSb`f8KRYs|W-)y=9=qrK)Uf69(c3lHeJ88eIvBsc+tF@o{UGdKvh zXN4fQZH-c3|^V6TuL)<=TZ`hrAujE)>avG z+XnfNHZ!X~5yiZnOGHSlTtbo6Mle8DSmHQKOIucLvQ>tdmrUbi;UO!Gh$0(|h#(`3 ze~4lcj8VCT;@!1f_Xeq_Kj`xcZjusy)JKcxuy24Yu#$CpatKdAqeE7%*~!*s$949- zf$hPvtsR6;mn`~r;nZd;wMYGQwq%t)Vq1a5a?Drh93HyI-y03~?7*V?4X76M>NXvF zlJo1a2Fazj13$F8A>9E%)}&uUNwSI`e<=x%uL`OpLQ;phLNSqqr;i-U3TT{Y3GMv? zf9K}k3dDJ$6r3zjYHdMi09XZ5(uAB?UM3il7L=1DM=i*z3w=EE!BuAE3 z-6F$T*g}qd4wKIU`5cY3SV`C%S9m4$!j?>oWO0W?(2RE%LguV6J4hpd-~L0!~m7PBN>wy{>t` zQP_Du8Uu?At4Xr?(#>j6T9I;;f0UrbL7PLEnnblrhbNSyOI8EWP+8>k0^Qf3n5n*_Nf8FQD}`J1QvKY zhj9soBbrje)vRNu*pudAWq9M2R^gSS{sk<@6Q4#M z1jL;XY%%|+5W-#LHEwo>>WD5ZwIBF_^A6NZv?CyWj{t=QfIzzw#Jvd|Hif*)-BQO- zo=hLTr*hMky^-U>%S8+bf7tLbOHk9kp_G*ImtRc(ad-0jlkww+=bwBu{ncj*jG@dv z61@qND%~zK%f(3J0#%N2A=o8cVCpN;MWO|#Cy9>e+53#~j*ZCp>9Yspd#ABPQeYDb zcnM!3(M;1D#4)`|yOVIK(5;D?t>;`wLxQ-lm#$~E|M#Qulb^+Me@U~NP|!WkUrhe~K`fKZjS?dITEnc&)Nld+M&Uv#Ny4QzN4bdyYi3hWP%u$i9y`Ni2oE?Epc zcq%O+ksy$$E=CB)WpDEF$@wRLP!br#z=4GVe~FIMN1vXbyg#|~2#WsX zqrY*1V$4*fI;MJpCm-EDl7u_^t%zAzBfWW!&^m6`aG24!kxa;_6UpWw zV$MXG+|~uXD~vpXRB3jlD$gq_Xp7lE&Py<0X+2l

x5suxbXh$#e%=`>+EqZ_u5` zytjwI=-K_w$PI7uFI#GI{9XDY2KXqt>uu+@A5s=AH93BZylleCzkL+GHG~%y;J-2o zoR<32f8FhRb7$8wN)2thQ8FubwbZO`@06-$dwXZcYHEhoeit%^{N~x!Bi)?)-Lrwy z4g8_s4>!8-4vXLKJ6(JJm(QBzX8hY{z~t)Cg}Z{t*hu*s$+eb>PMG=>E>Igli;XA` z`ERmq{U1hDy`v3p{v)vfG1_8~JnIAv_HIv#OGXYtX4j_{R z9RlK_lcgZX0fCckAvOZ29Fxr)9FxHzDgnNe>>(!`X5ycRI0^s&*-Zcd4FCWD00000 z0RSKX003K)E+RSsD3fU-HUUqQpdvs4>yzOkUJ0>jk8w5w001MCNFzN4Wgh?l008=a Br}F>+ diff --git a/epmet-module/gov-org/gov-org-server/src/main/resources/excel/public_service_template.xlsx b/epmet-module/gov-org/gov-org-server/src/main/resources/excel/public_service_template.xlsx index b6a1f0d2b8aaa5732a158d11203d5702c8d008cf..893bdc99ceca4c5ce6862297de7757a3eeab9ddc 100644 GIT binary patch delta 4090 zcmV%9Vh=1z_TF=msfml<7^_BzB3Ag*(7|BUz>vlj!i0S>!R_{4Yv002h_000;OlYJu^f3;Ri zixfK)-V6SRBFJ5}_3G)T-7U_PbFXj(@wrY{rMtqUDrJ)Dn%NDApch;S_bRRgQ4j>( zxzV5F%s4Cmf+wl2x?Q$917bsUQpxw7obQ~I(>=Pln=orZgrqzjBhPk`MbeN*G@Xyp zt()8D`^b_Crx9j6C1bQlB)T{`e|u(BaIqs}LX-s-QaMJkQrXaPWEhhKOPgmTg`F7} z30Ckb=8nt+!I2>)%<)~f>m-<_sI)K?r?J6jGa8bBhj~I$RT>e5VFmunm}auFwi}(w zUL8*f3cHi=fQ9W z;--{QwP)m_$;gE8ns6qgh(Z{2?kquOV|2+I{^=oDH;CJm6mn&5DLlPF7zq`LAlJy! zIh=C7qk&go$byF5+Z4bx zVMSzybEdX9yF()tkI?{Ce{0uy@fV@MR6JRpV!}~#{3Qp*qU5wYcE9&?QhP~)u_E!mLwP} zl4o~MAb}r75{yfd-~Fi`*foUS{{+|W4*a&;E5Bi5JseIMNt3q#e=9s030_!mUm&D9 z32jhXvg))z`ZKJrxi{=Vm4q67Nf(770Y}2>V&aaR1yn(}M3}N^BD^MIYu$$5LXl_|*FN3yO z#GDbR>x>AjIK*yBe^fyT^ghfOFE$xYcTAjQ%!?~&maD5oN<0Uub_^CT3&BNWvAm8! z&kDR@(6NI4FsN?jWTg9U&akI5QqQYZe=?{)^|lWRo4)@*3!_r~y5G${T1`{(%H>lO@$5BFOKkKP>p`y6Ipe?C4qc>D6p$A_)M{a1(o zJwAH#taWhz{ihF4N*lE_@3hh)64C^--;$^;=$r5?`{s(^lQJ|I*pRJS%=hy2P2!+S zW>7mo35?foG9CD`J#Ac>TAjsG)yy%;TM`feY!S)XPm3*1sZ+1w`~@6 z->?4yOuhn8kpUgEcnBi~1)Txs@lTVW4jO-LkK4u({$8N}fuPZT2&xm`^yZw-_34g4 zfV2o;7bwschEAgH2vFpeqKvx~0o*$7wJBVna9X!PfTjtq?uYu?rbT0X@3hrZXQW=+`Q|saN71S0+&FTaNP#B&QCmHVqT{R8>Zo_*47;PP z;Mnou${+}b-3Y#hht<(>=ydxdBsBD@hNji4!>;SAJKO$vXb+>2(hJ6Z)K)EaN+DNX z>%&P)RY+@{pbw_pQojAuaS*-w#pi$LW?eSuaj0P7*Qm-gf7yTx*yu4jArQO&o)^u`0XnmF4#(eukdLBe<}eX3Sg8)*_2rbk zlv^3~93a=zAv81jq^|=)TZ4a@)Ma#SiCb&cBS6?h9tbR4Glb)mfKetk0mSB7-E)^K zY}n{;opBTJ#OURTr=YEtcl3V*ZCu8R^9ZC8J3lZb3JXbG)Vo#($XQ1a=b0s$vU)B5 zd_t9hTY6#2Oxv^@YlSh5l|>FX6iMWqxz--AB4MIYXI)(mmkT4POkB@n1u2Y;#-6^DNvzCMDYIC4?V zT+y~ja|iSW*Y7(g4iwIHTpLw6!?PN>N~g9}Yr#LW*{U0@rmkUk^4H&recq7%TB5%J z?l<*%v)OD}rjCKm(SO>%(D>5nAg<-8i{_1b;;RY1HfptIO>Y^N-YQ0aL6mAFZf=^= z#ZrofnWJ>E{!>a{uc3dxoGBG|AH#;ff^^xPMrS`~T{MPx+LC`pU?YyURV-EG@Y(yj zt-P}z)zzu*+eL+s8`X-X#X?H;b6sU4`njyW5&iJ+m=vcQ zD%3dr8}YxO-o({t#SY$-=6D{P|G>lb=3)mPHoh`8Z$v*A=8b>oZ@g?7gD18yl|Bf< zJ}faQbakf%vsiL!XWMfI5zJ#k_wWdPM!_+f)dW!#4B?>fb`Jx;>%n0)mWV%>NWzL0 zEKar6elR}p9MDFdJ+g5Qp0DDkXwW87^p*7toxVFBGChmQ-$JuQt6^ykt7g=3>6uw~ z>`ZioSIPueb`5{@hr&`ta8MjGN?^<}ElXfEHNM zIz2jsC!q9@q-*kJXS?gUhyKv>uF^d| z_D;V)9v(QMjrSX1EAZJ}JoY5tug4Z7r``yI$mvCR2LxJ^{t8B-)phE-2{@F~NDfI8 zwi}ewNF9Hwoft~kDZp6?7na1ku=pAn}#RG7ng@I_s7hPIy34B6@Oz7$0*;IHfnTw8@AEvb2K@Z)CYLCPzt~%j>!T zY|bh)qR6J_5Zxt4 z*+TuDFK`@gLbre~nJwHcbcVpC8(>^QzvUJeYa`c_%Z#dpuw3~hi4dVYQ$&sc<(eT{ zDC~b_70A7$6@*=4 z3QT?_wn(gC@~97S^5o^vc*h2He)jCaU|L4)<${_^7DA=4~U&yZ@CAdr|YvJRH?B|3jE@BHHV zlgCV_NITg2ArVRK>`CxM`dLyAOwOM&wIcHj>HVo{nZtPdOad}&Op;hX{ny#_&i`V~ zhDbB=V(C0vC!buf`$bkk`5{yB(Vgj^&nNePKe=~z`oU*RR-}?4WhBaBXP+{Wxg;h{ zd(#ijEY z2wwFT61B9M+2g-Xe)o>Z5p#}TQc|X-L^edh$iVBjB_&&BklOGQ%I3HnG* zH^uZ+lQtvCtSrAl86cQ0g)TJ$%nopwZ>A;%a)B^ta?TB~(iF`zmFp{L&4Ck@CI;Fo z8BNfGbxsD>a$kmR3^ISTBaUmvk~TwiGm2PqOq2V%q;`doN6;$mU8#X$85OMMn}I$r z!GLt@g{%*i3omQnRG3V6ptO&=@bU)UdCY2iAV%LAbjMzFlU;19$?^B_ix?0idele`~40gaRVA2R{5 zlQ1BY1#LxzUt*KUAXEVslN}*I0dA9CAus{ilaC=b0stM8?;ISH;~^>n78#QdA|@N1 z0q5~g3IG7vO#lE5000000000103ZMW0GyLhB02$SlZzrY0g#izB0vE{lLI3>0gsbF sBOx2RQ24}n0{{R=2mk;W000000000103ZMW0K1cXBP#~I9{>OV0FXeyGynhq delta 4047 zcmV;=4>0iBN3BP&lK};O8`wr;lb8W27N+TN)6jLGvXcYBisCIKZ(FfVOA_6a*a0Me zI=7&7lFL3Ko{t=mJQsYUxr9DifJTF8cPHcp<+*}Wl^38)0@|@8 zsVOh|XlhJBG1hzv8PlG1NGpzWl`&(lYJv;Kuh|4};QL*ifnkCfhD)GZG(@yU3f>@# z8##9pePiaas|xfD*AePTs=S76XI62++fPI8QEoz6A*`sX!W*Sz2AMj zEX;P$wi-IojDOLF9@_)k*=CzQ=Dx*{*uu!N4&a^IPzORyu=0tg-qy?O; zh0KYDrQGzC}D_v{rA;ktVCpDW{31DdZX> zlf#t|#|C&8wgO|@0*pnHXtt$?l=B4!t4KYvceo4u_J-yB&Ahqo$Y%Y4L@8a9it9tc zzhbG*7I=!Az0XAbDP@~XgMTX{56VnbnzMr5qg%>>u)rguBoQ2}!avHHsZfk^a^k#q z7NfBj4KYe8rA5BG#m1oJL^}?Qwc`wi-emlK(qKn|u^~;o@QR!EcO)1aQs|AYAb}rN z5{x@iGSihuN0#8kZ=a0={6`4Rbc`LLFgVKeOf}VtTVwW)OATE(E?(( zqPnIO8Xnvwho52g`qj5*zi$8f`qh)Y^T)rP|M>mI z%jb^VY6`EbDWwU^3IAU*bO=h}=_|b|HPfjFX==s1D?$Ir7_`R{isn9%8wOR$=^BbM z@JxS`uD`m47Nsq$mC(>B?KFe$F@?emJOHnS(9HrGuRA-ko3QlT5B~CRkRG##2qOjs zl<)^sF_W(j8h_hw+twL>AF%&{V6Z&|lf|2EspTw|O<+Jb6i5aX*oHusD4PI9dL$Lt zEe2#uGjAO-U`V@cMS*oKyzF7|wr*I1u1WuyNRglVFZ4SX9v(`Elp2c^Z9SNz_}zZr z<$OHnP@C6}hK_W{@&ns*+p@Z$$dcvuyuR)3x8)z-GJh*gSqj3g+wVG_YqjNLE0C{m zefwLRL3r#~HxDc;lz@dBwB>^^JiJz|2E7Ao*bO$kL(7G42A)6chH&cdSA#>}>h=Rf zG<2$(qSULyuI}4l`d84tDBbGQQ z@_)?n3@mk1HybO(a+HlFxK1(6RXQ)jy45>wfptx=u31Pyp%o1IPcIBk6M1hnzQgT8 z0G)~LIIJOsL5p13+C1!rq2;?Kd@a%ATgQjcskqP}BNeKMa^cf3K|i(io7OUJB^~^itBWW&EaUI*G%~2oI{Z;v(sti z-NDQccg5n$x{7><8!Dy|kE&}iv!H&MGjlD~7f%!9*mg5-77{evSXOL(WoEKg@PhL3 zgDpHt?|FV7mYAZ|ofbUBl1p2gj(;@>0af4LKS2LO?+{_^g`qcugTCF}_uQ@nht-H8 z`j04KX$n@M+H!b+SCPn66)k7m8v3BpSw*)}8B0=NeXu%95`f~7-b+#tBNy8U25{&I znN!D+$9#b%eQ&hqSb#bKC~^C%sR2q6!bqQ?)wf5(i;0MM&8SQL8BZvQ{C~NSX5OO< zNfskHuUgJ+l!j5$>LkpUl^x+M%9?mtMTGJKig}C|5C{-nK(VZi$*h?R zSF!I+6Q)V=$`4c~XBL*(5i2s3qgW10j$lbFIf^VBX}N{s-Lo9$CMvUU4p;>@ zPzgU8aO>f)ZvZW@qIG(72!Au6^pKQmaek0N#zVwFgg;p=bJ0Q@S^aYee z3+7Zw9d-zmQ%Md<9TYC7k}#Lcpw!?v))M-o41X8qUlqFESSbkl41cAz*A|53$`rDN zXHl6TNSaVi;v6+0tKzd_@#OOb{9GcZ!}P@Bs#{_>VJfLaXmVp1=W9Sq6R)*K$m(#9m( zKulvY(NsV}Wpt9sK7T0ZW|zZJEA4{9MruCwuFXovb2WV>w4IN4ecczTDWNZ20A7kUjVEIY9Se0Xv_Mwz1(bc?`M(XnVShwJ69TcvH0P_KT;V1MNvhf4b($pveog@;0x z6|9N*xSZRk*zcEN_C*D+m-E4w8=DfnadurQV5mniNJl30uzMM@+(2MnzR?u*0HUF( zJWW3rr0@c0Ni!*}g@)kGDw=?Nyljzg(d34naRmdp(Kpx1^c?n zufCJDcy1Y9dw-=>c2E)kAU247s8YpDYIqCIEEg?}3x9MqgbTth<^m7E0$l`JFnTnq zbM)l3Jg4)km7oEJj zJFESFACI5@GLnm$>X-uWc$*a~fQt!4k2*2A-Vho8^3Tu5zxnm#pYKI7Q8kT;@Y^G^ zGE>6^{C`Ws1yz!mi;nlKF3kqurfia7X9yt^AQ0=3j5ye(BJh8zIUt?tkqkUt7`Uly zSoq?_)fg4nA0W_XdiK|sXOEcVWaz)lJ-_>_7f+usnaQxzgs7(` zd+fYq_!+_&7@t04Vv~^vi@X9;Q^hia@w{XVvVSg2`N_XeCU^fINygLtF$sCGbT(SY zpPjM$lTihWr~*wVpWL1N<#hbu{qg;KlaIb&w8>C{>2d)rs$nOeGm@DiCMcPVPR2qCffYA535}W@^X1p2>z-;bp^wqQE!f2lrk)djK`_{Db!*@pxky zXQ`0xvrngIU!FfYd-=gT)BoK+fB1az`%}gs8BxL{B}g%fWE{a`r9jtIlbMgeDZI(L zkj?bT-^PDJW${<5K;y5;jkPVg1LIi;2iBz$z8NDlvJUj!~&ihT2XMYtH zwB^}A&I{O(w4ST_(7Eumu*DN-~k!sBS?%B}p`Ci}+!i^rh!{QAFcF&ss<+E0` z75(-ZFu4{uaF Date: Tue, 26 Jul 2022 16:13:29 +0800 Subject: [PATCH 055/155] =?UTF-8?q?=E6=A8=A1=E6=9D=BF=E5=95=8A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../excel/city_management_template.xlsx | Bin 9099 -> 9113 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/epmet-module/gov-org/gov-org-server/src/main/resources/excel/city_management_template.xlsx b/epmet-module/gov-org/gov-org-server/src/main/resources/excel/city_management_template.xlsx index 261a5daa08f5f1cf1fd371af10af37bbd9adf1d8..392a1dbbe0e2d970625c3cd5a58e64c0f324d046 100644 GIT binary patch delta 4095 zcmV9sN0~>klK}e?d#bFcin{g5RO!-lpxej?i|XvXcYBiQ+9J zZ(FfVOA_sN8~6$Q0Ny-`Cl4M3zl=jahH1Oi4h12Xy#N3G@_&zngL#%(w;)xLiwJp+ zi!2Z<=ZTm`=zKi1`^Zw73Qp5pK!g^c&>-I330Xl{F5y(>1xTHMvJ6Qm!iosZf3z+L z#){1#qslQ3VZ=!;Gpfy1PH{omHJt+XT{plPXv(RkxB}WmOGIlVXDzb0k!cO!3_}VT z2(7T^c=*SwL1yaDhFa-3vqUcnGt)Y5m(5utw(hw~T4Pz3PT8wtnEW2T9G#riquPn6 zcEte2A!me1pgNcF*URJT`N5nJV|S|622-l^$Six306$#BtGDIq{qEy+`T2Ao;@`S~ z)-yC@;Fd{6ni)3AMepc%JVdeY`o8T3w$~rKKH1+Ru6tEIztvx*Yzo;r#J|J?+YiQG zK)fFD`W@m15ZAf4e@6Tbvls)i0Sez88Fl zWhh?R{Y#rPF-d6~qXmWHPraV(o@9s4?rdjfv+b==A3+ej_XR{s1)s*!K89z1+wE3c z6a&f3ocYercg~rU;pS1ujU`CML^L9fX%hn?PxvfajL6$J)71@PC`}`uauLCZ9D^d8 zhBG)ROYavdGo7$eU)`~A= zo)k*Vwdsk_Dne_s>|6Z?&(Lcbx+Pg5l?O?@iiTq(H)EXXf8(4k84vRm?n!Gr^ckih ztDPZXJ|bJr;F&{Eo+I`dr0Uw<&~)}1ICvU-tTi#R8qS0`$bh>jvNPK`AhSq4&6cnO zoR7$M2ixE<_kmk@L^69u6G1~$9x@(NS{=)S0a55Y!PS-rE6lF zi9~Z2!3$Ude@BH8>1K{R!O<%I8X?O%lo%mBDxxnex;?YEP7E(mT7;#SJO{OoTk7DN z7CIfr?7DweLc+NtTq~uX>D-~TRx06ID!ChXdcrtzPq$|f79%JJA)p!hnJzZ5SB@ZfjSDM z%dtJQme>hiiP&xWm*9CPF_s|M2

*@LF`}5Cdk1sy`xcvI1 zJY0S|xj3s1=O^EOe*ajg46WM6&}v5h8zw$@ETkOYX$+ETfqgIoodVzh|5tuH$Pd45 ze%Mx5ah5xG+;4vDE0l}Xx)+-?5FGvsmkDygM(mi(;GZyH^=uO-&Rhsx9dOzfchg*$P5Js?e*6oN9=pyErJ1)588D<>wxYng7GCyY@wRSQgRV*c zOr*%4`WJfc3oq}LE-5;dDB1!nisE^H&bfc*@?L85`q98u?%2W5@x7L+Z)mDwdtJZh zc>68&$G5CfLsf=h$Ln=m-?Lllu{~6;Z+-h)o5S$fwQnBScBlXgZ`e`~!tn4~xjgJ1 z*n`e+!#}h=_@?g%gH8w^gZ=XGFt9tlAtD;MWkb_yzV_9Zr{v(Oa^-thu4o&Yc3XK(^6gJc>E9DB zCGvLtI%e|y+lpF_^y8J$XO*GSG1XOt%A%hH&gp!OS-ymJ)=11`?kisE+?N+nqB5(* zjBA;Fk*}}PSV)~$rqSKn?E79EWJ7<0D5Eo5o5Q!1I~^DBrz2-~eb*0^5MTsR#%H|F zz$RCW&wlsf*+YEQK_?gj`UqjgMCUN}=#>M<^8<9UOk^ZW3ikI}s%2R>>N}c-C>Dyt zSG}6B3z?Ns&Ip+Fp8Fi%vz>V3%u9>agC)4+)D@>g-CxTlW}@h z?NBgNaM-~HLqf!*UHSB7YOwP{+1~)CBvI-0B0>H zVIWCgZsw(0R;w;o*aDy|e-ua(xQdZLkcBfWx14Jr_^nb}3QACJ*O!EU+%62EGjUv( zHKb5v$(gOq!%i65foH+j3O#?mb$ke&iU$oc@t?v2Wv;#rkkBvad{HsP<*Xx5BoL)Wl5tCtUR z5@Pe(4%Z0q@m!KEk%&lwiH@-cs@8iTO{DPONv z8&$n&n0ihqxlu*0+-+S;eXGU3&R0Im$acNGyJBBcS?$`cwQ^ZB`#B8P0mBWw)@U@E zW<|#XWDfai?QS=7t8{FP%r{@DuQ?2_MLz3`w2gdYJ#YV7N;)+aZwxP*y9*VBDs)e-p++25=$4- zT+~(>X5;mQtnuV1=IvY{LSp3timWz5(qV1j9fU{|LdbWCCNusPE`K#OKp8?9>627} zSaV{c`HopPwYq;<72HH6{HV{Zhr_-Bw7`ni>CqwF z0i}neT$2x5n;qBL_Xf5H%eHn9I$gBr+l7xdS*bnhC$mMX|CFr(qb|=^=^P%q$3Gek z_UypI`wg%b`0O?wd*aVGA`RkGZv=j5cSF1b0V2dn%z%oiB`o|`1#%}ExTrh1n8Tu4@s+Gx3Qxk#n&OAMSSik75{)=f za{(LWI9GqJb4cVf1&)guU%0^^yRNW357#_ag!lpo3e#QaXm2QOarMF`H0MgAu%%Il zyp3EbR2^_@O1#BhXtfQm&N&jPThR1Io3SHI3N0^`%oIr3a( zq=B)xB>?69Wk@gZU<3yav#38V=FrZ~c`nIdz)dv_Vbo6tZ@wcIf&pz!gaHexMcNn( zg(SWUx7zNBLucgzktcpuq}XajK>^8Z=#9Dr5jDrG(F08 z!MlF|jkIhRyqjCL7j`I0@*)(_f_RZDN1$vm2Xw9+2{Uy7W{MYc$Zb#{N^S0Tf{-t8 zK1D~d8Z9SZ%KYj(S&QeE;f+^Xg;$RHOIVIa?xGz8gjB#<#Gg2exFvEO=N4U9YCrG; z=Pf9$+>U_cJp$M*;0SJag19$0e{|GGE%|_&2|v{PVp? zChD4EBD~{rmL?G{5MK%xR7qkk75s=$W;Wn%%0`5pDRr5|1F;?=;$UxuB>su!fOM*d z2s~JSya*cxUp(=Qy#gBqBy6T*>_J~Oqp$E73B_t9L#Hx#^gQi%*;Qa2dUOaum zWQwqZ{YMg##AJ_yC&JH^VqkpwjENPIXGpJ46w3^T92cM`P5H^cPbPQ&A4$eD*ElZZ z!O~f@jz2qN*Ndn!q=_~8)q@rigz@%iiRp zlk<=Nq{MCzfdk7Kk|0hWe{z2E?&R)cDEgBR|G@-`n5jy2OpF9eKJbeW2`SvE-YiG( zZnroVtji(A=CGV5KFRM=F;qXw83tBb62gnw1PD z=*Bun19NPN&l7EBE<;=5I5wt~4VBFxV$L8K3L}poRhnIi%Cm|J+VX55=OsQM zX+2l

yGB4f3=ED{Ii&haGr$1MfU$y*&Vik8_pd+ z#4K8BeEd3k*o2gS`zU{WeFzU!z`HUEoR<3b?smPovuhcphPK@(nH9TQYF4**N>#JH zy|ZIAHA8Fv0x|~u=GnC)-JJW~vw_nM{Gs0uH@ff)i{I}%U3>nQ&zj|C^xJ2^^$3~Qg>^IrAz6MZB0|XQR006Vk7|8|!0o9Z2 zAtxKA;S+004jOtDpb? delta 4125 zcmV+&5aREdM~g?WlK}-oy7K#Elb8V>f6Ge5FcgOOg6~kWZ_|r&A+#M(nUw>A6~$dh z&de0sv?S5a>;`-SAHbbUapl5=;LAAZW0-a>c2E$q$@%~DxC5~NN+S%xGOVP%A-e_EFW zW5uSBQ{@@@%2gp>hxnJ+v;A)3 zbx5aAf}lm*0OBV1?$3z70kanavH^em-#dp&0{{Tv2mk;W0001ZY%h0ja%*#FWo2}8 zFLP*RWpptvcx`O8R@-jVKoEUL;vcLP;)(i}G--lkL>mf7AR(^L8+#J3y7rpgb=BU(U2a`tx4?3|g|wS!xSDYw=j6%*Nvc(#8_EXX1e zvurgZ&z|mY?GQ_8n#Gih3})mA6uA{%y%Ll{9;gIBTWBFuGm>bXPaQ`^38YlnB8LoD zmO`df<4~>~l}n(pA*I~$U3cW9lx3v0FqN0FA(l%P!CXW|3Yo5rNZ?eX|0-d*YOEc` zm$Da2TB6p*pK~tG>y_4?H|&4;m$FC-C6?NbMC#P8^;J%sNk?ZI^$h(YSSghUMZSfG za}>8=oarMYmxO@{;UnpULCi1=RqiYa%Ne=tP49XH=MCaHgHoOATbeGO0Eb9JjJYOO zmBWP)2Nm!>PPvtB1E?(0NV7HU0p~Nai)i)I?15d}z-f0l-*0x?H(7swB&`^hwBUMA z@E0uB$&5@$Gxu1O_kgVujjoJrEHhDP&N6raYv4$jkx{i#Bsf~de=B8Gg%T^Jhqd>$ zMSpCMw}}-MN{e)}i*d2#_!|zkWz89Q_Q?M|X|N$-+mOb#cL8a*Az`~A`8yZxgnk%F z*fu*2E+maMq;X5~U3-5t@dxg>{>O!WNSr#FCUt;?7qQp3;dc@9K4Q>C-035RUBrGL zvE4=BdHGq(s6{v!o~FL*c*PjC=ae&Ss~g9PM3G?-h8TqIlBIu-a=b4&Q<_+mb5ZVc znjM&!s6>?av%Js`K`FXISmgvx-jPzs&SZP$!l1fJ3r@Z8`pZJ-o2PHypB;ZZ{rKwi z{ihq>-hDYc{;(OGoxJ|`sTrKUKKc6jZA}TB)<)oT-TlAr`_o;|9qw$8M;NEphd


0(1$0ubqF*%HB0^icen{9)?zABi9cn-Jkmd*BO9KQ7006T%2s#FT{QQ;mEeZet*-Zcd z4FCWDcx*3oba`xLb1ryoY}H)bZ`;-xe;=^_fncyb1hYj_)Gf7~#j*($=!OExfC1YO z$P#4}ph%CT0=q+jY-#4LLk0}#maQnTu7#I9EZ)`)YtS|6KNBhPQ~!m1=N$4}s6&ZP zEQ+=sEK&S!zwdH?zH^~At{)Cv<&GVMj_Y=qH~Yv0_r?MML@Uf5Rmqv+sTr4sh`?O``u_YZ6jz8Uzzup7b0 zV6PG$1a`L{BBG&NF*L1S8Fn2{-Q4g-Lu(j?O3xp8QCl^C=_Q4H^JX6|nyNy$b^Jc4 za$EWKPe*?A#@An+kT+MAE8n?tMO)Xj+sYe~Z-2Zt|9iq^jr_ZQ9W(jvZAGml`ti!> zX=P&RnChw$%Zfh z1K(p#HZ<^mGP<(45x%3`>ADbqIs&`ryMCZV5Juo-e8uYyZF0x>^fxb_J;ZnIcY_e3 zj}TT(bPdN|eCN>d`~Y375E|LiwULZyC@!UXGZ*e^2?1ZiBTETd97^J_}OLa&R2 za!%5L)AVAKu8;waW;iO)1wo0jt#LsqfZK%-IuplrX+sKQ7P+#yanOw-JMb*{T8ZD^ zIy!)VPQ`-;8QEJwlnd|P3%W&<4f zWma|Uw&k1IV)BdiCan}ZTdhtpF6FRZk*$`0)mgT!F|Idi=v54^brwTah~Y-9)~x9* z!_*5))wl{4U6GO)HY|7*h4pf)Ut*HgX>@jqGHFHbi+fBuh_0vv*5J5W=ID7l(f8-ya=EjdA ze+X~-PIu4ux-Pt}BoxX2Ih3$t1)EcCweOF1T^pp4w;vAY2G9m8+NVcvVFfgPOUgC*u({E7ojq@8d$4V52a(f5 zo4!5xXp^1V!$CG%v?m?2HDHsR=c{xN4&0;fkA}N;VBzxySPOi03y(eQ^NmCUcIoZF zkL+HAPe7nO>DN#a?cT>q!jedTId$ZKtimaVaw-W6M-)i|<}yr6Xiw(2yD<0af>IFk zbCg6ty6!*r#Ig`9v)8w#bOOOu1+g7oWxoQF$e9#9Hk14IZ#EaBIui2#jRD%`Ktn| z^HnZZ$*gKKUq{jN1!!!4qLOpzrZilgELRU?qW0|4!O1nc=g6nRV-<8uu;tpKOQJCs zvU+*jO|EgjB)D?(A=EyVvyDfQn=~f^uAu$AK~`9jTW$lz#ivo)9-eo0xe7n>a9sB} zBul$weMy==6Ls~MZa78tJxO;V+so7Sb1_;4ZOd6Tvs!3SeqPakEO5fkIU1BLCyKnQ z%c>(cc^47}t{3d-3cveK_Tss1c;l6J;g!R|1#HKo5hm^-z@@xxw765`fogkh~ps*?E0nD~Ke)@F!_&t@HuI!E+7tZGrAmDsR znxL+IOIcIKUw$!v{pY>OACAXQ9-V#i(e&4!DbVT@`@kZONe!REN^>!?xIlUmE(klO z3QT_`x=6I3^r%{L^yKl$ zFP=W3GR3fegBgj0Bs1BW^ThBor7u$lbpcyjlD ziDbMp&q&CFrRiuLe|}2u7o!SJ?8roXdUx{YlktP!kMG}`eEcP)6+;Pjza+G%h8=%F zNm4~jTJ|O%AD?~lM}@&41`h0H$>co#^z8Wk$=%0)Q1mAs{hbOFW2Pq6F*5*Y^5K(A z3|8_>7-?8zy=ji%`7a|PkJP1!rnpM}Nc#!ZSd1O1Lo&-em5mp)nQT~3lwdY~aPP&l z2T(K5KKvjNk585{LOI>%pG{A{I(u~b^27J0|Gj_q@cHDoCzOF0QPLzONKpzgj^M10 zMAuAzlc|ruDMF!^vY9^l>-cx?i!oA7#g{ZFGb<|{qF`j;<(u+s{rBG>OsVB!dD5jM znb8UINKJ?FmzP|VvXN9)THl}z;2D@w=rTP(^#GH3HZ>`bGXaAp=iC4*Ezx|Wa=C(b z9XL{HVTiMmh6!3)=V;(`#(AQRLWYjSacoR~DVta}4G{pACxT6GiEN3Z7{aL-lV(?@ zqi971ZFxN)=OucOw4SN@(7EumaP9_Z*>ne5`=|>KZ{U;1w6}-A=-Y$t$c=8%FWV}6 z|2_O52KXqx>uu+bA7K`4mA!upJ#0eCzkL|J6~c29@Lw4PPFwxi&Q_zfy<-_`O>L`Q zxn@@F+FGl&wY^p|J6qe^R!cLq&byE?=r_-<9qQ)H@16~vUf_rRAX@LiGc5jK;PmX- zUp{M9TFGyp0h4Q?3wH&vv9a>`(%@}AXEVulL;X}2X6!b0C;RKlK~?f zlWZXl0g97*AvOZB9FyA|9Fxx>DgwtClkpf9lf)tr8~ps0^(_hj0NG6d01W^D00000 z0096X0001QlRP3i0X&m;A~peIldd8_0`wV^@FF__kdrJUAshVPJBLaG007_!000;O b0000000031AOHXWypw1nD+X>K00000dH%`# From c9bd4bf5c2677771ea14f85df758de6e6c3dbe97 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Tue, 26 Jul 2022 17:27:59 +0800 Subject: [PATCH 056/155] temp --- .../dto/result/ZhzlCategorySelectDTO.java | 23 ++++ .../tools/enums/ZhzlResiCategoryEnum.java | 108 ++++++++++++++++++ 2 files changed, 131 insertions(+) create mode 100644 epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/dto/result/ZhzlCategorySelectDTO.java create mode 100644 epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/ZhzlResiCategoryEnum.java diff --git a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/dto/result/ZhzlCategorySelectDTO.java b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/dto/result/ZhzlCategorySelectDTO.java new file mode 100644 index 0000000000..94b58de257 --- /dev/null +++ b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/dto/result/ZhzlCategorySelectDTO.java @@ -0,0 +1,23 @@ +package com.epmet.commons.tools.dto.result; + +import lombok.Data; + +import java.io.Serializable; + +/** + * @Description + * @Author yzm + * @Date 2022/7/26 16:37 + */ +@Data +public class ZhzlCategorySelectDTO implements Serializable { + private String label; + private String value; + + private String queryType; + private String tableName; + private String columnName; + private String columnValue; + private Integer sort; +} + diff --git a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/ZhzlResiCategoryEnum.java b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/ZhzlResiCategoryEnum.java new file mode 100644 index 0000000000..b57baedf5e --- /dev/null +++ b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/ZhzlResiCategoryEnum.java @@ -0,0 +1,108 @@ +package com.epmet.commons.tools.enums; + +import com.epmet.commons.tools.dto.result.ZhzlCategorySelectDTO; + +import java.util.ArrayList; +import java.util.List; + +public enum ZhzlResiCategoryEnum { + // resi_xfry 信访人员 + // anzhibangjiao 安置帮教 + // xiejiaorenyuan 邪教人员 + // buliangqingshaonian 不良青少年 + // shequjiaozheng 社区矫正 + // zhaoshizhaohuojingshenbing 肇事肇祸精神病 + // xidurenyuan 吸毒人员 + + resi_xfry("resi_xfry", "信访人员", "equal", "ic_resi_user", "IS_XFRY", "1", 1), + anzhibangjiao("anzhibangjiao", "安置帮教", "list_equal", "ic_special", "SPECIAL_RQLB", "anzhibangjiao", 2), + xiejiaorenyuan("xiejiaorenyuan", "邪教人员", "list_equal", "ic_special", "SPECIAL_RQLB", "xiejiaorenyuan", 3), + buliangqingshaonian("buliangqingshaonian", "不良青少年", "list_equal", "ic_special", "SPECIAL_RQLB", "buliangqingshaonian", 4), + shequjiaozheng("shequjiaozheng", "社区矫正", "list_equal", "ic_special", "SPECIAL_RQLB", "shequjiaozheng", 5), + zhaoshizhaohuojingshenbing("zhaoshizhaohuojingshenbing", "肇事肇祸精神病", "list_equal", "ic_special", "SPECIAL_RQLB", "zhaoshizhaohuojingshenbing", 6), + xidurenyuan("xidurenyuan", "吸毒人员", "list_equal", "ic_special", "SPECIAL_RQLB", "xidurenyuan", 7); + + private String code; + private String name; + private String queryType; + private String tableName; + private String columnName; + private String columnValue; + private Integer sort; + + + ZhzlResiCategoryEnum(String code, String name, String queryType, String tableName, String columnName, String columnValue, Integer sort) { + this.code = code; + this.name = name; + this.queryType = queryType; + this.tableName = tableName; + this.columnName = columnName; + this.columnValue = columnValue; + this.sort = sort; + } + + public static ZhzlResiCategoryEnum getEnum(String code) { + ZhzlResiCategoryEnum[] values = ZhzlResiCategoryEnum.values(); + for (ZhzlResiCategoryEnum value : values) { + if (value.getCode().equals(code)) { + return value; + } + } + return null; + + } + + + /** + * 转为数据 + * + * @return 枚举对象数组 + */ + public static List toSelectList() { + List list = new ArrayList<>(); + for (ZhzlResiCategoryEnum item : ZhzlResiCategoryEnum.values()) { + ZhzlCategorySelectDTO selectDTO = new ZhzlCategorySelectDTO(); + selectDTO.setLabel(item.getName()); + selectDTO.setValue(item.getCode()); + selectDTO.setQueryType(item.getQueryType()); + selectDTO.setTableName(item.getTableName()); + selectDTO.setColumnName(item.getColumnName()); + selectDTO.setColumnValue(item.getColumnValue()); + selectDTO.setSort(item.getSort()); + list.add(selectDTO); + } + return list; + } + + + public String getCode() { + return code; + } + + public String getName() { + return name; + } + + + public String getQueryType() { + return queryType; + } + + public String getTableName() { + return tableName; + } + + public String getColumnName() { + return columnName; + } + + public String getColumnValue() { + return columnValue; + } + + public Integer getSort() { + return sort; + } + + +} From c9aa7ab54c58fbb45771524ca950e3c0a2d5c3e1 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Tue, 26 Jul 2022 17:28:42 +0800 Subject: [PATCH 057/155] temp --- .../dataaggre/controller/CoverageController.java | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java index 27563e2134..9427a51575 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java @@ -1,13 +1,15 @@ package com.epmet.dataaggre.controller; +import com.epmet.commons.tools.dto.result.ZhzlCategorySelectDTO; +import com.epmet.commons.tools.enums.ZhzlResiCategoryEnum; import com.epmet.commons.tools.page.PageData; import com.epmet.commons.tools.utils.Result; import com.epmet.dataaggre.dto.govorg.form.CoverageAnalisisDataListFormDTO; import com.epmet.dataaggre.dto.govorg.result.CoverageAnalisisDataListResultDTO; import com.epmet.dataaggre.service.CoverageService; -import com.github.pagehelper.PageInfo; import org.apache.commons.collections4.CollectionUtils; import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; @@ -43,4 +45,13 @@ public class CoverageController { return new Result>().ok(page); } + /** + * 综合治理图层页面,居民类别下拉框 + * @return + */ + @PostMapping("zhzl-category-option") + public Result> queryZhzlCategorySelectOptions() { + List list = ZhzlResiCategoryEnum.toSelectList(); + return new Result>().ok(list); + } } From 7433f807bff319884337f79d0f7a406b14107271 Mon Sep 17 00:00:00 2001 From: sunyuchao Date: Tue, 26 Jul 2022 17:31:27 +0800 Subject: [PATCH 058/155] =?UTF-8?q?=E8=81=94=E5=BB=BA=E5=8D=95=E4=BD=8D?= =?UTF-8?q?=E3=80=81=E7=A4=BE=E4=BC=9A=E8=87=AA=E7=BB=84=E7=BB=87=E6=A0=A1?= =?UTF-8?q?=E9=AA=8C=E5=B7=A5=E4=BD=9C=E4=BA=BA=E5=91=98=E4=BF=A1=E6=81=AF?= =?UTF-8?q?=E4=BD=BF=E7=94=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../epmet/dto/form/CheckStaffInfoFormDTO.java | 49 +++++++++++++ .../dto/result/CheckStaffInfoResultDTO.java | 50 ++++++++++++++ .../controller/DepartmentController.java | 13 ++++ .../com/epmet/service/DepartmentService.java | 7 +- .../service/impl/DepartmentServiceImpl.java | 69 +++++++++++++++++++ .../epmet/feign/EpmetUserOpenFeignClient.java | 4 ++ .../EpmetUserOpenFeignClientFallback.java | 5 ++ .../controller/CustomerStaffController.java | 5 ++ .../epmet/service/CustomerStaffService.java | 2 + .../impl/CustomerStaffServiceImpl.java | 6 +- 10 files changed, 205 insertions(+), 5 deletions(-) create mode 100644 epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/CheckStaffInfoFormDTO.java create mode 100644 epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/CheckStaffInfoResultDTO.java diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/CheckStaffInfoFormDTO.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/CheckStaffInfoFormDTO.java new file mode 100644 index 0000000000..42e299ae44 --- /dev/null +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/CheckStaffInfoFormDTO.java @@ -0,0 +1,49 @@ +/** + * Copyright 2018 人人开源 https://www.renren.io + *

+ * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + *

+ * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + *

+ * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +package com.epmet.dto.form; + +import com.epmet.commons.tools.validator.group.CustomerClientShowGroup; +import lombok.Data; + +import javax.validation.constraints.NotBlank; +import java.io.Serializable; + + +@Data +public class CheckStaffInfoFormDTO implements Serializable { + + private static final long serialVersionUID = 1L; + public interface Check extends CustomerClientShowGroup {} + + /** + * 手机号 + */ + @NotBlank(message = "手机号不能为空", groups = Check.class) + private String mobile; + /** + * 人名姓名 + */ + @NotBlank(message = "姓名不能为空", groups = Check.class) + private String personName; + + + private String customerId; + private String staffId; + + +} \ No newline at end of file diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/CheckStaffInfoResultDTO.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/CheckStaffInfoResultDTO.java new file mode 100644 index 0000000000..0f500a0cab --- /dev/null +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/CheckStaffInfoResultDTO.java @@ -0,0 +1,50 @@ +/** + * Copyright 2018 人人开源 https://www.renren.io + *

+ * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + *

+ * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + *

+ * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +package com.epmet.dto.result; + +import lombok.Data; + +import java.io.Serializable; + + +@Data +public class CheckStaffInfoResultDTO implements Serializable { + + private static final long serialVersionUID = 1L; + + /** + * 状态,false为有问题 + */ + private Boolean type = false; + + /** + * 提示文案内容 + */ + private String msg = ""; + + /** + * 数据库中工作人员姓名【返参姓名有值的则需要更新工作人员信息】 + */ + private String personName; + + /** + * 类型,后端使用 + */ + private Boolean key = true; + +} \ No newline at end of file diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/DepartmentController.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/DepartmentController.java index 79b1975b9a..fac881ed3e 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/DepartmentController.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/DepartmentController.java @@ -161,4 +161,17 @@ public class DepartmentController { List deptList = departmentService.listDepartmentListByStaffId(staffId); return new Result>().ok(deptList); } + + + /** + * @Author sun + * @Description 根据手机号姓名查询人员信息,联建单位、社会自组织新增使用 + */ + @PostMapping("checkstaffinfo") + public Result checkStaffInfo(@LoginUser TokenDto tokenDTO, @RequestBody CheckStaffInfoFormDTO formDTO) { + ValidatorUtils.validateEntity(formDTO, CheckStaffInfoFormDTO.Check.class); + formDTO.setCustomerId(tokenDTO.getCustomerId()); + formDTO.setStaffId(tokenDTO.getUserId()); + return new Result().ok(departmentService.checkStaffInfo(formDTO)); + } } diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/DepartmentService.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/DepartmentService.java index c97f61e6a1..d1f589b26e 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/DepartmentService.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/DepartmentService.java @@ -20,10 +20,7 @@ package com.epmet.service; import com.epmet.commons.tools.security.dto.TokenDto; import com.epmet.commons.tools.utils.Result; import com.epmet.dto.form.*; -import com.epmet.dto.result.AddDepartmentResultDTO; -import com.epmet.dto.result.DepartmentDetailResultDTO; -import com.epmet.dto.result.DepartmentInAgencyResultDTO; -import com.epmet.dto.result.DepartmentListResultDTO; +import com.epmet.dto.result.*; import java.util.List; @@ -104,4 +101,6 @@ public interface DepartmentService { * @return */ List listDepartmentListByStaffId(String staffId); + + CheckStaffInfoResultDTO checkStaffInfo(CheckStaffInfoFormDTO formDTO); } diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java index 0c109e270a..aa8d6c1db8 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java @@ -19,7 +19,9 @@ package com.epmet.service.impl; import com.epmet.commons.tools.constant.NumConstant; import com.epmet.commons.tools.constant.StrConstant; +import com.epmet.commons.tools.dto.result.CustomerStaffInfoCacheResult; import com.epmet.commons.tools.exception.EpmetErrorCode; +import com.epmet.commons.tools.exception.EpmetException; import com.epmet.commons.tools.exception.RenException; import com.epmet.commons.tools.redis.common.CustomerStaffRedis; import com.epmet.commons.tools.security.dto.TokenDto; @@ -30,8 +32,10 @@ import com.epmet.constant.CustomerDepartmentConstant; import com.epmet.dao.CustomerAgencyDao; import com.epmet.dao.CustomerDepartmentDao; import com.epmet.dao.CustomerStaffDepartmentDao; +import com.epmet.dao.StaffOrgRelationDao; import com.epmet.dto.CustomerDepartmentDTO; import com.epmet.dto.CustomerIdDTO; +import com.epmet.dto.CustomerStaffDTO; import com.epmet.dto.CustomerStaffDepartmentDTO; import com.epmet.dto.form.*; import com.epmet.dto.result.*; @@ -39,6 +43,7 @@ import com.epmet.entity.CustomerAgencyEntity; import com.epmet.entity.CustomerDepartmentEntity; import com.epmet.entity.CustomerStaffDepartmentEntity; import com.epmet.feign.EpmetUserFeignClient; +import com.epmet.feign.EpmetUserOpenFeignClient; import com.epmet.service.CustomerDepartmentService; import com.epmet.service.CustomerStaffDepartmentService; import com.epmet.service.DepartmentService; @@ -49,6 +54,7 @@ import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; +import org.springframework.util.CollectionUtils; import java.util.ArrayList; import java.util.List; @@ -76,6 +82,10 @@ public class DepartmentServiceImpl implements DepartmentService { private EpmetUserFeignClient epmetUserFeignClient; @Autowired private LoginUserUtil loginUserUtil; + @Autowired + private EpmetUserOpenFeignClient epmetUserOpenFeignClient; + @Autowired + private StaffOrgRelationDao staffOrgRelationDao; /** * @param formDTO * @return @@ -280,4 +290,63 @@ public class DepartmentServiceImpl implements DepartmentService { public List listDepartmentListByStaffId(String staffId) { return customerDepartmentDao.listDepartmentListByStaffId(staffId); } + + @Override + public CheckStaffInfoResultDTO checkStaffInfo(CheckStaffInfoFormDTO formDTO) { + CheckStaffInfoResultDTO resultDTO = new CheckStaffInfoResultDTO(); + //1.根据手机号查询客户下工作人员信息 + CustomerStaffFormDTO user = new CustomerStaffFormDTO(); + user.setCustomerId(formDTO.getCustomerId()); + user.setMobile(formDTO.getMobile()); + Result userResult = epmetUserOpenFeignClient.staffDetailInfo(user); + if (!userResult.success()) { + throw new EpmetException(EpmetErrorCode.EPMET_COMMON_OPERATION_FAIL.getCode(), "获取工作人员信息失败", "获取工作人员信息失败"); + } + //查不到工作人员就直接返回 + if (null == userResult.getData()) { + return resultDTO; + } + + //2.查询工作人员注册组织关系数据 + List staffIdList = new ArrayList<>(); + staffIdList.add(userResult.getData().getUserId()); + List list = staffOrgRelationDao.selelctStaffOrg(staffIdList); + if (CollectionUtils.isEmpty(list)) { + return resultDTO; + } + + //3.校验工作人员的注册关系【从哪里新增进来的工作人员】 + //获取当前操作人员缓存信息 + CustomerStaffInfoCacheResult staffInfo = CustomerStaffRedis.getStaffInfo(formDTO.getCustomerId(), formDTO.getStaffId()); + if (null == staffInfo) { + throw new EpmetException(String.format("查询工作人员%s缓存信息失败...", formDTO.getStaffId())); + } + //所属组织信息不同的给提示【所属组织不同时则不新增部门、不新增工作人员】 + if (!list.get(0).getAgencyId().equals(staffInfo.getAgencyId())) { + resultDTO.setMsg("联系电话已存在其他组织工作账号中,请使用其他手机号,否则将无法获取通知信息"); + resultDTO.setKey(false); + return resultDTO; + } + //从网格下添加的人给提示【网格下加的人时则不新增部门、不新增工作人员】 + if ("gridId".equals(list.get(0).getOrgType())) { + resultDTO.setMsg("联系电话已存在其他部门工作账号中,请先将该工作人员调动至本组织下,再次添加"); + resultDTO.setKey(false); + return resultDTO; + } + //账号被禁用的给提示【人员被禁用的则不新增部门、不新增工作人员】 + if ("disabled".equals(userResult.getData().getEnableFlag())) { + resultDTO.setMsg("该工作人员账号已被禁用,请使用其他联系电话,否则将无法获取通知信息"); + resultDTO.setKey(false); + return resultDTO; + } + //姓名不一样的给反馈 + if (!formDTO.getPersonName().equals(userResult.getData().getRealName())) { + resultDTO.setPersonName(userResult.getData().getRealName()); + } + + resultDTO.setType(true); + return resultDTO; + } + + } \ No newline at end of file diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java index 2dffd84aee..5cd018c37c 100644 --- a/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java @@ -855,4 +855,8 @@ public interface EpmetUserOpenFeignClient { */ @PostMapping("/epmetuser/staffrole/getIsRootManager") Result getIsRootManager(@RequestParam("userId") String userId); + + @PostMapping("/epmetuser/customerstaff/staffdetailinfo") + Result staffDetailInfo(@RequestBody CustomerStaffFormDTO formDTO); + } diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/fallback/EpmetUserOpenFeignClientFallback.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/fallback/EpmetUserOpenFeignClientFallback.java index bee7102a73..6491dc477d 100644 --- a/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/fallback/EpmetUserOpenFeignClientFallback.java +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/fallback/EpmetUserOpenFeignClientFallback.java @@ -646,4 +646,9 @@ public class EpmetUserOpenFeignClientFallback implements EpmetUserOpenFeignClien return ModuleUtils.feignConError(ServiceConstant.EPMET_USER_SERVER, "getIsRootManager", userId); } + @Override + public Result staffDetailInfo(CustomerStaffFormDTO formDTO) { + return ModuleUtils.feignConError(ServiceConstant.EPMET_USER_SERVER, "staffDetailInfo", formDTO); + } + } diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java index 274cb8ed87..f3a5d6bd99 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java @@ -493,5 +493,10 @@ public class CustomerStaffController { return new Result>().ok(customerStaffService.gridMobileList(formDTO.getGridId(), tokenDto.getUserId())); } + @PostMapping(value = "staffdetailinfo") + public Result staffDetailInfo(@RequestBody CustomerStaffFormDTO formDTO) { + return new Result().ok(customerStaffService.staffDetailInfo(formDTO)); + } + } diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/CustomerStaffService.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/CustomerStaffService.java index e986aa8f07..16d6e83189 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/CustomerStaffService.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/CustomerStaffService.java @@ -347,4 +347,6 @@ public interface CustomerStaffService extends BaseService { * @Description 【事件】网格员服务电话 **/ List gridMobileList(String gridId, String userId); + + CustomerStaffDTO staffDetailInfo(CustomerStaffFormDTO formDTO); } diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java index c9c416d63c..1caf9abf5a 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java @@ -45,7 +45,6 @@ import com.epmet.dao.StaffRoleDao; import com.epmet.dto.*; import com.epmet.dto.form.*; import com.epmet.dto.result.*; -import com.epmet.dto.result.NewUserRoleResultDTO; import com.epmet.entity.CustomerStaffEntity; import com.epmet.entity.GovStaffRoleEntity; import com.epmet.entity.StaffRoleEntity; @@ -870,4 +869,9 @@ public class CustomerStaffServiceImpl extends BaseServiceImpl Date: Wed, 27 Jul 2022 09:08:47 +0800 Subject: [PATCH 059/155] =?UTF-8?q?=E6=9A=82=E6=8F=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../form/CoverageHomeSearchFormDTO.java | 20 ++++++ .../result/CoverageHomeSearchResultDTO.java | 32 +++++++++ .../dto/govorg/result/EventInfoResultDTO.java | 46 +++++++++++++ .../govorg/result/ResourceInfoResultDTO.java | 31 +++++++++ .../dto/govorg/result/UserInfoResultDTO.java | 69 +++++++++++++++++++ .../controller/CoverageController.java | 18 +++++ .../dataaggre/service/CoverageService.java | 11 +++ .../service/impl/CoverageServiceImpl.java | 13 ++++ 8 files changed, 240 insertions(+) create mode 100644 epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageHomeSearchFormDTO.java create mode 100644 epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/CoverageHomeSearchResultDTO.java create mode 100644 epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/EventInfoResultDTO.java create mode 100644 epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/ResourceInfoResultDTO.java create mode 100644 epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/UserInfoResultDTO.java diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageHomeSearchFormDTO.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageHomeSearchFormDTO.java new file mode 100644 index 0000000000..61ff9e4c07 --- /dev/null +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageHomeSearchFormDTO.java @@ -0,0 +1,20 @@ +package com.epmet.dataaggre.dto.govorg.form; + +import lombok.Data; + +import java.io.Serializable; + +/** + * @Author zxc + * @DateTime 2022/7/26 16:25 + * @DESC + */ +@Data +public class CoverageHomeSearchFormDTO implements Serializable { + + private static final long serialVersionUID = 3776954636762201010L; + + private String name; + private String customerId; + private String userId; +} diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/CoverageHomeSearchResultDTO.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/CoverageHomeSearchResultDTO.java new file mode 100644 index 0000000000..59d65d5741 --- /dev/null +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/CoverageHomeSearchResultDTO.java @@ -0,0 +1,32 @@ +package com.epmet.dataaggre.dto.govorg.result; + +import lombok.Data; + +import java.io.Serializable; +import java.util.List; + +/** + * @Author zxc + * @DateTime 2022/7/26 16:25 + * @DESC + */ +@Data +public class CoverageHomeSearchResultDTO implements Serializable { + + private static final long serialVersionUID = 8922820109004386708L; + + /** + * 居民信息 + */ + private List userInfos; + + /** + * 事件信息 + */ + private List eventInfos; + + /** + * 资源信息 + */ + private List resourceInfos; +} diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/EventInfoResultDTO.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/EventInfoResultDTO.java new file mode 100644 index 0000000000..18c6221410 --- /dev/null +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/EventInfoResultDTO.java @@ -0,0 +1,46 @@ +package com.epmet.dataaggre.dto.govorg.result; + +import lombok.Data; + +import java.io.Serializable; + +/** + * @Author zxc + * @DateTime 2022/7/26 16:52 + * @DESC 事件本组织及下级难点堵点: 社区治理-事件管理中标记的痛点堵点 + */ +@Data +public class EventInfoResultDTO implements Serializable { + + private static final long serialVersionUID = 1645410018462094960L; + + /** + * 事件ID + */ + private String eventId; + + /** + * 所属网格 + */ + private String gridName; + + /** + * 发生时间 yyyy-dd-mm hh:ii:ss + */ + private String happenTime; + + /** + * 事件内容 + */ + private String eventContent; + + /** + * 经度 + */ + private String longitude; + + /** + * 纬度 + */ + private String latitude; +} diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/ResourceInfoResultDTO.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/ResourceInfoResultDTO.java new file mode 100644 index 0000000000..772d6fd69f --- /dev/null +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/ResourceInfoResultDTO.java @@ -0,0 +1,31 @@ +package com.epmet.dataaggre.dto.govorg.result; + +import lombok.Data; + +import java.io.Serializable; + +/** + * @Author zxc + * @DateTime 2022/7/26 16:52 + * @DESC + */ +@Data +public class ResourceInfoResultDTO implements Serializable { + + private static final long serialVersionUID = 1645410018462094960L; + + private String resourceId; + private String resourceType; + + private String name; + + /** + * 经度 + */ + private String longitude; + + /** + * 纬度 + */ + private String latitude; +} diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/UserInfoResultDTO.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/UserInfoResultDTO.java new file mode 100644 index 0000000000..971606c625 --- /dev/null +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/UserInfoResultDTO.java @@ -0,0 +1,69 @@ +package com.epmet.dataaggre.dto.govorg.result; + +import lombok.Data; + +import java.io.Serializable; +import java.util.List; + +/** + * @Author zxc + * @DateTime 2022/7/26 16:52 + * @DESC + */ +@Data +public class UserInfoResultDTO implements Serializable { + + private static final long serialVersionUID = 1645410018462094960L; + + private String icUserId; + + /** + * 名字 + */ + private String name; + + /** + * 所属网格 + */ + private String gridName; + + /** + * 所属房屋 + */ + private String houseName; + + /** + * 手机号 + */ + private String mobile; + + /** + * 身份证 + */ + private String idCard; + + /** + * 工作单位 + */ + private String gzdw; + + /** + * 人户情况 + */ + private String rhqk; + + /** + * 人员分类 + */ + private List type; + + /** + * 经度 + */ + private String longitude; + + /** + * 纬度 + */ + private String latitude; +} diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java index 9427a51575..8ce19a7b9e 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java @@ -1,11 +1,15 @@ package com.epmet.dataaggre.controller; +import com.epmet.commons.tools.annotation.LoginUser; import com.epmet.commons.tools.dto.result.ZhzlCategorySelectDTO; import com.epmet.commons.tools.enums.ZhzlResiCategoryEnum; import com.epmet.commons.tools.page.PageData; +import com.epmet.commons.tools.security.dto.TokenDto; import com.epmet.commons.tools.utils.Result; import com.epmet.dataaggre.dto.govorg.form.CoverageAnalisisDataListFormDTO; +import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; import com.epmet.dataaggre.dto.govorg.result.CoverageAnalisisDataListResultDTO; +import com.epmet.dataaggre.dto.govorg.result.CoverageHomeSearchResultDTO; import com.epmet.dataaggre.service.CoverageService; import org.apache.commons.collections4.CollectionUtils; import org.springframework.beans.factory.annotation.Autowired; @@ -54,4 +58,18 @@ public class CoverageController { List list = ZhzlResiCategoryEnum.toSelectList(); return new Result>().ok(list); } + /** + * Desc: 五大图层首页搜索 + * @param formDTO + * @param tokenDto + * @author zxc + * @date 2022/7/26 16:29 + */ + @PostMapping("search") + public Result coverageHomeSearch(@RequestBody CoverageHomeSearchFormDTO formDTO, @LoginUser TokenDto tokenDto){ + formDTO.setCustomerId(tokenDto.getCustomerId()); + formDTO.setUserId(tokenDto.getUserId()); + return new Result().ok(coverageService.coverageHomeSearch(formDTO)); + } + } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java index 8734dcabd2..5674c60c2e 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java @@ -1,7 +1,9 @@ package com.epmet.dataaggre.service; import com.epmet.commons.tools.page.PageData; +import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; import com.epmet.dataaggre.dto.govorg.result.CoverageAnalisisDataListResultDTO; +import com.epmet.dataaggre.dto.govorg.result.CoverageHomeSearchResultDTO; import java.util.List; @@ -20,4 +22,13 @@ public interface CoverageService { */ PageData analysisDataList(List coverageTypes, List categoryKeys, String search, Integer pageNo, Integer pageSize, Boolean isPage); + + /** + * Desc: 五大图层首页搜索 + * @param formDTO + * @author zxc + * @date 2022/7/26 16:29 + */ + CoverageHomeSearchResultDTO coverageHomeSearch(CoverageHomeSearchFormDTO formDTO); + } \ No newline at end of file diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index b5f8a0ec3a..2a73095105 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -8,7 +8,9 @@ import com.epmet.commons.tools.redis.common.CustomerStaffRedis; import com.epmet.commons.tools.redis.common.bean.BuildingInfoCache; import com.epmet.commons.tools.utils.EpmetRequestHolder; import com.epmet.dataaggre.dto.epmetuser.result.IcResiInfoResultDTO; +import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; import com.epmet.dataaggre.dto.govorg.result.CoverageAnalisisDataListResultDTO; +import com.epmet.dataaggre.dto.govorg.result.CoverageHomeSearchResultDTO; import com.epmet.dataaggre.dto.govorg.result.IcEnterisePatrolResultDTO; import com.epmet.dataaggre.entity.epmetuser.IcResiUserEntity; import com.epmet.dataaggre.entity.govorg.*; @@ -195,6 +197,17 @@ public class CoverageServiceImpl implements CoverageService { } } + /** + * Desc: 五大图层首页搜索 + * @param formDTO + * @author zxc + * @date 2022/7/26 16:29 + */ + @Override + public CoverageHomeSearchResultDTO coverageHomeSearch(CoverageHomeSearchFormDTO formDTO) { + return null; + } + /** * 从staff信息中获取工作人员的PIDS * @param staffInfo From c8156fe4c0692e72859170fe13fa27721ee3b6c9 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Wed, 27 Jul 2022 09:59:09 +0800 Subject: [PATCH 060/155] =?UTF-8?q?=E7=BB=BC=E5=90=88=E6=B2=BB=E7=90=86?= =?UTF-8?q?=E5=9B=BE=E5=B1=82=E6=9F=A5=E8=AF=A21?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../epmet/dto/form/CustomerFormQueryDTO.java | 6 + .../epmet/controller/IcFormController.java | 2 +- .../java/com/epmet/dao/IcFormItemDao.java | 2 +- .../com/epmet/service/IcFormItemService.java | 2 +- .../service/impl/IcFormItemServiceImpl.java | 4 +- .../db/migration/V0.0.34__formitem_zhzl.sql | 1 + .../main/resources/mapper/IcFormItemDao.xml | 10 +- .../epmet/dto/form/IcResiUserPageFormDTO.java | 6 +- .../controller/IcResiUserController.java | 23 +++ .../com/epmet/service/IcResiUserService.java | 6 + .../service/impl/IcResiUserServiceImpl.java | 181 +++++++++++++++++- 11 files changed, 233 insertions(+), 10 deletions(-) create mode 100644 epmet-module/oper-customize/oper-customize-server/src/main/resources/db/migration/V0.0.34__formitem_zhzl.sql diff --git a/epmet-module/oper-customize/oper-customize-client/src/main/java/com/epmet/dto/form/CustomerFormQueryDTO.java b/epmet-module/oper-customize/oper-customize-client/src/main/java/com/epmet/dto/form/CustomerFormQueryDTO.java index 1978e3660d..5f3d79cd47 100644 --- a/epmet-module/oper-customize/oper-customize-client/src/main/java/com/epmet/dto/form/CustomerFormQueryDTO.java +++ b/epmet-module/oper-customize/oper-customize-client/src/main/java/com/epmet/dto/form/CustomerFormQueryDTO.java @@ -30,5 +30,11 @@ public class CustomerFormQueryDTO implements Serializable { * 是否动态 */ private Boolean dynamic; + + /** + * 居民信息列表:resi + * 综合治理图层:zhzl + */ + private String listType; } diff --git a/epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/controller/IcFormController.java b/epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/controller/IcFormController.java index ef443587d2..dcb08f35e7 100644 --- a/epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/controller/IcFormController.java +++ b/epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/controller/IcFormController.java @@ -140,7 +140,7 @@ public class IcFormController { @PostMapping(value = "queryConditions") Result> queryConditions(@RequestBody CustomerFormQueryDTO formQueryDTO) { ValidatorUtils.validateEntity(formQueryDTO,CustomerFormQueryDTO.AddUserInternalGroup.class); - return new Result>().ok(icFormItemService.queryConditions(formQueryDTO.getCustomerId(),formQueryDTO.getFormCode())); + return new Result>().ok(icFormItemService.queryConditions(formQueryDTO.getCustomerId(),formQueryDTO.getFormCode(),formQueryDTO.getListType())); } /** diff --git a/epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/dao/IcFormItemDao.java b/epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/dao/IcFormItemDao.java index 9737ddb90f..df9da799b0 100644 --- a/epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/dao/IcFormItemDao.java +++ b/epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/dao/IcFormItemDao.java @@ -59,7 +59,7 @@ public interface IcFormItemDao extends BaseDao { * @author yinzuomei * @date 2021/11/1 12:58 下午 */ - List queryConditions(@Param("customerId") String customerId, @Param("formCode") String formCode); + List queryConditions(@Param("customerId") String customerId, @Param("formCode") String formCode,@Param("listType") String listType); /** * 构造出所有子表关联语句 diff --git a/epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/service/IcFormItemService.java b/epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/service/IcFormItemService.java index 435e703e33..92058db5c3 100644 --- a/epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/service/IcFormItemService.java +++ b/epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/service/IcFormItemService.java @@ -47,7 +47,7 @@ public interface IcFormItemService extends BaseService { List queryTableHeaderList(CustomerFormQueryDTO formDto); - List queryConditions(String customerId,String formCode); + List queryConditions(String customerId,String formCode,String listType); List querySubTables(String customerId, String formCode); diff --git a/epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/service/impl/IcFormItemServiceImpl.java b/epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/service/impl/IcFormItemServiceImpl.java index c3b2e35991..74cb44a6b4 100644 --- a/epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/service/impl/IcFormItemServiceImpl.java +++ b/epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/service/impl/IcFormItemServiceImpl.java @@ -137,8 +137,8 @@ public class IcFormItemServiceImpl extends BaseServiceImpl queryConditions(String customerId,String formCode) { - return baseDao.queryConditions(customerId,formCode); + public List queryConditions(String customerId,String formCode,String listType) { + return baseDao.queryConditions(customerId,formCode,listType); } @Override diff --git a/epmet-module/oper-customize/oper-customize-server/src/main/resources/db/migration/V0.0.34__formitem_zhzl.sql b/epmet-module/oper-customize/oper-customize-server/src/main/resources/db/migration/V0.0.34__formitem_zhzl.sql new file mode 100644 index 0000000000..51b502edbb --- /dev/null +++ b/epmet-module/oper-customize/oper-customize-server/src/main/resources/db/migration/V0.0.34__formitem_zhzl.sql @@ -0,0 +1 @@ +ALTER TABLE ic_form_item ADD COLUMN ZHZL_LIST_DISPLAY TINYINT ( 1 ) DEFAULT '0' COMMENT '综合治理图层列表显示:1展示,0不展示' AFTER LIST_DISPLAY; diff --git a/epmet-module/oper-customize/oper-customize-server/src/main/resources/mapper/IcFormItemDao.xml b/epmet-module/oper-customize/oper-customize-server/src/main/resources/mapper/IcFormItemDao.xml index b0906de8d1..e2689c4c62 100644 --- a/epmet-module/oper-customize/oper-customize-server/src/main/resources/mapper/IcFormItemDao.xml +++ b/epmet-module/oper-customize/oper-customize-server/src/main/resources/mapper/IcFormItemDao.xml @@ -147,7 +147,15 @@ m.DEL_FLAG = '0' AND m.CUSTOMER_ID = #{customerId} and m.FORM_CODE=#{formCode} - AND m.LIST_DISPLAY = '1' + + AND m.LIST_DISPLAY = '1' + + + AND m.LIST_DISPLAY = '1' + + + AND m.ZHZL_LIST_DISPLAY = '1' + )temp diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/IcResiUserPageFormDTO.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/IcResiUserPageFormDTO.java index 66ece366cc..7acb58f01b 100644 --- a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/IcResiUserPageFormDTO.java +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/IcResiUserPageFormDTO.java @@ -35,6 +35,10 @@ public class IcResiUserPageFormDTO extends PageFormDTO implements Serializable { * 关键词 */ private String keyword; - + /** + * 居民信息列表:resi + * 综合治理图层:zhzl + */ + private String listType; } diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/IcResiUserController.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/IcResiUserController.java index 8ed931e7ed..834ac2326c 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/IcResiUserController.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/IcResiUserController.java @@ -374,6 +374,7 @@ public class IcResiUserController implements ResultDataResolver { //pageFormDTO.setCustomerId("45687aa479955f9d06204d415238f7cc"); pageFormDTO.setCustomerId(tokenDto.getCustomerId()); pageFormDTO.setStaffId(tokenDto.getUserId()); + pageFormDTO.setListType("resi"); ValidatorUtils.validateEntity(pageFormDTO, IcResiUserPageFormDTO.AddUserInternalGroup.class); if (null == pageFormDTO.getConditions()) { pageFormDTO.setConditions(new ArrayList<>()); @@ -1271,4 +1272,26 @@ public class IcResiUserController implements ResultDataResolver { public Result> getIcUserCount(@RequestBody IcUserCountFormDTO formDTO) { return new Result>().ok(icResiUserService.getIcUserCount(formDTO)); } + + /** + * 综合治理图层:查询居民信息 + * @param tokenDto + * @param pageFormDTO + * @return + */ + @PostMapping("listresi-zhzl") + @MaskResponse(fieldNames = {"MOBILE", "ID_CARD"}, fieldsMaskType = {MaskResponse.MASK_TYPE_MOBILE, MaskResponse.MASK_TYPE_ID_CARD}) + public Result>> listResiZhzl(@LoginUser TokenDto tokenDto, @RequestBody IcResiUserPageFormDTO pageFormDTO) { + pageFormDTO.setCustomerId(tokenDto.getCustomerId()); + pageFormDTO.setStaffId(tokenDto.getUserId()); + pageFormDTO.setListType("zhzl"); + pageFormDTO.setIsPage(true); + ValidatorUtils.validateEntity(pageFormDTO, IcResiUserPageFormDTO.AddUserInternalGroup.class); + if (null == pageFormDTO.getConditions()) { + pageFormDTO.setConditions(new ArrayList<>()); + } + return new Result>>().ok(icResiUserService.listResiZhzl(pageFormDTO)); + } + + } diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/IcResiUserService.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/IcResiUserService.java index 97cb5345a5..f68830d81c 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/IcResiUserService.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/IcResiUserService.java @@ -490,4 +490,10 @@ public interface IcResiUserService extends BaseService { */ Map getIcUserCount(IcUserCountFormDTO formDTO); + /** + * 综合治理图层-查询各类别(信访人员、安置帮教、吸毒人员、社区矫正、不良青少年、肇事肇祸精神病、邪教人员)居民信息 + * @param pageFormDTO + * @return + */ + PageData> listResiZhzl(IcResiUserPageFormDTO pageFormDTO); } diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java index 57fd9c7d34..6c1ef637b3 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java @@ -787,9 +787,7 @@ public class IcResiUserServiceImpl extends BaseServiceImpl> pageResiMap(IcResiUserPageFormDTO formDTO) { // 查询列表展示项,如果没有,直接返回 - CustomerFormQueryDTO queryDTO1 = new CustomerFormQueryDTO(); - queryDTO1.setCustomerId(formDTO.getCustomerId()); - queryDTO1.setFormCode(formDTO.getFormCode()); + CustomerFormQueryDTO queryDTO1 = ConvertUtils.sourceToTarget(formDTO,CustomerFormQueryDTO.class); Result> resultColumnRes = operCustomizeOpenFeignClient.queryConditions(queryDTO1); if (!resultColumnRes.success() || CollectionUtils.isEmpty(resultColumnRes.getData())) { log.warn("没有配置列表展示列"); @@ -3045,4 +3043,181 @@ public class IcResiUserServiceImpl extends BaseServiceImpl list = ConvertUtils.sourceToTarget(userList,SendPointNoticeFormDTO.UserListBean.class); return list; } + + /** + * 综合治理图层-查询各类别(信访人员、安置帮教、吸毒人员、社区矫正、不良青少年、肇事肇祸精神病、邪教人员)居民信息 + * + * @param formDTO + * @return + */ + @Override + public PageData> listResiZhzl(IcResiUserPageFormDTO formDTO) { + // 查询列表展示项,如果没有,直接返回 + CustomerFormQueryDTO queryDTO1 = ConvertUtils.sourceToTarget(formDTO,CustomerFormQueryDTO.class); + Result> resultColumnRes = operCustomizeOpenFeignClient.queryConditions(queryDTO1); + if (!resultColumnRes.success() || CollectionUtils.isEmpty(resultColumnRes.getData())) { + log.warn("没有配置列表展示列"); + return new PageData(new ArrayList(), NumConstant.ZERO); + } + List resultColumns = resultColumnRes.getData(); + // 查询结果列对应的表: + Set resultColumnTables = resultColumns.stream().map(IcFormResColumnDTO::getTableName).collect(Collectors.toSet()); + List queryAgencyIdList = formDTO.getConditions().stream() + .filter(o -> IcResiUserConstant.IC_RESI_USER.equals(o.getTableName()) && "AGENCY_ID".equals(o.getColumnName()) + && CollectionUtils.isNotEmpty(o.getColumnValue()) && StringUtils.isNotBlank(o.getColumnValue().get(NumConstant.ZERO))) + .flatMap(o -> o.getColumnValue().stream()).collect(Collectors.toList()); + + //添加数据权限 + String staffOrgPath; + String agencyId; + //如果查询条件中 有居民表的agencyId 则匹配查询该组织下的 数据 + if (queryAgencyIdList.isEmpty()){ + CustomerStaffInfoCacheResult staffInfoCacheResult = CustomerStaffRedis.getStaffInfo(formDTO.getCustomerId(), formDTO.getStaffId()); + agencyId = staffInfoCacheResult.getAgencyId(); + if (StringUtils.isNotBlank(staffInfoCacheResult.getAgencyPIds()) && !NumConstant.ZERO_STR.equals(staffInfoCacheResult.getAgencyPIds())) { + staffOrgPath = staffInfoCacheResult.getAgencyPIds().concat(":").concat(staffInfoCacheResult.getAgencyId()); + } else { + staffOrgPath = staffInfoCacheResult.getAgencyId(); + } + } else { + formDTO.getConditions().removeIf(o->IcResiUserConstant.IC_RESI_USER.equals(o.getTableName()) && "AGENCY_ID".equals(o.getColumnName())); + AgencyInfoCache agencyInfo = CustomerOrgRedis.getAgencyInfo(queryAgencyIdList.get(NumConstant.ZERO)); + if (agencyInfo == null){ + throw new EpmetException(EpmetErrorCode.EPMET_COMMON_OPERATION_FAIL.getCode(),"获取组织信息失败"); + } + agencyId = agencyInfo.getId(); + staffOrgPath = agencyInfo.getPids(); + if (StringUtils.isBlank(staffOrgPath)){ + staffOrgPath = agencyId; + }else{ + staffOrgPath = staffOrgPath+StrConstant.COLON+agencyInfo.getId(); + } + } + // 查询列表展示项需要用到哪些子表 + Result> subTablesRes = operCustomizeOpenFeignClient.querySubTables(queryDTO1); + List subTables = subTablesRes.getData(); + log.info("1、所有的子表subTables:"+JSON.toJSONString(subTables,true)); + + //关联哪些子表:查询条件用到的表名+查询的列对应的表 并集去重 + Set whereConditionTables = formDTO.getConditions().stream().map(ResiUserQueryValueDTO::getTableName).collect(Collectors.toSet()); + Set tables = new HashSet<>(); + tables.addAll(whereConditionTables); + tables.addAll(resultColumnTables); + log.info("2、查询条件+查询列对应的tables并集去重:"+ JSON.toJSONString(tables,true)); + //最终关联的子表对应的sql: + List finalSubTables = new ArrayList<>(); + //groupBy用到的表 + Set groupByTables = new HashSet<>(); + subTables.forEach(subTable -> { + if (tables.contains(subTable.getTableName())) { + finalSubTables.add(subTable.getJoinTableSql()); + if (subTable.getSupportAdd()) { + groupByTables.add(subTable.getTableName()); + } + } + }); + + PageInfo> pageInfo = new PageInfo<>(); + if (null == formDTO.getIsPage() || formDTO.getIsPage()) { + //分页 + String finalStaffOrgPath = staffOrgPath; + pageInfo = PageHelper.startPage(formDTO.getPageNo(), + formDTO.getPageSize()).doSelectPageInfo(() -> baseDao.selectListResiMap(formDTO.getCustomerId(), + formDTO.getFormCode(), + formDTO.getConditions(), + resultColumns, + finalSubTables, + agencyId, finalStaffOrgPath,null, formDTO.getKeyword(), + groupByTables)); + } else { + List> list = baseDao.selectListResiMap(formDTO.getCustomerId(), + formDTO.getFormCode(), + formDTO.getConditions(), + resultColumns, + finalSubTables, + agencyId, + staffOrgPath,null, + formDTO.getKeyword(), + groupByTables); + pageInfo.setTotal(CollectionUtils.isEmpty(list) ? NumConstant.ZERO : list.size()); + pageInfo.setList(list); + } + + List> list = pageInfo.getList(); + //查询网格名称 + List gridIds = new ArrayList<>(); + Set houseIds = new HashSet<>(); + for (Map map : list) { + if (map.containsKey(UserConstant.GRID_ID) && null != map.get(UserConstant.GRID_ID) && StringUtils.isNotBlank(map.get(UserConstant.GRID_ID).toString())) { + gridIds.add(map.get(UserConstant.GRID_ID).toString()); + } + if (map.containsKey(UserConstant.HOME_ID) && null != map.get(UserConstant.HOME_ID) && StringUtils.isNotBlank(map.get(UserConstant.HOME_ID).toString())) { + houseIds.add(map.get(UserConstant.HOME_ID).toString()); + } + } + Result> gridInfoRes = govOrgOpenFeignClient.getGridListByGridIds(gridIds); + List gridInfoList = gridInfoRes.success() && !CollectionUtils.isEmpty(gridInfoRes.getData()) ? gridInfoRes.getData() : new ArrayList<>(); + Map gridInfoMap = gridInfoList.stream().collect(Collectors.toMap(AllGridsByUserIdResultDTO::getGridId, Function.identity())); + + //查询房子名称 + Result> houseInfoRes = govOrgOpenFeignClient.queryListHouseInfo(houseIds, formDTO.getCustomerId()); + List houseInfoDTOList = houseInfoRes.success() && !CollectionUtils.isEmpty(houseInfoRes.getData()) ? houseInfoRes.getData() : new ArrayList<>(); + Map houseInfoMap = houseInfoDTOList.stream().collect(Collectors.toMap(HouseInfoDTO::getHomeId, Function.identity())); + + + for (Map resultMap : list) { + String gridIdValue = null != resultMap.get(UserConstant.GRID_ID) ? resultMap.get(UserConstant.GRID_ID).toString() : StrConstant.EPMETY_STR; + resultMap.put("GRID_ID_VALUE", gridIdValue); + if (gridInfoMap.containsKey(gridIdValue) && null != gridInfoMap.get(gridIdValue)) { + //GRID_NAME + resultMap.put(UserConstant.GRID_ID, gridInfoMap.get(gridIdValue).getGridName()); + } + + String homeId = null != resultMap.get(UserConstant.HOME_ID) ? resultMap.get(UserConstant.HOME_ID).toString() : StrConstant.EPMETY_STR; + resultMap.put("HOME_ID_VALUE", homeId); + if (houseInfoMap.containsKey(homeId) && null != houseInfoMap.get(homeId)) { + HouseInfoDTO houseInfoDTO = houseInfoMap.get(homeId); + String buildName = StringUtils.isNotBlank(houseInfoDTO.getBuildingName()) ? houseInfoDTO.getBuildingName() : StrConstant.EPMETY_STR; + resultMap.put("BUILD_NAME", buildName); + + String neighBorName = StringUtils.isNotBlank(houseInfoDTO.getNeighborHoodName()) ? houseInfoDTO.getNeighborHoodName() : StrConstant.EPMETY_STR; + resultMap.put("VILLAGE_NAME", neighBorName); + + String unitName = StringUtils.isNotBlank(houseInfoDTO.getUnitName()) ? houseInfoDTO.getUnitName() : StrConstant.EPMETY_STR; + resultMap.put("UNIT_NAME", unitName); + + String doorName = StringUtils.isNotBlank(houseInfoDTO.getDoorName()) ? houseInfoDTO.getDoorName() : StrConstant.EPMETY_STR; + resultMap.put("DOOR_NAME", doorName); + + String houseType = StringUtils.isNotBlank(houseInfoDTO.getHouseType()) ? houseInfoDTO.getHouseType() : StrConstant.EPMETY_STR; + //房屋类型,1楼房,2平房,3别墅 + resultMap.put(UserConstant.HOUSE_TYPE_KEY, ""); + if (HouseTypeEnum.LOUFANG.getCode().equals(houseType)) { + resultMap.put(UserConstant.HOUSE_TYPE_KEY, HouseTypeEnum.LOUFANG.getName()); + } else if (HouseTypeEnum.PINGFANG.getCode().equals(houseType)) { + resultMap.put(UserConstant.HOUSE_TYPE_KEY, HouseTypeEnum.PINGFANG.getName()); + } else if (HouseTypeEnum.BIESHU.getCode().equals(houseType)) { + resultMap.put(UserConstant.HOUSE_TYPE_KEY, HouseTypeEnum.BIESHU.getName()); + } + resultMap.put(UserConstant.HOME_ID, neighBorName.concat(buildName).concat(unitName).concat(doorName)); + + } + + if (resultMap.containsKey(UserConstant.GENDER)) { + String genderValue = null != resultMap.get(UserConstant.GENDER) ? resultMap.get(UserConstant.GENDER).toString() : StrConstant.EPMETY_STR; + if (GenderEnum.MAN.getCode().equals(genderValue)) { + resultMap.put(UserConstant.GENDER, GenderEnum.MAN.getName()); + } else if (GenderEnum.WOMAN.getCode().equals(genderValue)) { + resultMap.put(UserConstant.GENDER, GenderEnum.WOMAN.getName()); + } else if (GenderEnum.UN_KNOWN.getCode().equals(genderValue)) { + resultMap.put(UserConstant.GENDER, GenderEnum.UN_KNOWN.getName()); + } + } + // 如果是信访人员 + + // 如果是特殊人群,且有特殊人群类别 + } + pageInfo.setList(list); + return new PageData<>(pageInfo.getList(), pageInfo.getTotal()); + } } From 210189e227af3d22f85fe877f881ff79f457117c Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Wed, 27 Jul 2022 10:09:46 +0800 Subject: [PATCH 061/155] =?UTF-8?q?=E7=BB=BC=E5=90=88=E6=B2=BB=E7=90=86?= =?UTF-8?q?=E5=9B=BE=E5=B1=82=E6=9F=A5=E8=AF=A22?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../db/migration/V0.0.34__formitem_zhzl.sql | 7 +++++++ .../epmet/service/impl/IcResiUserServiceImpl.java | 15 ++++++++++++++- 2 files changed, 21 insertions(+), 1 deletion(-) diff --git a/epmet-module/oper-customize/oper-customize-server/src/main/resources/db/migration/V0.0.34__formitem_zhzl.sql b/epmet-module/oper-customize/oper-customize-server/src/main/resources/db/migration/V0.0.34__formitem_zhzl.sql index 51b502edbb..9784ebe953 100644 --- a/epmet-module/oper-customize/oper-customize-server/src/main/resources/db/migration/V0.0.34__formitem_zhzl.sql +++ b/epmet-module/oper-customize/oper-customize-server/src/main/resources/db/migration/V0.0.34__formitem_zhzl.sql @@ -1 +1,8 @@ ALTER TABLE ic_form_item ADD COLUMN ZHZL_LIST_DISPLAY TINYINT ( 1 ) DEFAULT '0' COMMENT '综合治理图层列表显示:1展示,0不展示' AFTER LIST_DISPLAY; + + +update ic_form_item i set i.ZHZL_LIST_DISPLAY='1' +where i.DEL_FLAG='0' + and i.COLUMN_NAME in( + 'GRID_ID','HOME_ID','NAME','MOBILE','ID_CARD','GENDER','BIRTHDAY','REMARKS','IS_XFRY','IS_SPECIAL','SPECIAL_RQLB' + ); \ No newline at end of file diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java index 6c1ef637b3..a529fe8438 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java @@ -3213,9 +3213,22 @@ public class IcResiUserServiceImpl extends BaseServiceImpl zhzlCategoryName=new ArrayList<>(); // 如果是信访人员 - + String isXfry = StringUtils.isNotBlank((String)resultMap.get("IS_XFRY")) ? resultMap.get("IS_XFRY").toString() : StrConstant.EPMETY_STR; + if(NumConstant.ONE_STR.equals(isXfry)){ + zhzlCategoryName.add("信访人员"); + } // 如果是特殊人群,且有特殊人群类别 + String isSpecial = StringUtils.isNotBlank((String)resultMap.get("IS_SPECIAL")) ? resultMap.get("IS_SPECIAL").toString() : StrConstant.EPMETY_STR; + String specialRqlb = StringUtils.isNotBlank((String)resultMap.get("SPECIAL_RQLB")) ? resultMap.get("SPECIAL_RQLB").toString() : StrConstant.EPMETY_STR; + if(NumConstant.ONE_STR.equals(isSpecial)&&StringUtils.isNotBlank(specialRqlb)){ + String[] att=specialRqlb.split(StrConstant.COMMA); + for(String categoryCode:att){ + zhzlCategoryName.add(ZhzlResiCategoryEnum.getEnum(categoryCode).getName()); + } + } + resultMap.put("zhzlCategoryName",zhzlCategoryName.stream().collect(Collectors.joining(StrConstant.COMMA))); } pageInfo.setList(list); return new PageData<>(pageInfo.getList(), pageInfo.getTotal()); From 52c9ceb3d046ac1921654f4f4cb382fefa19b355 Mon Sep 17 00:00:00 2001 From: wangxianzhang Date: Wed, 27 Jul 2022 10:21:50 +0800 Subject: [PATCH 062/155] =?UTF-8?q?=E3=80=90=E5=9B=BE=E5=B1=82=E3=80=91?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E6=96=B0=E5=88=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../govorg/IcCoverageCategoryDictEntity.java | 10 ++++++++++ .../govorg/IcCoverageCategoryDictDao.xml | 2 ++ .../entity/IcCoverageCategoryDictEntity.java | 20 ++++++++++++++----- 3 files changed, 27 insertions(+), 5 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCoverageCategoryDictEntity.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCoverageCategoryDictEntity.java index cdaca78b91..dee38b469f 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCoverageCategoryDictEntity.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCoverageCategoryDictEntity.java @@ -43,6 +43,16 @@ public class IcCoverageCategoryDictEntity extends BaseEpmetEntity { */ private String placeType; + /** + * 在可视化系统中所属的plact_type,跟COVERAGE_TYPE可能不同,COVERAGE_TYPE是给管理平台用的 + */ + private String placeTypeInAnalysis; + + /** + * 要跟菜单绑定(客户配置了这个菜单,这里才显示) + */ + private String menuUrl; + /** * 所属五大图层:zhzl:综合治理图层;yjcl:应急处置图层;aqsc:安全生产图层;csgl:城市管理图层;ggfw:公共服务图层 */ diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryDictDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryDictDao.xml index beb08a1262..25c0704bbd 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryDictDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryDictDao.xml @@ -10,6 +10,8 @@ + + diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcCoverageCategoryDictEntity.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcCoverageCategoryDictEntity.java index c690e4a48a..13a31b9974 100755 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcCoverageCategoryDictEntity.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcCoverageCategoryDictEntity.java @@ -37,15 +37,25 @@ public class IcCoverageCategoryDictEntity extends BaseEpmetEntity { private String categoryName; /** - * 所属场所类型; -社区自组织:community_org; -优势资源:superior_resource; -城市管理:city_management; -重点危化企业:dangerous_chemicals; + * 所属场所类型; +社区自组织:community_org; +优势资源:superior_resource; +城市管理:city_management; +重点危化企业:dangerous_chemicals; 公共服务:public_service */ private String placeType; + /** + * 在可视化系统中所属的plact_type,跟COVERAGE_TYPE可能不同,COVERAGE_TYPE是给管理平台用的 + */ + private String placeTypeInAnalysis; + + /** + * 要跟菜单绑定(客户配置了这个菜单,这里才显示) + */ + private String menuUrl; + /** * 所属五大图层:zhzl:综合治理图层;yjcl:应急处置图层;aqsc:安全生产图层;csgl:城市管理图层;ggfw:公共服务图层 */ From d680d49eebbbf145f73180edb4fd9c34ae482609 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Wed, 27 Jul 2022 10:27:53 +0800 Subject: [PATCH 063/155] =?UTF-8?q?=E7=BB=BC=E5=90=88=E6=B2=BB=E7=90=86?= =?UTF-8?q?=E5=9B=BE=E5=B1=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/epmet/service/impl/IcResiUserServiceImpl.java | 9 --------- 1 file changed, 9 deletions(-) diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java index a529fe8438..07aeab3f53 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java @@ -3190,15 +3190,6 @@ public class IcResiUserServiceImpl extends BaseServiceImpl Date: Wed, 27 Jul 2022 10:31:26 +0800 Subject: [PATCH 064/155] =?UTF-8?q?=E8=8E=B7=E5=8F=96=E5=AE=A2=E6=88=B7?= =?UTF-8?q?=E4=B8=8B=E8=8F=9C=E5=8D=95=E5=8A=A0=E4=BA=86=E4=B8=AAfeign?= =?UTF-8?q?=E6=96=B9=E6=B3=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dto/form/GetCustomerMenuListFormDTO.java | 27 +++++++++++++++++++ .../com/epmet/feign/GovAccessFeignClient.java | 15 ++++++++--- .../GovAccessFeignClientFallBack.java | 11 +++++--- .../epmet/controller/GovMenuController.java | 12 +++++++++ .../com/epmet/service/GovMenuService.java | 9 +++++++ .../service/impl/GovMenuServiceImpl.java | 17 ++++++++++++ 6 files changed, 83 insertions(+), 8 deletions(-) create mode 100644 epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/dto/form/GetCustomerMenuListFormDTO.java diff --git a/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/dto/form/GetCustomerMenuListFormDTO.java b/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/dto/form/GetCustomerMenuListFormDTO.java new file mode 100644 index 0000000000..a79722fcd4 --- /dev/null +++ b/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/dto/form/GetCustomerMenuListFormDTO.java @@ -0,0 +1,27 @@ +package com.epmet.dto.form; + +import lombok.Data; + +import java.io.Serializable; + +/** + * @Author zxc + * @DateTime 2022/7/27 10:13 + * @DESC + */ +@Data +public class GetCustomerMenuListFormDTO implements Serializable { + + private static final long serialVersionUID = 8143715578744359728L; + + private String customerId; + + /** + * 0:菜单;1:按钮 + */ + private Integer type; + + private String language; + + private String tableName; +} diff --git a/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/GovAccessFeignClient.java b/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/GovAccessFeignClient.java index 36ccf542bb..ce7fc27c82 100644 --- a/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/GovAccessFeignClient.java +++ b/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/GovAccessFeignClient.java @@ -2,10 +2,8 @@ package com.epmet.feign; import com.epmet.commons.tools.constant.ServiceConstant; import com.epmet.commons.tools.utils.Result; -import com.epmet.dto.form.GetStaffExistRoleFormDTO; -import com.epmet.dto.form.InitDefaultOperationsFormDTO; -import com.epmet.dto.form.ListOpePermsFormDTO; -import com.epmet.dto.form.RoleUserFormDTO; +import com.epmet.dto.GovMenuDTO; +import com.epmet.dto.form.*; import com.epmet.dto.result.NewUserRoleResultDTO; import com.epmet.feign.fallback.GovAccessFeignClientFallBackFactory; import org.springframework.cloud.openfeign.FeignClient; @@ -52,4 +50,13 @@ public interface GovAccessFeignClient { @PostMapping("/gov/access/govroleuser/getStaffExistRole") Result> getStaffExistRole(@RequestBody GetStaffExistRoleFormDTO formDTO); + /** + * Desc: 获取客户下的菜单 + * @param formDTO + * @author zxc + * @date 2022/7/27 10:22 + */ + @PostMapping("/gov/access/menu/getCustomerMenuList") + Result> getCustomerMenuList(@RequestBody GetCustomerMenuListFormDTO formDTO); + } diff --git a/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/fallback/GovAccessFeignClientFallBack.java b/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/fallback/GovAccessFeignClientFallBack.java index bfb9acbc3b..ed19d5728c 100644 --- a/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/fallback/GovAccessFeignClientFallBack.java +++ b/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/fallback/GovAccessFeignClientFallBack.java @@ -3,10 +3,8 @@ package com.epmet.feign.fallback; import com.epmet.commons.tools.constant.ServiceConstant; import com.epmet.commons.tools.utils.ModuleUtils; import com.epmet.commons.tools.utils.Result; -import com.epmet.dto.form.GetStaffExistRoleFormDTO; -import com.epmet.dto.form.InitDefaultOperationsFormDTO; -import com.epmet.dto.form.ListOpePermsFormDTO; -import com.epmet.dto.form.RoleUserFormDTO; +import com.epmet.dto.GovMenuDTO; +import com.epmet.dto.form.*; import com.epmet.dto.result.NewUserRoleResultDTO; import com.epmet.feign.GovAccessFeignClient; @@ -40,4 +38,9 @@ public class GovAccessFeignClientFallBack implements GovAccessFeignClient { public Result> getStaffExistRole(GetStaffExistRoleFormDTO formDTO) { return ModuleUtils.feignConError(ServiceConstant.GOV_ACCESS_SERVER, "getStaffExistRole", formDTO); } + + @Override + public Result> getCustomerMenuList(GetCustomerMenuListFormDTO formDTO) { + return ModuleUtils.feignConError(ServiceConstant.GOV_ACCESS_SERVER, "getCustomerMenuList", formDTO); + } } diff --git a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/controller/GovMenuController.java b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/controller/GovMenuController.java index ce89f2c7d8..cc94cd91f0 100644 --- a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/controller/GovMenuController.java +++ b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/controller/GovMenuController.java @@ -11,6 +11,7 @@ import com.epmet.commons.tools.validator.group.AddGroup; import com.epmet.commons.tools.validator.group.DefaultGroup; import com.epmet.commons.tools.validator.group.UpdateGroup; import com.epmet.dto.GovMenuDTO; +import com.epmet.dto.form.GetCustomerMenuListFormDTO; import com.epmet.service.GovMenuService; import com.epmet.service.GovResourceService; import org.springframework.beans.factory.annotation.Autowired; @@ -155,4 +156,15 @@ public class GovMenuController { govMenuService.clearOperUserAccess(tokenDto.getApp(), tokenDto.getClient(), tokenDto.getUserId()); return new Result(); } + + /** + * Desc: 获取客户下的菜单 + * @param formDTO + * @author zxc + * @date 2022/7/27 10:22 + */ + @PostMapping("getCustomerMenuList") + public Result> getCustomerMenuList(@RequestBody GetCustomerMenuListFormDTO formDTO){ + return new Result>().ok(govMenuService.getCustomerMenuList(formDTO)); + } } diff --git a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/GovMenuService.java b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/GovMenuService.java index fd09359551..127f271940 100644 --- a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/GovMenuService.java +++ b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/GovMenuService.java @@ -21,6 +21,7 @@ import com.epmet.commons.mybatis.service.BaseService; import com.epmet.commons.tools.page.PageData; import com.epmet.commons.tools.security.dto.TokenDto; import com.epmet.dto.GovMenuDTO; +import com.epmet.dto.form.GetCustomerMenuListFormDTO; import com.epmet.entity.GovMenuEntity; import java.util.List; @@ -145,4 +146,12 @@ public interface GovMenuService extends BaseService { List getListPid(String pid); void clearOperUserAccess(String app, String client, String userId); + + /** + * Desc: 获取客户下的菜单 + * @param formDTO + * @author zxc + * @date 2022/7/27 10:22 + */ + List getCustomerMenuList(GetCustomerMenuListFormDTO formDTO); } diff --git a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovMenuServiceImpl.java b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovMenuServiceImpl.java index 92c86a2c1c..a3b63e096b 100644 --- a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovMenuServiceImpl.java +++ b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovMenuServiceImpl.java @@ -36,6 +36,7 @@ import com.epmet.dao.GovRoleDao; import com.epmet.dao.GovRoleMenuDao; import com.epmet.dao.GovRoleUserDao; import com.epmet.dto.GovMenuDTO; +import com.epmet.dto.form.GetCustomerMenuListFormDTO; import com.epmet.entity.GovMenuEntity; import com.epmet.enums.MenuTypeEnum; import com.epmet.feign.EpmetUserOpenFeignClient; @@ -343,6 +344,22 @@ public class GovMenuServiceImpl extends BaseServiceImpl getCustomerMenuList(GetCustomerMenuListFormDTO formDTO) { + List customerMenuList = baseDao.getCustomerMenuList(formDTO.getCustomerId(), formDTO.getType(), HttpContextUtils.getLanguage(), formDTO.getTableName()); + if (CollectionUtils.isEmpty(customerMenuList)){ + return new ArrayList<>(); + } + return ConvertUtils.sourceToTarget(customerMenuList,GovMenuDTO.class); + + } + private void saveLanguage(String tableName, String tableId, String fieldName, String fieldValue){ govLanguageService.saveOrUpdate(tableName, tableId, fieldName, fieldValue, HttpContextUtils.getLanguage()); } From 0e382024233089f0317a57ec276655b243866d63 Mon Sep 17 00:00:00 2001 From: zxc <1272811460@qq.com> Date: Wed, 27 Jul 2022 15:28:05 +0800 Subject: [PATCH 065/155] =?UTF-8?q?=E7=BB=99=E5=AE=A2=E6=88=B7=E5=8B=BE?= =?UTF-8?q?=E9=80=89=E8=8F=9C=E5=8D=95=E6=97=B6=EF=BC=8C=E5=88=A0=E9=99=A4?= =?UTF-8?q?=E7=BC=93=E5=AD=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/epmet/commons/tools/redis/RedisKeys.java | 10 ++++++++++ .../java/com/epmet/commons/tools/redis/RedisUtils.java | 9 +++++++++ .../java/com/epmet/redis/GovCustomerMenuRedis.java | 5 +++++ .../epmet/service/impl/GovCustomerMenuServiceImpl.java | 1 + 4 files changed, 25 insertions(+) diff --git a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/redis/RedisKeys.java b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/redis/RedisKeys.java index d6e8a2c245..76585fa96f 100644 --- a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/redis/RedisKeys.java +++ b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/redis/RedisKeys.java @@ -766,6 +766,16 @@ public class RedisKeys { return rootPrefix.concat("gov:access:nav:"); } + /** + * Desc: 新五大图层获取菜单缓存key + * @param + * @author zxc + * @date 2022/7/27 13:42 + */ + public static String getCustomerMenuListFiveCoverage() { + return rootPrefix.concat("customer:govMenu:"); + } + /** * 如果是省列表:epmet:areacode:parentCode:0 * 山东省的下一级:epmet:areacode:parentCode:37 diff --git a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/redis/RedisUtils.java b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/redis/RedisUtils.java index 2dce88e919..311830ae9f 100644 --- a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/redis/RedisUtils.java +++ b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/redis/RedisUtils.java @@ -375,6 +375,15 @@ public class RedisUtils { return redisTemplate.opsForSet().add(key,value); } + public void listAdd(String key,Object value){ + redisTemplate.opsForList().rightPush(key,value); + } + + public Object listGetAll(String key,Integer start, Integer end){ + List result = redisTemplate.opsForList().range(key, start, end); + return result; + } + /** * @Description 获取 zset 中带score的集合 * @param key diff --git a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/redis/GovCustomerMenuRedis.java b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/redis/GovCustomerMenuRedis.java index 64dcb0fb1c..274ad0fed3 100644 --- a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/redis/GovCustomerMenuRedis.java +++ b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/redis/GovCustomerMenuRedis.java @@ -78,6 +78,11 @@ public class GovCustomerMenuRedis { redisUtils.deleteByPattern(key); } + public void delAllCustomerMenuFiveCoverage(String customerId){ + String key = RedisKeys.getCustomerMenuListFiveCoverage().concat(customerId); + redisUtils.delete(key); + } + private boolean checkParam(String customerId, Integer type) { if (StringUtils.isBlank(customerId) || type == null){ log.warn("checkParam fail, param is null"); diff --git a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovCustomerMenuServiceImpl.java b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovCustomerMenuServiceImpl.java index a5933f8e58..0a93c9a4d1 100644 --- a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovCustomerMenuServiceImpl.java +++ b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovCustomerMenuServiceImpl.java @@ -115,6 +115,7 @@ public class GovCustomerMenuServiceImpl extends BaseServiceImpl Date: Wed, 27 Jul 2022 15:49:47 +0800 Subject: [PATCH 066/155] =?UTF-8?q?=E3=80=90=E5=9B=BE=E5=B1=82=E3=80=91?= =?UTF-8?q?=E5=AE=8C=E6=88=90=E6=9F=A5=E8=AF=A2=E5=8F=B3=E4=BE=A7=E8=8F=9C?= =?UTF-8?q?=E5=8D=95=E6=8E=A5=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../commons/tools/enums/CoverageEnums.java | 47 ++++++++++++ .../tools/enums/CoveragePlaceTypeEnum.java | 1 + .../AnalysisResourceCategoriesResult.java | 69 ++++++++++++++++++ .../controller/CoverageController.java | 11 +++ .../dataaggre/service/CoverageService.java | 6 ++ .../service/govorg/GovOrgCoverageService.java | 2 + .../impl/GovOrgCoverageServiceImpl.java | 9 +++ .../service/impl/CoverageServiceImpl.java | 72 +++++++++++++++++++ 8 files changed, 217 insertions(+) create mode 100644 epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoverageEnums.java create mode 100644 epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/coverage/AnalysisResourceCategoriesResult.java diff --git a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoverageEnums.java b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoverageEnums.java new file mode 100644 index 0000000000..0e2e749b16 --- /dev/null +++ b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoverageEnums.java @@ -0,0 +1,47 @@ +package com.epmet.commons.tools.enums; + +/** + * 图层枚举 + */ +public enum CoverageEnums { + + ZHZL("zhzl", "综合治理图层", 1), + YJCL("yjcl", "应急处置资源", 2), + AQSC("aqsc", "安全生产资源", 2), + CSGL("csgl", "城市管理资源", 2), + GGFW("ggfw", "公共服务资源", 2); + + private String coverageType; + private String coverageName; + + /** 位置,1:左侧,2,右侧**/ + private Integer position; + + CoverageEnums(String coverageType, String coverageName, Integer position) { + this.coverageType = coverageType; + this.coverageName = coverageName; + this.position = position; + } + + public static CoverageEnums getEnum(String coverageType) { + CoverageEnums[] values = CoverageEnums.values(); + for (CoverageEnums value : values) { + if (value.getCoverageType().equals(coverageType)) { + return value; + } + } + return null; + } + + public String getCoverageType() { + return coverageType; + } + + public String getCoverageName() { + return coverageName; + } + + public Integer getPosition() { + return position; + } +} diff --git a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoveragePlaceTypeEnum.java b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoveragePlaceTypeEnum.java index eb8d25e80f..dbad5fa3c2 100644 --- a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoveragePlaceTypeEnum.java +++ b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoveragePlaceTypeEnum.java @@ -14,6 +14,7 @@ public enum CoveragePlaceTypeEnum { PUBLIC_SERVICE("public_service", "公共服务"), RESI("resi", "居民"), PARTY_UNIT("party_unit", "联建单位"), + VOLUNTEER("volunteer", "志愿者"), GROUP_RENT("group_rent", "群租房"), EVENT("event", "事件(包括难点堵点)"); diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/coverage/AnalysisResourceCategoriesResult.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/coverage/AnalysisResourceCategoriesResult.java new file mode 100644 index 0000000000..216c41f705 --- /dev/null +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/coverage/AnalysisResourceCategoriesResult.java @@ -0,0 +1,69 @@ +package com.epmet.dataaggre.dto.coverage; + +import lombok.AllArgsConstructor; +import lombok.Data; +import lombok.NoArgsConstructor; + +import java.util.ArrayList; +import java.util.List; + +/** + * 五大图层-可视化-右侧分类树列表 + */ +@Data +@NoArgsConstructor +@AllArgsConstructor +public class AnalysisResourceCategoriesResult { + + /** + * 图层类型 + */ + private String coverageType; + /** + * 图层名称 + */ + private String coverageName; + /** + * 个数 + */ + private Integer count; + + /** + * 没有placeTypeInAnalysis,直接属于图层的 + */ + private List categories = new ArrayList<>(); + + /** + * 场所类型,有placeTypeInAnalysis,不直接属于图层的 + */ + private List placeTypesInAnalysis = new ArrayList<>(); + + /** + * 分类 + */ + @Data + @NoArgsConstructor + @AllArgsConstructor + public static class Category { + private String categoryKey; + private String categoryName; + private String coverageType; + private String placeType; + private Integer count = 0; + } + + /** + * 场所类型 + */ + @Data + @NoArgsConstructor + @AllArgsConstructor + public static class PlaceType { + private String placeType; + private String placeTypeName; + private Integer count = 0; + private List categories; + } + + +} diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java index 8ce19a7b9e..fa68116993 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java @@ -6,6 +6,7 @@ import com.epmet.commons.tools.enums.ZhzlResiCategoryEnum; import com.epmet.commons.tools.page.PageData; import com.epmet.commons.tools.security.dto.TokenDto; import com.epmet.commons.tools.utils.Result; +import com.epmet.dataaggre.dto.coverage.AnalysisResourceCategoriesResult; import com.epmet.dataaggre.dto.govorg.form.CoverageAnalisisDataListFormDTO; import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; import com.epmet.dataaggre.dto.govorg.result.CoverageAnalisisDataListResultDTO; @@ -72,4 +73,14 @@ public class CoverageController { return new Result().ok(coverageService.coverageHomeSearch(formDTO)); } + /** + * 五大图层-可视化-右侧分类树列表 + * @return + */ + @PostMapping("analysis/resourceCategories") + public Result> listAnalysisResourceCategories() { + List r = coverageService.listAnalysisResourceCategories(); + return new Result>().ok(r); + } + } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java index 5674c60c2e..f372f2699c 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java @@ -1,6 +1,7 @@ package com.epmet.dataaggre.service; import com.epmet.commons.tools.page.PageData; +import com.epmet.dataaggre.dto.coverage.AnalysisResourceCategoriesResult; import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; import com.epmet.dataaggre.dto.govorg.result.CoverageAnalisisDataListResultDTO; import com.epmet.dataaggre.dto.govorg.result.CoverageHomeSearchResultDTO; @@ -31,4 +32,9 @@ public interface CoverageService { */ CoverageHomeSearchResultDTO coverageHomeSearch(CoverageHomeSearchFormDTO formDTO); + /** + * 五大图层-可视化-右侧分类树列表 + * @return + */ + List listAnalysisResourceCategories(); } \ No newline at end of file diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java index 424cba462d..8168721b71 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java @@ -137,4 +137,6 @@ public interface GovOrgCoverageService { * @return */ IcCoverageCategoryDictEntity selectByCategoryKey(String categoryKey); + + List listCoverageCategoryEntities(String coverageType); } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java index 85b7d2569c..2f39da60a4 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java @@ -324,4 +324,13 @@ public class GovOrgCoverageServiceImpl implements GovOrgCoverageService { query.ge(IcHouseEntity::getResiNumber, resiNumberBiggerThan); return query; } + + @Override + public List listCoverageCategoryEntities(String coverageType) { + LambdaQueryWrapper query = new LambdaQueryWrapper<>(); + query.eq(IcCoverageCategoryDictEntity::getCustomerId, EpmetRequestHolder.getLoginUserCustomerId()); + query.eq(IcCoverageCategoryDictEntity::getCoverageType, coverageType); + query.orderByAsc(IcCoverageCategoryDictEntity::getSort); + return coverageCategoryDictDao.selectList(query); + } } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index 2a73095105..dfae8be881 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -1,12 +1,15 @@ package com.epmet.dataaggre.service.impl; import com.epmet.commons.tools.dto.result.CustomerStaffInfoCacheResult; +import com.epmet.commons.tools.enums.CoverageEnums; +import com.epmet.commons.tools.enums.CoveragePlaceTypeEnum; import com.epmet.commons.tools.exception.EpmetErrorCode; import com.epmet.commons.tools.exception.EpmetException; import com.epmet.commons.tools.page.PageData; import com.epmet.commons.tools.redis.common.CustomerStaffRedis; import com.epmet.commons.tools.redis.common.bean.BuildingInfoCache; import com.epmet.commons.tools.utils.EpmetRequestHolder; +import com.epmet.dataaggre.dto.coverage.AnalysisResourceCategoriesResult; import com.epmet.dataaggre.dto.epmetuser.result.IcResiInfoResultDTO; import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; import com.epmet.dataaggre.dto.govorg.result.CoverageAnalisisDataListResultDTO; @@ -30,8 +33,10 @@ import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import java.util.ArrayList; +import java.util.HashMap; import java.util.List; import java.util.Map; +import java.util.concurrent.atomic.AtomicReference; import java.util.stream.Collectors; @Slf4j @@ -53,6 +58,9 @@ public class CoverageServiceImpl implements CoverageService { @Autowired private GovProjectService govProjectService; + @Autowired + private GovOrgCoverageService govOrgCoverageService; + /** * 场所类型常量 */ @@ -452,4 +460,68 @@ public class CoverageServiceImpl implements CoverageService { } return new String[]{longitude, latitude}; } + + /** + * 五大图层-可视化-右侧分类树列表 + * @return + */ + @Override + public List listAnalysisResourceCategories() { + + //结果集 + ArrayList results = new ArrayList<>(); + + // 1.查询categoryDict表得到基础数据,每个图层循环一次 + for (CoverageEnums coverage : CoverageEnums.values()) { + + // 只要右边的 + if (!coverage.getPosition().equals(Integer.valueOf(2))) { + continue; + } + + AnalysisResourceCategoriesResult categoriesOfThisCoverage = new AnalysisResourceCategoriesResult(); + HashMap placeTypeMap = new HashMap<>(); + + List categoryDictEntities = govOrgCoverageService.listCoverageCategoryEntities(coverage.getCoverageType()); + + // 2.根据menuUrl过滤 todo + + // 2.计算各类数量 todo + + // 3.对上一步得到的数据进行分组,使用PLACE_TYPE_IN_ANALYSIS分组,然后放入placeType,这一列为空的说明不分组,直接属于coverage + categoryDictEntities.forEach(c -> { + if (StringUtils.isBlank(c.getPlaceTypeInAnalysis())) { + // 没有placetype的 + categoriesOfThisCoverage.getCategories() + .add(new AnalysisResourceCategoriesResult.Category(c.getCategoryKey(), c.getCategoryName(), + c.getCoverageType(), c.getPlaceType(), 0)); + } else { + // 有placetype的 + AnalysisResourceCategoriesResult.PlaceType placeType = placeTypeMap.get(c.getPlaceTypeInAnalysis()); + if (placeType == null) { + placeType = new AnalysisResourceCategoriesResult.PlaceType( + c.getPlaceTypeInAnalysis(), CoveragePlaceTypeEnum.getEnum(c.getPlaceTypeInAnalysis()).getName(), 0, new ArrayList<>()); + placeTypeMap.put(c.getPlaceTypeInAnalysis(), placeType); + } + placeType.getCategories().add(new AnalysisResourceCategoriesResult.Category(c.getCategoryKey(), + c.getCategoryName(), c.getCoverageType(), c.getPlaceType(), 0)); + + placeType.setCount(placeType.getCount() + 0); // todo 0改为category的count + } + }); + + AtomicReference total = new AtomicReference<>(0); + placeTypeMap.forEach((placeTypeKey, placeType) -> { + categoriesOfThisCoverage.getPlaceTypesInAnalysis().add(placeType); + total.updateAndGet(v -> v + placeType.getCount()); + }); + + categoriesOfThisCoverage.setCoverageType(coverage.getCoverageType()); + categoriesOfThisCoverage.setCoverageName(CoverageEnums.getEnum(coverage.getCoverageType()).getCoverageName()); + categoriesOfThisCoverage.setCount(total.get()); + results.add(categoriesOfThisCoverage); + } + + return results; + } } \ No newline at end of file From 0be377f923c7285d53621130b768573de269cda7 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Wed, 27 Jul 2022 16:58:20 +0800 Subject: [PATCH 067/155] =?UTF-8?q?=E6=9C=AA=E5=AE=8C=E5=BE=85=E7=BB=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/epmet/entity/ServerInfoDTO.java | 15 +++++++ .../impl/IcUserDemandRecServiceImpl.java | 45 ++++++++++++++----- 2 files changed, 48 insertions(+), 12 deletions(-) create mode 100644 epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/entity/ServerInfoDTO.java diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/entity/ServerInfoDTO.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/entity/ServerInfoDTO.java new file mode 100644 index 0000000000..39bdd462f5 --- /dev/null +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/entity/ServerInfoDTO.java @@ -0,0 +1,15 @@ +package com.epmet.entity; + +import lombok.Data; + +/** + * @Description + * @Author yzm + * @Date 2022/7/27 16:23 + */ +@Data +public class ServerInfoDTO { + private String serviceName; + private String mobile; +} + diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java index c1acbcd859..9458f5ddff 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java @@ -414,11 +414,11 @@ public class IcUserDemandRecServiceImpl extends BaseServiceImpl Date: Wed, 27 Jul 2022 17:44:17 +0800 Subject: [PATCH 068/155] =?UTF-8?q?=E6=9F=A5=E8=A7=92=E8=89=B2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/epmet/dto/form/GovRoleListDTO.java | 49 +++++++++++++++++++ .../com/epmet/feign/GovAccessFeignClient.java | 9 ++-- .../GovAccessFeignClientFallBack.java | 11 +++-- .../epmet/controller/GovRoleController.java | 6 +++ .../main/java/com/epmet/dao/GovRoleDao.java | 2 + .../com/epmet/service/GovRoleService.java | 3 ++ .../service/impl/GovRoleServiceImpl.java | 6 +++ .../src/main/resources/mapper/GovRoleDao.xml | 12 +++++ 8 files changed, 90 insertions(+), 8 deletions(-) create mode 100644 epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/dto/form/GovRoleListDTO.java diff --git a/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/dto/form/GovRoleListDTO.java b/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/dto/form/GovRoleListDTO.java new file mode 100644 index 0000000000..7ff4de4670 --- /dev/null +++ b/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/dto/form/GovRoleListDTO.java @@ -0,0 +1,49 @@ +/** + * Copyright 2018 人人开源 https://www.renren.io + *

+ * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + *

+ * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + *

+ * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +package com.epmet.dto.form; + +import lombok.Data; + +import java.io.Serializable; +import java.util.Date; +import java.util.List; + + +/** + * 角色管理 + * + * @author generator generator@elink-cn.com + * @since v1.0.0 2020-03-18 + */ +@Data +public class GovRoleListDTO implements Serializable { + + private static final long serialVersionUID = 1L; + + /** + * 客户id + */ + private String customerId; + + /** + * 角色名称 + */ + private String name; + + +} \ No newline at end of file diff --git a/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/GovAccessFeignClient.java b/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/GovAccessFeignClient.java index 36ccf542bb..d5b6623ea8 100644 --- a/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/GovAccessFeignClient.java +++ b/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/GovAccessFeignClient.java @@ -2,10 +2,8 @@ package com.epmet.feign; import com.epmet.commons.tools.constant.ServiceConstant; import com.epmet.commons.tools.utils.Result; -import com.epmet.dto.form.GetStaffExistRoleFormDTO; -import com.epmet.dto.form.InitDefaultOperationsFormDTO; -import com.epmet.dto.form.ListOpePermsFormDTO; -import com.epmet.dto.form.RoleUserFormDTO; +import com.epmet.dto.GovRoleDTO; +import com.epmet.dto.form.*; import com.epmet.dto.result.NewUserRoleResultDTO; import com.epmet.feign.fallback.GovAccessFeignClientFallBackFactory; import org.springframework.cloud.openfeign.FeignClient; @@ -52,4 +50,7 @@ public interface GovAccessFeignClient { @PostMapping("/gov/access/govroleuser/getStaffExistRole") Result> getStaffExistRole(@RequestBody GetStaffExistRoleFormDTO formDTO); + @PostMapping("/gov/access/govrole/getgovrole") + Result getGovRole(@RequestBody GovRoleListDTO formDTO); + } diff --git a/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/fallback/GovAccessFeignClientFallBack.java b/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/fallback/GovAccessFeignClientFallBack.java index bfb9acbc3b..9fb58edf69 100644 --- a/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/fallback/GovAccessFeignClientFallBack.java +++ b/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/fallback/GovAccessFeignClientFallBack.java @@ -3,10 +3,8 @@ package com.epmet.feign.fallback; import com.epmet.commons.tools.constant.ServiceConstant; import com.epmet.commons.tools.utils.ModuleUtils; import com.epmet.commons.tools.utils.Result; -import com.epmet.dto.form.GetStaffExistRoleFormDTO; -import com.epmet.dto.form.InitDefaultOperationsFormDTO; -import com.epmet.dto.form.ListOpePermsFormDTO; -import com.epmet.dto.form.RoleUserFormDTO; +import com.epmet.dto.GovRoleDTO; +import com.epmet.dto.form.*; import com.epmet.dto.result.NewUserRoleResultDTO; import com.epmet.feign.GovAccessFeignClient; @@ -40,4 +38,9 @@ public class GovAccessFeignClientFallBack implements GovAccessFeignClient { public Result> getStaffExistRole(GetStaffExistRoleFormDTO formDTO) { return ModuleUtils.feignConError(ServiceConstant.GOV_ACCESS_SERVER, "getStaffExistRole", formDTO); } + + @Override + public Result getGovRole(GovRoleListDTO formDTO) { + return ModuleUtils.feignConError(ServiceConstant.GOV_ACCESS_SERVER, "getGovRole", formDTO); + } } diff --git a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/controller/GovRoleController.java b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/controller/GovRoleController.java index c11faba160..0159a8d891 100644 --- a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/controller/GovRoleController.java +++ b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/controller/GovRoleController.java @@ -27,6 +27,7 @@ import com.epmet.commons.tools.validator.group.AddGroup; import com.epmet.commons.tools.validator.group.DefaultGroup; import com.epmet.commons.tools.validator.group.UpdateGroup; import com.epmet.dto.GovRoleDTO; +import com.epmet.dto.form.GovRoleListDTO; import com.epmet.service.GovRoleMenuService; import com.epmet.service.GovRoleService; import org.springframework.beans.factory.annotation.Autowired; @@ -102,4 +103,9 @@ public class GovRoleController { return new Result>().ok(data); } + @PostMapping("getgovrole") + public Result getGovRole(@RequestBody GovRoleListDTO fromDTO){ + return new Result().ok(govRoleService.getGovRole(fromDTO)); + } + } diff --git a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/dao/GovRoleDao.java b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/dao/GovRoleDao.java index 526dbf9b37..a70c839a63 100644 --- a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/dao/GovRoleDao.java +++ b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/dao/GovRoleDao.java @@ -9,6 +9,7 @@ package com.epmet.dao; import com.epmet.commons.mybatis.dao.BaseDao; +import com.epmet.dto.GovRoleDTO; import com.epmet.dto.result.NewUserRoleResultDTO; import com.epmet.entity.GovRoleEntity; import org.apache.ibatis.annotations.Mapper; @@ -33,4 +34,5 @@ public interface GovRoleDao extends BaseDao { */ List getCustomerRoles(@Param("customerId")String customerId); + GovRoleDTO selectGovRole(@Param("customerId") String customerId, @Param("name") String name); } diff --git a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/GovRoleService.java b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/GovRoleService.java index 4fbf7e0f58..b7ca62a420 100644 --- a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/GovRoleService.java +++ b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/GovRoleService.java @@ -20,6 +20,7 @@ package com.epmet.service; import com.epmet.commons.mybatis.service.BaseService; import com.epmet.commons.tools.page.PageData; import com.epmet.dto.GovRoleDTO; +import com.epmet.dto.form.GovRoleListDTO; import com.epmet.entity.GovRoleEntity; import java.util.List; @@ -92,4 +93,6 @@ public interface GovRoleService extends BaseService { * @date 2020-03-18 */ void delete(String[] ids); + + GovRoleDTO getGovRole(GovRoleListDTO fromDTO); } \ No newline at end of file diff --git a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovRoleServiceImpl.java b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovRoleServiceImpl.java index 72a542c9e7..c171d081d9 100644 --- a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovRoleServiceImpl.java +++ b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovRoleServiceImpl.java @@ -28,6 +28,7 @@ import com.epmet.commons.tools.security.user.LoginUserUtil; import com.epmet.commons.tools.utils.ConvertUtils; import com.epmet.dao.GovRoleDao; import com.epmet.dto.GovRoleDTO; +import com.epmet.dto.form.GovRoleListDTO; import com.epmet.entity.GovRoleEntity; import com.epmet.redis.GovRoleRedis; import com.epmet.service.GovRoleMenuService; @@ -122,4 +123,9 @@ public class GovRoleServiceImpl extends BaseServiceImpl + + + From a209553d82fac426d5770d68a734a3523e7e0cef Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Wed, 27 Jul 2022 18:13:49 +0800 Subject: [PATCH 069/155] =?UTF-8?q?=E6=8C=87=E6=B4=BE=E9=9C=80=E6=B1=82?= =?UTF-8?q?=E5=8F=91=E7=9F=AD=E4=BF=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../impl/IcUserDemandRecServiceImpl.java | 21 ++++++++-- .../com/epmet/dto/form/SendSmsFormDTO.java | 42 +++++++++++++++++++ .../feign/EpmetMessageOpenFeignClient.java | 8 +++- .../EpmetMessageOpenFeignClientFallback.java | 5 +++ .../com/epmet/controller/SmsController.java | 14 +++++++ .../java/com/epmet/service/SysSmsService.java | 2 + .../epmet/service/impl/SysSmsServiceImpl.java | 30 ++++++++++++- ...em_zhzl.sql => V0.0.35__formitem_zhzl.sql} | 0 8 files changed, 116 insertions(+), 6 deletions(-) create mode 100644 epmet-module/epmet-message/epmet-message-client/src/main/java/com/epmet/dto/form/SendSmsFormDTO.java rename epmet-module/oper-customize/oper-customize-server/src/main/resources/db/migration/{V0.0.34__formitem_zhzl.sql => V0.0.35__formitem_zhzl.sql} (100%) diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java index 9458f5ddff..b85121ff68 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java @@ -43,6 +43,7 @@ import com.epmet.commons.tools.utils.DateUtils; import com.epmet.commons.tools.utils.Result; import com.epmet.commons.tools.utils.ScanContentUtils; import com.epmet.constant.ReadFlagConstant; +import com.epmet.constant.SmsTemplateConstant; import com.epmet.constant.UserDemandConstant; import com.epmet.constant.UserMessageTypeConstant; import com.epmet.dao.IcUserDemandOperateLogDao; @@ -431,7 +432,7 @@ public class IcUserDemandRecServiceImpl extends BaseServiceImpl smsList=new ArrayList<>(); + SendSmsFormDTO sms = new SendSmsFormDTO(); + sms.setCustomerId(customerId); + sms.setMobile(mobile); + sms.setAliyunTemplateCode(SmsTemplateConstant.PROJECT_TRANSFER); + List paramsContent=new ArrayList<>(); + paramsContent.add(String.format("%s给您指派了一个新的需求,请查看",staffInfoCacheResult.getAgencyName())); + sms.setParamsContent(paramsContent); + smsList.add(sms); + messageOpenFeignClient.sendMsg(smsList); + } /** diff --git a/epmet-module/epmet-message/epmet-message-client/src/main/java/com/epmet/dto/form/SendSmsFormDTO.java b/epmet-module/epmet-message/epmet-message-client/src/main/java/com/epmet/dto/form/SendSmsFormDTO.java new file mode 100644 index 0000000000..ee2802f691 --- /dev/null +++ b/epmet-module/epmet-message/epmet-message-client/src/main/java/com/epmet/dto/form/SendSmsFormDTO.java @@ -0,0 +1,42 @@ +package com.epmet.dto.form; + +import com.epmet.commons.tools.validator.group.CustomerClientShowGroup; +import lombok.Data; + +import javax.validation.constraints.NotBlank; +import java.io.Serializable; +import java.util.List; + +/** + * @Description + * @Author yzm + * @Date 2022/7/27 17:23 + */ +@Data +public class SendSmsFormDTO implements Serializable { + public interface AddUserInternalGroup { + } + + public interface AddUserShowGroup extends CustomerClientShowGroup { + } + + /** + * 手机号 + */ + @NotBlank(message = "手机号不能为空", groups = {AddUserShowGroup.class}) + private String mobile; + + /** + * 场景: + */ + @NotBlank(message = "短信模板编码不能为空", groups = {AddUserInternalGroup.class}) + private String aliyunTemplateCode; + + /** + * 如果短信模板内有参数,按序传入 + */ + private List paramsContent; + + private String customerId; +} + diff --git a/epmet-module/epmet-message/epmet-message-client/src/main/java/com/epmet/feign/EpmetMessageOpenFeignClient.java b/epmet-module/epmet-message/epmet-message-client/src/main/java/com/epmet/feign/EpmetMessageOpenFeignClient.java index 920d508b89..447111aca6 100644 --- a/epmet-module/epmet-message/epmet-message-client/src/main/java/com/epmet/feign/EpmetMessageOpenFeignClient.java +++ b/epmet-module/epmet-message/epmet-message-client/src/main/java/com/epmet/feign/EpmetMessageOpenFeignClient.java @@ -21,8 +21,8 @@ import java.util.List; * @author yinzuomei@elink-cn.com * @date 2020/6/4 13:47 */ -//@FeignClient(name = ServiceConstant.EPMET_MESSAGE_SERVER, fallbackFactory = EpmetMessageOpenFeignClientFallbackFactory.class, url = "http://127.0.0.1:8085") -@FeignClient(name = ServiceConstant.EPMET_MESSAGE_SERVER, fallbackFactory = EpmetMessageOpenFeignClientFallbackFactory.class) +@FeignClient(name = ServiceConstant.EPMET_MESSAGE_SERVER, fallbackFactory = EpmetMessageOpenFeignClientFallbackFactory.class, url = "http://127.0.0.1:8085") +// @FeignClient(name = ServiceConstant.EPMET_MESSAGE_SERVER, fallbackFactory = EpmetMessageOpenFeignClientFallbackFactory.class) public interface EpmetMessageOpenFeignClient { /** * 发送短信 @@ -123,4 +123,8 @@ public interface EpmetMessageOpenFeignClient { */ @PostMapping("/message/system/pendding-mq-msg-scan") Result penddingMqMsgScan(); + + + @PostMapping(value = "message/sms/send-msg", consumes = MediaType.APPLICATION_JSON_UTF8_VALUE) + Result sendMsg(@RequestBody List formDTO); } diff --git a/epmet-module/epmet-message/epmet-message-client/src/main/java/com/epmet/feign/fallback/EpmetMessageOpenFeignClientFallback.java b/epmet-module/epmet-message/epmet-message-client/src/main/java/com/epmet/feign/fallback/EpmetMessageOpenFeignClientFallback.java index eba096ff0f..2d5c0d9073 100644 --- a/epmet-module/epmet-message/epmet-message-client/src/main/java/com/epmet/feign/fallback/EpmetMessageOpenFeignClientFallback.java +++ b/epmet-module/epmet-message/epmet-message-client/src/main/java/com/epmet/feign/fallback/EpmetMessageOpenFeignClientFallback.java @@ -73,4 +73,9 @@ public class EpmetMessageOpenFeignClientFallback implements EpmetMessageOpenFeig public Result penddingMqMsgScan() { return ModuleUtils.feignConError(ServiceConstant.EPMET_MESSAGE_SERVER, "penddingMqMsgScan"); } + + @Override + public Result sendMsg(List formDTO) { + return ModuleUtils.feignConError(ServiceConstant.EPMET_MESSAGE_SERVER, "sendMsg",formDTO); + } } diff --git a/epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/controller/SmsController.java b/epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/controller/SmsController.java index c41ad3195d..47684b67c7 100644 --- a/epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/controller/SmsController.java +++ b/epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/controller/SmsController.java @@ -16,6 +16,7 @@ import com.epmet.commons.tools.validator.group.AliyunGroup; import com.epmet.commons.tools.validator.group.QcloudGroup; import com.epmet.dto.SysSmsDTO; import com.epmet.dto.form.ProjectSendMsgFormDTO; +import com.epmet.dto.form.SendSmsFormDTO; import com.epmet.dto.form.SendVerificationCodeFormDTO; import com.epmet.dto.result.SendVerificationCodeResultDTO; import com.epmet.enums.PlatformEnum; @@ -128,4 +129,17 @@ public class SmsController { return new Result(); } + /** + * 通用发短信方法,传入短信模板,内容 + * + * @param formDTOList + * @return + */ + @PostMapping("send-msg") + public Result sendMsg(@RequestBody List formDTOList) { + ValidatorUtils.validateEntity(formDTOList, SendSmsFormDTO.AddUserShowGroup.class, SendSmsFormDTO.AddUserInternalGroup.class); + sysSmsService.sendMsg(formDTOList); + return new Result(); + } + } diff --git a/epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/service/SysSmsService.java b/epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/service/SysSmsService.java index 1327aff692..0025768d94 100644 --- a/epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/service/SysSmsService.java +++ b/epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/service/SysSmsService.java @@ -13,6 +13,7 @@ import com.epmet.commons.tools.page.PageData; import com.epmet.commons.tools.utils.Result; import com.epmet.dto.SysSmsDTO; import com.epmet.dto.form.ProjectSendMsgFormDTO; +import com.epmet.dto.form.SendSmsFormDTO; import com.epmet.dto.form.SendVerificationCodeFormDTO; import com.epmet.dto.result.SendVerificationCodeResultDTO; import com.epmet.entity.SysSmsEntity; @@ -77,5 +78,6 @@ public interface SysSmsService extends BaseService { **/ void projectSendMsg(List formDTOList); + void sendMsg(List formDTOList); } diff --git a/epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/service/impl/SysSmsServiceImpl.java b/epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/service/impl/SysSmsServiceImpl.java index 1fc41bc718..ee4c3be657 100644 --- a/epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/service/impl/SysSmsServiceImpl.java +++ b/epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/service/impl/SysSmsServiceImpl.java @@ -13,6 +13,7 @@ import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; import com.epmet.commons.mybatis.service.impl.BaseServiceImpl; import com.epmet.commons.tools.constant.Constant; +import com.epmet.commons.tools.constant.NumConstant; import com.epmet.commons.tools.exception.EpmetErrorCode; import com.epmet.commons.tools.exception.ErrorCode; import com.epmet.commons.tools.exception.RenException; @@ -25,6 +26,7 @@ import com.epmet.dao.SysSmsDao; import com.epmet.dto.SysSmsDTO; import com.epmet.dto.form.CrmParameterFormDTO; import com.epmet.dto.form.ProjectSendMsgFormDTO; +import com.epmet.dto.form.SendSmsFormDTO; import com.epmet.dto.form.SendVerificationCodeFormDTO; import com.epmet.dto.result.CrmParameterResultDTO; import com.epmet.dto.result.SendVerificationCodeResultDTO; @@ -323,7 +325,33 @@ public class SysSmsServiceImpl extends BaseServiceImpl service.sendSmsMsg(sysSmsDTO); } } catch (Exception e) { - logger.warn(String.format("项目提醒发送短信失败,失败手机号:%s,ErrorCode:%s", sysSmsDTO.getMobile(), e.getMessage())); + logger.warn(String.format("发送短信失败,失败手机号:%s,ErrorCode:%s", sysSmsDTO.getMobile(), e.getMessage())); + } + } + + @Override + public void sendMsg(List formDTOList) { + try { + for(SendSmsFormDTO formDTO:formDTOList){ + SysSmsDTO sysSmsDTO = new SysSmsDTO(); + sysSmsDTO.setMobile(formDTO.getMobile()); + sysSmsDTO.setAliyunTemplateCode(formDTO.getAliyunTemplateCode()); + sysSmsDTO.setCustomerId(formDTO.getCustomerId()); + HashMap map = new HashMap<>(); + try{ + if(SmsTemplateConstant.PROJECT_TRANSFER.equals(formDTO.getAliyunTemplateCode())){ + map.put("params1", formDTO.getParamsContent().get(NumConstant.ZERO)); + } + String paramJson = new ObjectMapper().writeValueAsString(map); + sysSmsDTO.setParams(paramJson); + } catch (JsonProcessingException e) { + log.warn("sendMsg JsonProcessingException", e); + } + //推送短信 + this.sendMsg(sysSmsDTO); + } + } catch (Exception e) { + logger.error("sendMsg exception", e); } } diff --git a/epmet-module/oper-customize/oper-customize-server/src/main/resources/db/migration/V0.0.34__formitem_zhzl.sql b/epmet-module/oper-customize/oper-customize-server/src/main/resources/db/migration/V0.0.35__formitem_zhzl.sql similarity index 100% rename from epmet-module/oper-customize/oper-customize-server/src/main/resources/db/migration/V0.0.34__formitem_zhzl.sql rename to epmet-module/oper-customize/oper-customize-server/src/main/resources/db/migration/V0.0.35__formitem_zhzl.sql From 7be9b70e2253e3c7d3cdedda4121891fad6047fd Mon Sep 17 00:00:00 2001 From: wangxianzhang Date: Thu, 28 Jul 2022 00:10:39 +0800 Subject: [PATCH 070/155] =?UTF-8?q?=E3=80=90=E5=9B=BE=E5=B1=82=E3=80=91?= =?UTF-8?q?=E5=B7=A6=E4=BE=A7=E8=BF=98=E5=B7=AE=E5=85=AC=E5=85=B1=E6=9C=8D?= =?UTF-8?q?=E5=8A=A1=E4=BA=BA=E7=BE=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../commons/tools/enums/CoverageEnums.java | 52 ++++++++++------- .../tools/enums/CoveragePlaceTypeEnum.java | 4 +- .../AnalysisGovernedTargetsResult.java | 25 ++++++++ .../controller/CoverageController.java | 11 ++++ .../govorg/IcCoverageCategoryDictEntity.java | 2 + .../dataaggre/service/CoverageService.java | 3 + .../service/govorg/GovOrgCoverageService.java | 4 +- .../impl/GovOrgCoverageServiceImpl.java | 13 ++++- .../service/impl/CoverageServiceImpl.java | 57 +++++++++++++++++-- .../govorg/IcCoverageCategoryDictDao.xml | 1 + .../entity/IcCoverageCategoryDictEntity.java | 2 + 11 files changed, 144 insertions(+), 30 deletions(-) create mode 100644 epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/coverage/AnalysisGovernedTargetsResult.java diff --git a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoverageEnums.java b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoverageEnums.java index 0e2e749b16..02f5504d6a 100644 --- a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoverageEnums.java +++ b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoverageEnums.java @@ -6,42 +6,50 @@ package com.epmet.commons.tools.enums; public enum CoverageEnums { ZHZL("zhzl", "综合治理图层", 1), - YJCL("yjcl", "应急处置资源", 2), - AQSC("aqsc", "安全生产资源", 2), - CSGL("csgl", "城市管理资源", 2), - GGFW("ggfw", "公共服务资源", 2); - - private String coverageType; - private String coverageName; - - /** 位置,1:左侧,2,右侧**/ - private Integer position; - - CoverageEnums(String coverageType, String coverageName, Integer position) { - this.coverageType = coverageType; - this.coverageName = coverageName; - this.position = position; + YJCL("yjcl", "应急处置资源", 1), + AQSC("aqsc", "安全生产资源", 1), + CSGL("csgl", "城市管理资源", 1), + GGFW("ggfw", "公共服务资源", 1), + + DATA_TYPE_GOVERNED_TARGET("governedTarget", "被管理对象", 2), + DATA_TYPE_RESOURCES("resources", "资源", 2); + + private String key; + private String name; + /** + * 1:图层,2:数据类型 + */ + private Integer type; + + CoverageEnums(String key, String name, Integer type) { + this.key = key; + this.name = name; + this.type = type; } - public static CoverageEnums getEnum(String coverageType) { + public static CoverageEnums getEnum(String key) { CoverageEnums[] values = CoverageEnums.values(); for (CoverageEnums value : values) { - if (value.getCoverageType().equals(coverageType)) { + if (value.getKey().equals(key)) { return value; } } return null; } - public String getCoverageType() { - return coverageType; + public String getKey() { + return key; } public String getCoverageName() { - return coverageName; + return name; + } + + public String getName() { + return name; } - public Integer getPosition() { - return position; + public Integer getType() { + return type; } } diff --git a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoveragePlaceTypeEnum.java b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoveragePlaceTypeEnum.java index dbad5fa3c2..3e68bf0503 100644 --- a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoveragePlaceTypeEnum.java +++ b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoveragePlaceTypeEnum.java @@ -8,6 +8,7 @@ public enum CoveragePlaceTypeEnum { SUPERIOR_RESOURCE("superior_resource", "优势资源"), DANGEROUS_CHEMICALS("dangerous_chemicals", "重点危化企业"), ENTERPRISE_PATROL("enterprise_patrol", "企事业单位巡查"), + ENTERPRISE_PATROL_UNQUALIFIED("enterprise_patrol_unqualified", "安全生产隐患"), SPECIAL_RESI("special_resi", "特殊人群"), CITY_MANAGEMENT("city_management", "城市管理"), COMMUNITY_ORG("community_org", "社区自组织"), @@ -16,7 +17,8 @@ public enum CoveragePlaceTypeEnum { PARTY_UNIT("party_unit", "联建单位"), VOLUNTEER("volunteer", "志愿者"), GROUP_RENT("group_rent", "群租房"), - EVENT("event", "事件(包括难点堵点)"); + EVENT("event", "事件(包括难点堵点)"), + ZHZL_RQ("zhzl_rq", "综合治理人群"); private final String code; private final String name; diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/coverage/AnalysisGovernedTargetsResult.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/coverage/AnalysisGovernedTargetsResult.java new file mode 100644 index 0000000000..56988054ba --- /dev/null +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/coverage/AnalysisGovernedTargetsResult.java @@ -0,0 +1,25 @@ +package com.epmet.dataaggre.dto.coverage; + +import lombok.AllArgsConstructor; +import lombok.Data; +import lombok.NoArgsConstructor; + +import java.util.List; + +/** + * 五大图层分析-被管理对象分类 + */ +@Data +@NoArgsConstructor +@AllArgsConstructor +public class AnalysisGovernedTargetsResult { + + private String categoryKey; + private String categoryName; + private String coverageType; + private String placeType; + private String placeTypeName; + private Integer count = 0; + + private List children; +} diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java index fa68116993..67a4b52d04 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java @@ -6,6 +6,7 @@ import com.epmet.commons.tools.enums.ZhzlResiCategoryEnum; import com.epmet.commons.tools.page.PageData; import com.epmet.commons.tools.security.dto.TokenDto; import com.epmet.commons.tools.utils.Result; +import com.epmet.dataaggre.dto.coverage.AnalysisGovernedTargetsResult; import com.epmet.dataaggre.dto.coverage.AnalysisResourceCategoriesResult; import com.epmet.dataaggre.dto.govorg.form.CoverageAnalisisDataListFormDTO; import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; @@ -83,4 +84,14 @@ public class CoverageController { return new Result>().ok(r); } + /** + * 被管理对象分类列表 + * @return + */ + @PostMapping("analysis/governedTargetCategories") + public Result> listGovernedTargetCategories() { + List r = coverageService.listGovernedTargetCategories(); + return new Result>().ok(r); + } + } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCoverageCategoryDictEntity.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCoverageCategoryDictEntity.java index dee38b469f..bc0ae5c9e2 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCoverageCategoryDictEntity.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCoverageCategoryDictEntity.java @@ -58,6 +58,8 @@ public class IcCoverageCategoryDictEntity extends BaseEpmetEntity { */ private String coverageType; + private String dataType; + /** * 排序 */ diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java index f372f2699c..651655f2e3 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java @@ -1,6 +1,7 @@ package com.epmet.dataaggre.service; import com.epmet.commons.tools.page.PageData; +import com.epmet.dataaggre.dto.coverage.AnalysisGovernedTargetsResult; import com.epmet.dataaggre.dto.coverage.AnalysisResourceCategoriesResult; import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; import com.epmet.dataaggre.dto.govorg.result.CoverageAnalisisDataListResultDTO; @@ -37,4 +38,6 @@ public interface CoverageService { * @return */ List listAnalysisResourceCategories(); + + List listGovernedTargetCategories(); } \ No newline at end of file diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java index 8168721b71..7b1779be57 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java @@ -138,5 +138,7 @@ public interface GovOrgCoverageService { */ IcCoverageCategoryDictEntity selectByCategoryKey(String categoryKey); - List listCoverageCategoryEntities(String coverageType); + List listResourceCategoryEntities(String coverageType); + + List listGovernedTargetCategoryEntities(); } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java index 2f39da60a4..bc64607a7f 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java @@ -3,6 +3,7 @@ package com.epmet.dataaggre.service.govorg.impl; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.epmet.commons.dynamic.datasource.annotation.DataSource; +import com.epmet.commons.tools.enums.CoverageEnums; import com.epmet.commons.tools.utils.EpmetRequestHolder; import com.epmet.dataaggre.constant.DataSourceConstant; import com.epmet.dataaggre.dao.govorg.*; @@ -326,11 +327,21 @@ public class GovOrgCoverageServiceImpl implements GovOrgCoverageService { } @Override - public List listCoverageCategoryEntities(String coverageType) { + public List listResourceCategoryEntities(String coverageType) { LambdaQueryWrapper query = new LambdaQueryWrapper<>(); query.eq(IcCoverageCategoryDictEntity::getCustomerId, EpmetRequestHolder.getLoginUserCustomerId()); query.eq(IcCoverageCategoryDictEntity::getCoverageType, coverageType); query.orderByAsc(IcCoverageCategoryDictEntity::getSort); + query.eq(IcCoverageCategoryDictEntity::getDataType, CoverageEnums.DATA_TYPE_RESOURCES.getKey()); + return coverageCategoryDictDao.selectList(query); + } + + @Override + public List listGovernedTargetCategoryEntities() { + LambdaQueryWrapper query = new LambdaQueryWrapper<>(); + query.eq(IcCoverageCategoryDictEntity::getCustomerId, EpmetRequestHolder.getLoginUserCustomerId()); + query.orderByAsc(IcCoverageCategoryDictEntity::getSort); + query.eq(IcCoverageCategoryDictEntity::getDataType, CoverageEnums.DATA_TYPE_GOVERNED_TARGET.getKey()); return coverageCategoryDictDao.selectList(query); } } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index dfae8be881..3f09b04d77 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -9,6 +9,7 @@ import com.epmet.commons.tools.page.PageData; import com.epmet.commons.tools.redis.common.CustomerStaffRedis; import com.epmet.commons.tools.redis.common.bean.BuildingInfoCache; import com.epmet.commons.tools.utils.EpmetRequestHolder; +import com.epmet.dataaggre.dto.coverage.AnalysisGovernedTargetsResult; import com.epmet.dataaggre.dto.coverage.AnalysisResourceCategoriesResult; import com.epmet.dataaggre.dto.epmetuser.result.IcResiInfoResultDTO; import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; @@ -26,6 +27,7 @@ import com.epmet.dataaggre.service.govorg.GovOrgCoverageService; import com.epmet.dataaggre.service.govorg.GovOrgService; import com.epmet.dataaggre.service.govproject.GovProjectService; import com.epmet.dataaggre.service.heart.HeartService; +import jodd.util.StringUtil; import lombok.extern.slf4j.Slf4j; import org.apache.commons.collections4.CollectionUtils; import org.apache.commons.lang3.StringUtils; @@ -474,15 +476,18 @@ public class CoverageServiceImpl implements CoverageService { // 1.查询categoryDict表得到基础数据,每个图层循环一次 for (CoverageEnums coverage : CoverageEnums.values()) { - // 只要右边的 - if (!coverage.getPosition().equals(Integer.valueOf(2))) { + if (!coverage.getType().equals(1)) { continue; } AnalysisResourceCategoriesResult categoriesOfThisCoverage = new AnalysisResourceCategoriesResult(); HashMap placeTypeMap = new HashMap<>(); - List categoryDictEntities = govOrgCoverageService.listCoverageCategoryEntities(coverage.getCoverageType()); + List categoryDictEntities = govOrgCoverageService.listResourceCategoryEntities(coverage.getKey()); + + if (CollectionUtils.isEmpty(categoryDictEntities)) { + continue; + } // 2.根据menuUrl过滤 todo @@ -516,12 +521,54 @@ public class CoverageServiceImpl implements CoverageService { total.updateAndGet(v -> v + placeType.getCount()); }); - categoriesOfThisCoverage.setCoverageType(coverage.getCoverageType()); - categoriesOfThisCoverage.setCoverageName(CoverageEnums.getEnum(coverage.getCoverageType()).getCoverageName()); + categoriesOfThisCoverage.setCoverageType(coverage.getKey()); + categoriesOfThisCoverage.setCoverageName(CoverageEnums.getEnum(coverage.getKey()).getCoverageName()); categoriesOfThisCoverage.setCount(total.get()); results.add(categoriesOfThisCoverage); } return results; } + + @Override + public List listGovernedTargetCategories() { + List targetCategories = govOrgCoverageService.listGovernedTargetCategoryEntities(); + + if (CollectionUtils.isEmpty(targetCategories)) { + return new ArrayList<>(); + } + + List results = new ArrayList<>(); + HashMap> placeTypeMap = new HashMap<>(); + + targetCategories.forEach(rc -> { + String placeTypeInAnalysis = rc.getPlaceTypeInAnalysis(); + if (StringUtils.isEmpty(placeTypeInAnalysis)) { + // 只有一层,没有子级 + results.add(new AnalysisGovernedTargetsResult(rc.getCategoryKey(), rc.getCategoryName(), rc.getCoverageType(), + rc.getPlaceType(), CoveragePlaceTypeEnum.getEnum(rc.getPlaceType()).getName(), 0, new ArrayList<>())); + } else { + // 有子级,需要使用placeTypeInAnalysis分组 + List targets = placeTypeMap.get(placeTypeInAnalysis); + if (CollectionUtils.isEmpty(targets)) { + targets = new ArrayList<>(); + placeTypeMap.put(placeTypeInAnalysis, targets); + } + targets.add(new AnalysisGovernedTargetsResult(rc.getCategoryKey(), rc.getCategoryName(), rc.getCoverageType(), + rc.getPlaceType(), CoveragePlaceTypeEnum.getEnum(rc.getPlaceType()).getName(), 0, new ArrayList<>())); + } + }); + + if (placeTypeMap.size() > 0) { + placeTypeMap.forEach((placeTypeInAnalysis, targetObjects) -> { + AnalysisGovernedTargetsResult tr = new AnalysisGovernedTargetsResult(); + tr.setPlaceType(placeTypeInAnalysis); + tr.setPlaceTypeName(CoveragePlaceTypeEnum.getEnum(placeTypeInAnalysis).getName()); + tr.setChildren(targetObjects); + results.add(tr); + }); + } + + return results; + } } \ No newline at end of file diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryDictDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryDictDao.xml index 25c0704bbd..94da6bd60c 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryDictDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryDictDao.xml @@ -12,6 +12,7 @@ + diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcCoverageCategoryDictEntity.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcCoverageCategoryDictEntity.java index 13a31b9974..25a4e47299 100755 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcCoverageCategoryDictEntity.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcCoverageCategoryDictEntity.java @@ -61,6 +61,8 @@ public class IcCoverageCategoryDictEntity extends BaseEpmetEntity { */ private String coverageType; + private String dataType; + /** * 排序 */ From aafdf59d8b8b46a8bf91c04e3ae9c31f52d0248e Mon Sep 17 00:00:00 2001 From: wangxianzhang Date: Thu, 28 Jul 2022 09:24:40 +0800 Subject: [PATCH 071/155] =?UTF-8?q?=E3=80=90=E5=9B=BE=E5=B1=82=E3=80=91?= =?UTF-8?q?=E5=8F=AF=E8=A7=86=E5=8C=96=EF=BC=8C=E5=B7=A6=E4=BE=A7=E8=8F=9C?= =?UTF-8?q?=E5=8D=95=E5=8A=A0=E4=B8=8A=E4=BA=86=E5=85=AC=E5=85=B1=E6=9C=8D?= =?UTF-8?q?=E5=8A=A1=E4=BA=BA=E7=BE=A4,=E8=BF=98=E6=9C=89=E5=85=A8?= =?UTF-8?q?=E5=B1=80=E7=9A=84=E6=95=B0=E9=87=8F=E8=A6=81=E7=AE=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../IcResiCategoryWarnConfigDao.java | 9 ++ .../IcResiCategoryWarnConfigEntity.java | 86 +++++++++++++++++++ .../service/impl/CoverageServiceImpl.java | 20 +++++ .../IcResiCategoryWarnService.java | 9 ++ .../impl/IcResiCategoryWarnServiceImpl.java | 28 ++++++ .../IcResiCategoryWarnConfigDao.xml | 5 ++ 6 files changed, 157 insertions(+) create mode 100644 epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/opercustomize/IcResiCategoryWarnConfigDao.java create mode 100644 epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/opercustomize/IcResiCategoryWarnConfigEntity.java create mode 100644 epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/opercustomize/IcResiCategoryWarnService.java create mode 100644 epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/opercustomize/impl/IcResiCategoryWarnServiceImpl.java create mode 100644 epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/opercustomize/IcResiCategoryWarnConfigDao.xml diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/opercustomize/IcResiCategoryWarnConfigDao.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/opercustomize/IcResiCategoryWarnConfigDao.java new file mode 100644 index 0000000000..d826ee778c --- /dev/null +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/opercustomize/IcResiCategoryWarnConfigDao.java @@ -0,0 +1,9 @@ +package com.epmet.dataaggre.dao.opercustomize; + +import com.epmet.commons.mybatis.dao.BaseDao; +import com.epmet.dataaggre.entity.opercustomize.IcResiCategoryWarnConfigEntity; +import org.apache.ibatis.annotations.Mapper; + +@Mapper +public interface IcResiCategoryWarnConfigDao extends BaseDao { +} diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/opercustomize/IcResiCategoryWarnConfigEntity.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/opercustomize/IcResiCategoryWarnConfigEntity.java new file mode 100644 index 0000000000..0738f7e37a --- /dev/null +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/opercustomize/IcResiCategoryWarnConfigEntity.java @@ -0,0 +1,86 @@ +/** + * Copyright 2018 人人开源 https://www.renren.io + *

+ * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + *

+ * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + *

+ * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +package com.epmet.dataaggre.entity.opercustomize; + +import com.baomidou.mybatisplus.annotation.TableField; +import com.baomidou.mybatisplus.annotation.TableName; +import com.epmet.commons.mybatis.entity.BaseEpmetEntity; +import lombok.Data; +import lombok.EqualsAndHashCode; + +/** + * 居民类别预警配置表 + * + * @author generator generator@elink-cn.com + * @since v1.0.0 2021-11-04 + */ +@Data +@EqualsAndHashCode(callSuper=false) +@TableName("ic_resi_category_warn_config") +public class IcResiCategoryWarnConfigEntity extends BaseEpmetEntity { + + private static final long serialVersionUID = 1L; + + /** + * 客户id + */ + private String customerId; + + /** + * 项标签 + */ + private String label; + + /** + * 表名 + */ + private String tableName; + + /** + * 列名 + */ + private String columnName; + /** + * 是否预警 1 是 0 否 + */ + private String warn; + + /** + * 排序 + */ + private Integer sort; + + /** + * 等级1阈值 + */ + @TableField(value = "LEVEL_1") + private Integer level1; + + /** + * 等级2阈值 + */ + @TableField(value = "LEVEL_2") + private Integer level2; + + /** + * 等级3阈值 + */ + @TableField(value = "LEVEL_3") + private Integer level3; + +} diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index 3f09b04d77..dcc72dd756 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -21,12 +21,14 @@ import com.epmet.dataaggre.entity.govorg.*; import com.epmet.dataaggre.entity.govproject.IcEventEntity; import com.epmet.dataaggre.entity.heart.IcCommunitySelfOrganizationEntity; import com.epmet.dataaggre.entity.heart.IcPartyUnitEntity; +import com.epmet.dataaggre.entity.opercustomize.IcResiCategoryWarnConfigEntity; import com.epmet.dataaggre.service.CoverageService; import com.epmet.dataaggre.service.epmetuser.IcResiService; import com.epmet.dataaggre.service.govorg.GovOrgCoverageService; import com.epmet.dataaggre.service.govorg.GovOrgService; import com.epmet.dataaggre.service.govproject.GovProjectService; import com.epmet.dataaggre.service.heart.HeartService; +import com.epmet.dataaggre.service.opercustomize.IcResiCategoryWarnService; import jodd.util.StringUtil; import lombok.extern.slf4j.Slf4j; import org.apache.commons.collections4.CollectionUtils; @@ -63,6 +65,9 @@ public class CoverageServiceImpl implements CoverageService { @Autowired private GovOrgCoverageService govOrgCoverageService; + @Autowired + private IcResiCategoryWarnService icResiCategoryWarnService; + /** * 场所类型常量 */ @@ -532,6 +537,8 @@ public class CoverageServiceImpl implements CoverageService { @Override public List listGovernedTargetCategories() { + + // 1.从表中取数据出来 List targetCategories = govOrgCoverageService.listGovernedTargetCategoryEntities(); if (CollectionUtils.isEmpty(targetCategories)) { @@ -569,6 +576,19 @@ public class CoverageServiceImpl implements CoverageService { }); } + //2.从oper_customize.ic_resi_category_warn_config表中取18大类居民中需要预警的类出来 + List categoriesNeed2Warn = icResiCategoryWarnService.listResiCategoriesNeed2Warn(EpmetRequestHolder.getLoginUserCustomerId()); + List ggfwrqCategories = categoriesNeed2Warn.stream().map(wc -> + new AnalysisGovernedTargetsResult(wc.getColumnName(), wc.getTableName(), + CoverageEnums.GGFW.getKey(), CoveragePlaceTypeEnum.RESI.getCode(), CoveragePlaceTypeEnum.RESI.getCode(), + 0, new ArrayList<>())).collect(Collectors.toList()); + + AnalysisGovernedTargetsResult ggfwRq = new AnalysisGovernedTargetsResult(); + ggfwRq.setPlaceType(CoveragePlaceTypeEnum.RESI.getCode()); + ggfwRq.setPlaceTypeName(CoveragePlaceTypeEnum.RESI.getName()); + ggfwRq.setChildren(ggfwrqCategories); + + results.add(ggfwRq); return results; } } \ No newline at end of file diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/opercustomize/IcResiCategoryWarnService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/opercustomize/IcResiCategoryWarnService.java new file mode 100644 index 0000000000..85b43f948a --- /dev/null +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/opercustomize/IcResiCategoryWarnService.java @@ -0,0 +1,9 @@ +package com.epmet.dataaggre.service.opercustomize; + +import com.epmet.dataaggre.entity.opercustomize.IcResiCategoryWarnConfigEntity; + +import java.util.List; + +public interface IcResiCategoryWarnService { + List listResiCategoriesNeed2Warn(String loginUserCustomerId); +} diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/opercustomize/impl/IcResiCategoryWarnServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/opercustomize/impl/IcResiCategoryWarnServiceImpl.java new file mode 100644 index 0000000000..c3e52bacec --- /dev/null +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/opercustomize/impl/IcResiCategoryWarnServiceImpl.java @@ -0,0 +1,28 @@ +package com.epmet.dataaggre.service.opercustomize.impl; + +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; +import com.epmet.commons.dynamic.datasource.annotation.DataSource; +import com.epmet.dataaggre.constant.DataSourceConstant; +import com.epmet.dataaggre.dao.opercustomize.IcResiCategoryWarnConfigDao; +import com.epmet.dataaggre.entity.opercustomize.IcResiCategoryWarnConfigEntity; +import com.epmet.dataaggre.service.opercustomize.IcResiCategoryWarnService; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; + +import java.util.List; + +@Service +@DataSource(DataSourceConstant.OPERCUSTOMIZE) +public class IcResiCategoryWarnServiceImpl implements IcResiCategoryWarnService { + + @Autowired + private IcResiCategoryWarnConfigDao icResiCategoryWarnConfigDao; + + @Override + public List listResiCategoriesNeed2Warn(String customerId) { + LambdaQueryWrapper query = new LambdaQueryWrapper<>(); + query.eq(IcResiCategoryWarnConfigEntity::getCustomerId, customerId); + query.eq(IcResiCategoryWarnConfigEntity::getWarn, "1"); + return icResiCategoryWarnConfigDao.selectList(query); + } +} diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/opercustomize/IcResiCategoryWarnConfigDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/opercustomize/IcResiCategoryWarnConfigDao.xml new file mode 100644 index 0000000000..0da1fddf73 --- /dev/null +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/opercustomize/IcResiCategoryWarnConfigDao.xml @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file From dc78b8884340ad19af1a1f0369d0fa30451dd3d7 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Thu, 28 Jul 2022 10:09:46 +0800 Subject: [PATCH 072/155] 11 --- .../com/epmet/service/impl/IcUserDemandRecServiceImpl.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java index b85121ff68..1e2784349f 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java @@ -441,6 +441,9 @@ public class IcUserDemandRecServiceImpl extends BaseServiceImpl Date: Thu, 28 Jul 2022 10:49:57 +0800 Subject: [PATCH 073/155] =?UTF-8?q?=E8=81=94=E5=BB=BA=E5=8D=95=E4=BD=8D?= =?UTF-8?q?=E3=80=81=E7=A4=BE=E4=BC=9A=E8=87=AA=E7=BB=84=E7=BB=87=E5=90=8C?= =?UTF-8?q?=E6=AD=A5=E5=88=B0=E9=80=9A=E8=AE=AF=E5=BD=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dto/IcCommunitySelfOrganizationDTO.java | 15 ++ .../java/com/epmet/dto/IcPartyUnitDTO.java | 15 ++ .../feign/EpmetHeartOpenFeignClient.java | 5 + .../EpmetHeartOpenFeignClientFallback.java | 6 + .../controller/IcPartyUnitController.java | 16 +- .../IcCommunitySelfOrganizationEntity.java | 15 ++ .../com/epmet/entity/IcPartyUnitEntity.java | 15 ++ .../com/epmet/service/IcPartyUnitService.java | 7 +- .../service/impl/IcPartyUnitServiceImpl.java | 30 ++++ .../epmet/dto/form/AddDepartmentFormDTO.java | 5 + .../epmet/dto/form/CheckStaffInfoFormDTO.java | 37 ++++- .../epmet/dto/form/StaffSubmitFromDTO.java | 6 + .../dto/result/CheckStaffInfoResultDTO.java | 37 ++++- .../controller/DepartmentController.java | 17 +- .../com/epmet/service/DepartmentService.java | 2 + .../service/impl/DepartmentServiceImpl.java | 150 ++++++++++++++++-- .../epmet/feign/EpmetUserOpenFeignClient.java | 6 + .../EpmetUserOpenFeignClientFallback.java | 10 ++ .../controller/CustomerStaffController.java | 12 ++ .../java/com/epmet/dao/CustomerStaffDao.java | 2 + .../epmet/service/CustomerStaffService.java | 4 + .../impl/CustomerStaffServiceImpl.java | 30 ++++ .../resources/mapper/CustomerStaffDao.xml | 11 ++ 23 files changed, 421 insertions(+), 32 deletions(-) diff --git a/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/IcCommunitySelfOrganizationDTO.java b/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/IcCommunitySelfOrganizationDTO.java index 6364dc08e2..a8cad6d0f6 100644 --- a/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/IcCommunitySelfOrganizationDTO.java +++ b/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/IcCommunitySelfOrganizationDTO.java @@ -104,6 +104,21 @@ public class IcCommunitySelfOrganizationDTO implements Serializable { */ private String latitude; + /** + * 同步状态【已同步:sync 未同步:not_sync】 + */ + private String syncType; + + /** + * 部门ID customer_department.id + */ + private String deptId; + + /** + * 部门下工作人员Id + */ + private String deptStaffId; + /** * */ diff --git a/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/IcPartyUnitDTO.java b/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/IcPartyUnitDTO.java index 2258b94762..5935d564de 100644 --- a/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/IcPartyUnitDTO.java +++ b/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/IcPartyUnitDTO.java @@ -134,6 +134,21 @@ public class IcPartyUnitDTO implements Serializable { */ private String remark; + /** + * 同步状态【已同步:sync 未同步:not_sync】 + */ + private String syncType; + + /** + * 部门ID customer_department.id + */ + private String deptId; + + /** + * 部门下工作人员Id + */ + private String deptStaffId; + /** * 删除标识 0未删除、1已删除 */ diff --git a/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/feign/EpmetHeartOpenFeignClient.java b/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/feign/EpmetHeartOpenFeignClient.java index 9939b88455..e3b04df7bb 100644 --- a/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/feign/EpmetHeartOpenFeignClient.java +++ b/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/feign/EpmetHeartOpenFeignClient.java @@ -16,6 +16,7 @@ import com.epmet.dto.form.demand.UserDemandNameQueryFormDTO; import com.epmet.dto.form.resi.ResiVolunteerAuthenticateFormDTO; import com.epmet.dto.form.resi.ResisByPolicyRulesFormDTO; import com.epmet.dto.form.resi.VolunteerCommonFormDTO; +import com.epmet.dto.result.CheckStaffInfoResultDTO; import com.epmet.dto.result.PartyUnitListResultDTO; import com.epmet.dto.result.demand.IcResiDemandDictDTO; import com.epmet.dto.result.resi.PageVolunteerInfoResultDTO; @@ -166,4 +167,8 @@ public interface EpmetHeartOpenFeignClient { */ @PostMapping("/heart/policy/rules4ResiListAndExport/{ruleId}") Result listPolicyRules4QueryAndExport(@PathVariable("ruleId") String ruleId); + + @PostMapping("/heart/icpartyunit/editpartyorcommunity") + Result editPartyOrCommunity(@RequestBody CheckStaffInfoResultDTO formDTO); + } diff --git a/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/feign/fallback/EpmetHeartOpenFeignClientFallback.java b/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/feign/fallback/EpmetHeartOpenFeignClientFallback.java index 815bfab92c..558cd43f2b 100644 --- a/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/feign/fallback/EpmetHeartOpenFeignClientFallback.java +++ b/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/feign/fallback/EpmetHeartOpenFeignClientFallback.java @@ -18,6 +18,7 @@ import com.epmet.dto.form.demand.UserDemandNameQueryFormDTO; import com.epmet.dto.form.resi.ResiVolunteerAuthenticateFormDTO; import com.epmet.dto.form.resi.ResisByPolicyRulesFormDTO; import com.epmet.dto.form.resi.VolunteerCommonFormDTO; +import com.epmet.dto.result.CheckStaffInfoResultDTO; import com.epmet.dto.result.PartyUnitListResultDTO; import com.epmet.dto.result.demand.IcResiDemandDictDTO; import com.epmet.dto.result.demand.OptionDTO; @@ -166,4 +167,9 @@ public class EpmetHeartOpenFeignClientFallback implements EpmetHeartOpenFeignCli public Result listPolicyRules4QueryAndExport(String ruleId) { return ModuleUtils.feignConError(ServiceConstant.EPMET_HEART_SERVER, "listPolicyRules4QueryAndExport", ruleId); } + + @Override + public Result editPartyOrCommunity(CheckStaffInfoResultDTO formDTO) { + return ModuleUtils.feignConError(ServiceConstant.EPMET_HEART_SERVER, "editPartyOrCommunity", formDTO); + } } diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/controller/IcPartyUnitController.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/controller/IcPartyUnitController.java index 236e0d3b99..95093177cb 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/controller/IcPartyUnitController.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/controller/IcPartyUnitController.java @@ -22,11 +22,7 @@ import com.epmet.dto.form.PartyUnitFormDTO; import com.epmet.dto.form.PartyUnitListFormDTO; import com.epmet.dto.form.*; import com.epmet.dto.form.demand.ServiceQueryFormDTO; -import com.epmet.dto.result.ImportTaskCommonResultDTO; -import com.epmet.dto.result.PartyTypepercentResultDTO; -import com.epmet.dto.result.PartyUnitDistributionResultDTO; -import com.epmet.dto.result.PartyUnitListResultDTO; -import com.epmet.dto.result.PartyUnitListbrieResultDTO; +import com.epmet.dto.result.*; import com.epmet.dto.result.demand.OptionDTO; import com.epmet.excel.IcPartyUnitExcel; import com.epmet.feign.EpmetCommonServiceOpenFeignClient; @@ -312,4 +308,14 @@ public class IcPartyUnitController { return new Result>().ok(icPartyUnitService.getAssistanceUnitList(tokenDto)); } + /** + * Desc: 联建单位、社会自组织同步/取消同步到通讯录部门后相应的修改业务数据 + * @author sun + */ + @PostMapping("editpartyorcommunity") + public Result editPartyOrCommunity(@RequestBody CheckStaffInfoResultDTO formDTO){ + icPartyUnitService.editPartyOrCommunity(formDTO); + return new Result(); + } + } diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/entity/IcCommunitySelfOrganizationEntity.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/entity/IcCommunitySelfOrganizationEntity.java index 7098ce83e9..3f35e32184 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/entity/IcCommunitySelfOrganizationEntity.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/entity/IcCommunitySelfOrganizationEntity.java @@ -117,4 +117,19 @@ public class IcCommunitySelfOrganizationEntity extends BaseEpmetEntity { */ private String remark; + /** + * 同步状态【已同步:sync 未同步:not_sync】 + */ + private String syncType; + + /** + * 部门ID customer_department.id + */ + private String deptId; + + /** + * 部门下工作人员Id + */ + private String deptStaffId; + } diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/entity/IcPartyUnitEntity.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/entity/IcPartyUnitEntity.java index 65c11a447f..47210a837a 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/entity/IcPartyUnitEntity.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/entity/IcPartyUnitEntity.java @@ -105,4 +105,19 @@ public class IcPartyUnitEntity extends BaseEpmetEntity { */ private String remark; + /** + * 同步状态【已同步:sync 未同步:not_sync】 + */ + private String syncType; + + /** + * 部门ID customer_department.id + */ + private String deptId; + + /** + * 部门下工作人员Id + */ + private String deptStaffId; + } diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/IcPartyUnitService.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/IcPartyUnitService.java index 53ddf81e19..8cc2d342a7 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/IcPartyUnitService.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/IcPartyUnitService.java @@ -12,10 +12,7 @@ import com.epmet.dto.form.PartyUnitFormDTO; import com.epmet.dto.form.PartyUnitListFormDTO; import com.epmet.dto.form.PartyUnitListbriefFormDTO; import com.epmet.dto.form.demand.ServiceQueryFormDTO; -import com.epmet.dto.result.PartyTypepercentResultDTO; -import com.epmet.dto.result.PartyUnitDistributionResultDTO; -import com.epmet.dto.result.PartyUnitListResultDTO; -import com.epmet.dto.result.PartyUnitListbrieResultDTO; +import com.epmet.dto.result.*; import com.epmet.dto.result.demand.OptionDTO; import com.epmet.entity.IcPartyUnitEntity; import org.springframework.web.multipart.MultipartFile; @@ -182,4 +179,6 @@ public interface IcPartyUnitService extends BaseService { * @param form */ List getTypepercent(PartyTypepercentFormDTO form); + + void editPartyOrCommunity(CheckStaffInfoResultDTO formDTO); } diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcPartyUnitServiceImpl.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcPartyUnitServiceImpl.java index 91dc0baa57..7b8df1b923 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcPartyUnitServiceImpl.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcPartyUnitServiceImpl.java @@ -55,6 +55,7 @@ import com.epmet.dto.form.demand.ServiceQueryFormDTO; import com.epmet.dto.result.*; import com.epmet.dto.result.demand.OptionDTO; import com.epmet.dto.result.demand.ServiceStatDTO; +import com.epmet.entity.IcCommunitySelfOrganizationEntity; import com.epmet.entity.IcPartyUnitEntity; import com.epmet.excel.IcPartyUnitImportExcel; import com.epmet.excel.IcPartyUnitImportFailedExcel; @@ -62,6 +63,7 @@ import com.epmet.feign.EpmetAdminOpenFeignClient; import com.epmet.feign.EpmetCommonServiceOpenFeignClient; import com.epmet.feign.EpmetHeartOpenFeignClient; import com.epmet.feign.OssFeignClient; +import com.epmet.service.IcCommunitySelfOrganizationService; import com.epmet.service.IcPartyUnitService; import com.epmet.service.IcServiceItemDictService; import com.epmet.service.IcUserDemandRecService; @@ -111,6 +113,8 @@ public class IcPartyUnitServiceImpl extends BaseServiceImpl search(PartyUnitFormDTO formDTO) { @@ -711,4 +715,30 @@ public class IcPartyUnitServiceImpl extends BaseServiceImpl newRoles; + /** + * 部门类型 + * 联建单位: party_unit + * 社会自组织: community_org + */ + private String deptType; } diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/CheckStaffInfoResultDTO.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/CheckStaffInfoResultDTO.java index 0f500a0cab..01619b955a 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/CheckStaffInfoResultDTO.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/CheckStaffInfoResultDTO.java @@ -17,8 +17,10 @@ package com.epmet.dto.result; +import com.epmet.dto.form.CheckStaffInfoFormDTO; import lombok.Data; +import javax.validation.constraints.NotBlank; import java.io.Serializable; @@ -41,10 +43,41 @@ public class CheckStaffInfoResultDTO implements Serializable { * 数据库中工作人员姓名【返参姓名有值的则需要更新工作人员信息】 */ private String personName; + /** + * 联建单位、社会自组织Id + */ + private String id; + /** + * 部门Id + */ + private String deptId; + /** + * 联建单位: party_unit + * 社会自组织: community_org + */ + private String deptType; + /** + * 部门下工作人员Id + */ + private String deptStaffId; + /** + * 已同步:sync 未同步:not_sync + */ + private String syncType; + + + //token中信息 + private String customerId; + private String userId; /** - * 类型,后端使用 + * 后端使用 */ - private Boolean key = true; + //工作人员添加入口Id(agencyId;deptId;gridId) + private String orgId = ""; + //工作人员添加入口类型(组织:agency;部门:dept;网格:gridId) + private String orgType = ""; + //工作人员Id,后端使用 + private String staffId = ""; } \ No newline at end of file diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/DepartmentController.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/DepartmentController.java index fac881ed3e..448181bf74 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/DepartmentController.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/DepartmentController.java @@ -162,16 +162,27 @@ public class DepartmentController { return new Result>().ok(deptList); } - /** * @Author sun * @Description 根据手机号姓名查询人员信息,联建单位、社会自组织新增使用 */ @PostMapping("checkstaffinfo") public Result checkStaffInfo(@LoginUser TokenDto tokenDTO, @RequestBody CheckStaffInfoFormDTO formDTO) { - ValidatorUtils.validateEntity(formDTO, CheckStaffInfoFormDTO.Check.class); + ValidatorUtils.validateEntity(formDTO, CheckStaffInfoFormDTO.CheckAdd.class); formDTO.setCustomerId(tokenDTO.getCustomerId()); - formDTO.setStaffId(tokenDTO.getUserId()); + formDTO.setUserId(tokenDTO.getUserId()); return new Result().ok(departmentService.checkStaffInfo(formDTO)); } + + /** + * @Author sun + * @Description 联建单位、社会自组织同步到通讯录操作 + */ + @PostMapping("addoreditdeptorstaff") + public Result addOrEditDeptOrStaff(@RequestBody CheckStaffInfoFormDTO formDTO) { + return new Result().ok(departmentService.addOrEditDeptOrStaff(formDTO)); + } + + + } diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/DepartmentService.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/DepartmentService.java index d1f589b26e..020ef3551e 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/DepartmentService.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/DepartmentService.java @@ -103,4 +103,6 @@ public interface DepartmentService { List listDepartmentListByStaffId(String staffId); CheckStaffInfoResultDTO checkStaffInfo(CheckStaffInfoFormDTO formDTO); + + CheckStaffInfoResultDTO addOrEditDeptOrStaff(CheckStaffInfoFormDTO formDTO); } diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java index aa8d6c1db8..69f3ab9ae2 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java @@ -17,6 +17,7 @@ package com.epmet.service.impl; +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.epmet.commons.tools.constant.NumConstant; import com.epmet.commons.tools.constant.StrConstant; import com.epmet.commons.tools.dto.result.CustomerStaffInfoCacheResult; @@ -39,14 +40,11 @@ import com.epmet.dto.CustomerStaffDTO; import com.epmet.dto.CustomerStaffDepartmentDTO; import com.epmet.dto.form.*; import com.epmet.dto.result.*; -import com.epmet.entity.CustomerAgencyEntity; -import com.epmet.entity.CustomerDepartmentEntity; -import com.epmet.entity.CustomerStaffDepartmentEntity; +import com.epmet.entity.*; +import com.epmet.feign.EpmetHeartOpenFeignClient; import com.epmet.feign.EpmetUserFeignClient; import com.epmet.feign.EpmetUserOpenFeignClient; -import com.epmet.service.CustomerDepartmentService; -import com.epmet.service.CustomerStaffDepartmentService; -import com.epmet.service.DepartmentService; +import com.epmet.service.*; import com.epmet.util.ModuleConstant; import org.apache.commons.lang3.StringUtils; import org.slf4j.Logger; @@ -55,6 +53,7 @@ import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; import org.springframework.util.CollectionUtils; +import org.springframework.web.bind.annotation.RequestBody; import java.util.ArrayList; import java.util.List; @@ -86,6 +85,15 @@ public class DepartmentServiceImpl implements DepartmentService { private EpmetUserOpenFeignClient epmetUserOpenFeignClient; @Autowired private StaffOrgRelationDao staffOrgRelationDao; + @Autowired + private CustomerStaffAgencyService customerStaffAgencyService; + @Autowired + private CustomerAgencyService customerAgencyService; + @Autowired + private StaffOrgRelationService staffOrgRelationService; + @Autowired + private EpmetHeartOpenFeignClient epmetHeartOpenFeignClient; + /** * @param formDTO * @return @@ -294,6 +302,13 @@ public class DepartmentServiceImpl implements DepartmentService { @Override public CheckStaffInfoResultDTO checkStaffInfo(CheckStaffInfoFormDTO formDTO) { CheckStaffInfoResultDTO resultDTO = new CheckStaffInfoResultDTO(); + resultDTO.setCustomerId(formDTO.getCustomerId()); + resultDTO.setUserId(formDTO.getUserId()); + //座机号的直接返回 + if(formDTO.getMobile().startsWith("0")){ + resultDTO.setMsg("座机账号无法创建账号,建议使用填写手机号,否则将无法获取通知信息"); + return resultDTO; + } //1.根据手机号查询客户下工作人员信息 CustomerStaffFormDTO user = new CustomerStaffFormDTO(); user.setCustomerId(formDTO.getCustomerId()); @@ -314,29 +329,29 @@ public class DepartmentServiceImpl implements DepartmentService { if (CollectionUtils.isEmpty(list)) { return resultDTO; } + resultDTO.setOrgId(list.get(0).getOrgId()); + resultDTO.setOrgType(list.get(0).getOrgType()); + resultDTO.setStaffId(list.get(0).getStaffId()); //3.校验工作人员的注册关系【从哪里新增进来的工作人员】 //获取当前操作人员缓存信息 - CustomerStaffInfoCacheResult staffInfo = CustomerStaffRedis.getStaffInfo(formDTO.getCustomerId(), formDTO.getStaffId()); + CustomerStaffInfoCacheResult staffInfo = CustomerStaffRedis.getStaffInfo(formDTO.getCustomerId(), formDTO.getUserId()); if (null == staffInfo) { - throw new EpmetException(String.format("查询工作人员%s缓存信息失败...", formDTO.getStaffId())); + throw new EpmetException(String.format("查询工作人员%s缓存信息失败...", formDTO.getUserId())); } //所属组织信息不同的给提示【所属组织不同时则不新增部门、不新增工作人员】 if (!list.get(0).getAgencyId().equals(staffInfo.getAgencyId())) { resultDTO.setMsg("联系电话已存在其他组织工作账号中,请使用其他手机号,否则将无法获取通知信息"); - resultDTO.setKey(false); return resultDTO; } //从网格下添加的人给提示【网格下加的人时则不新增部门、不新增工作人员】 - if ("gridId".equals(list.get(0).getOrgType())) { + if (!"agency".equals(list.get(0).getOrgType())) { resultDTO.setMsg("联系电话已存在其他部门工作账号中,请先将该工作人员调动至本组织下,再次添加"); - resultDTO.setKey(false); return resultDTO; } //账号被禁用的给提示【人员被禁用的则不新增部门、不新增工作人员】 if ("disabled".equals(userResult.getData().getEnableFlag())) { resultDTO.setMsg("该工作人员账号已被禁用,请使用其他联系电话,否则将无法获取通知信息"); - resultDTO.setKey(false); return resultDTO; } //姓名不一样的给反馈 @@ -348,5 +363,116 @@ public class DepartmentServiceImpl implements DepartmentService { return resultDTO; } + @Override + public CheckStaffInfoResultDTO addOrEditDeptOrStaff(CheckStaffInfoFormDTO formDTO) { + CustomerStaffInfoCacheResult staffInfo = CustomerStaffRedis.getStaffInfo(formDTO.getCustomerId(), formDTO.getUserId()); + if (null == staffInfo) { + throw new EpmetException(String.format("查询工作人员%s缓存信息失败...", formDTO.getUserId())); + } + //1.校验当前数据是否允许操作 + CheckStaffInfoResultDTO resultDTO = checkStaffInfo(formDTO); + if(!resultDTO.getType()){ + return resultDTO; + } + //2.根据校验结果操作数据 + //2-1.没查到人的直接新增部门、人员 + if(StringUtils.isBlank(resultDTO.getOrgType())){ + //一、新增工作人员 + StaffSubmitFromDTO submitDTO = ConvertUtils.sourceToTarget(formDTO, StaffSubmitFromDTO.class); + submitDTO.setName(formDTO.getPersonName()); + submitDTO.setAgencyId(staffInfo.getAgencyId()); + submitDTO.setGender(0); + submitDTO.setWorkType("fulltime"); + Result staffResult = epmetUserOpenFeignClient.deptToAddStaff(submitDTO); + if (!staffResult.success()) { + throw new RenException("人员添加失败" + staffResult.getMsg()); + } + //二、新增部门 + AddDepartmentFormDTO deptDTO = new AddDepartmentFormDTO(); + deptDTO.setAgencyId(staffInfo.getAgencyId()); + deptDTO.setDepartmentDuty(""); + deptDTO.setDepartmentName(formDTO.getDeptName()); + deptDTO.setTotalUser(1); + Result deptResult = addDepartment(deptDTO); + //三、新增组织人员关系数据 + //人员机关关系表 + CustomerStaffAgencyEntity customerStaffAgencyEntity = new CustomerStaffAgencyEntity(); + customerStaffAgencyEntity.setCustomerId(formDTO.getCustomerId()); + customerStaffAgencyEntity.setUserId(staffResult.getData().getUserId()); + customerStaffAgencyEntity.setAgencyId(staffInfo.getAgencyId()); + customerStaffAgencyService.insert(customerStaffAgencyEntity); + //机关总人数加一 + OrgResultDTO orgDTO = customerAgencyDao.selectAgencyDetail(staffInfo.getAgencyId(), "agency"); + CustomerAgencyEntity agencyEntity = new CustomerAgencyEntity(); + agencyEntity.setId(staffInfo.getAgencyId()); + agencyEntity.setTotalUser(orgDTO.getTotalUser() + 1); + customerAgencyService.updateById(agencyEntity); + //工作人员注册组织关系表新增数据 + StaffOrgRelationEntity staffOrgRelationEntity = new StaffOrgRelationEntity(); + staffOrgRelationEntity.setCustomerId(formDTO.getCustomerId()); + staffOrgRelationEntity.setPids(("".equals(orgDTO.getPids()) ? "" : orgDTO.getPids())); + staffOrgRelationEntity.setStaffId(staffResult.getData().getUserId()); + staffOrgRelationEntity.setOrgId(staffInfo.getAgencyId()); + staffOrgRelationEntity.setOrgType("agency"); + staffOrgRelationService.insert(staffOrgRelationEntity); + + //四、部门下新增人员关系数据 + CustomerStaffDepartmentEntity dept = new CustomerStaffDepartmentEntity(); + dept.setCustomerId(formDTO.getCustomerId()); + dept.setUserId(staffResult.getData().getUserId()); + dept.setDepartmentId(deptResult.getData().getDepartmentId()); + customerStaffDepartmentService.insert(dept); + //修改联建单位/社会自组织业务数据 + resultDTO.setId(formDTO.getId()); + resultDTO.setDeptId(deptResult.getData().getDepartmentId()); + resultDTO.setDeptType(formDTO.getDeptType()); + resultDTO.setDeptStaffId(staffResult.getData().getUserId()); + resultDTO.setSyncType("sync"); + Result heartResult = epmetHeartOpenFeignClient.editPartyOrCommunity(resultDTO); + if (!heartResult.success()) { + throw new RenException("修改联建单位/社会自组织业务数据失败" + heartResult.getMsg()); + } + + } + //2-2.查到是组织下的人,新增部门,绑定部门人员关系 + if(("agency".equals(resultDTO.getOrgType()))){ + //一、更新人员基础数据[姓名 手机号信息] + CustomerStaffDTO staffDTO = new CustomerStaffDTO(); + staffDTO.setUserId(resultDTO.getStaffId()); + staffDTO.setRealName(formDTO.getPersonName()); + staffDTO.setMobile(formDTO.getMobile()); + staffDTO.setUpdatedBy(resultDTO.getUserId()); + Result result = epmetUserOpenFeignClient.editToStaff(staffDTO); + if (!result.success()) { + throw new RenException("更新工作人员基础信息失败" + result.getMsg()); + } + //二、新增部门数据 + AddDepartmentFormDTO deptDTO = new AddDepartmentFormDTO(); + deptDTO.setAgencyId(staffInfo.getAgencyId()); + deptDTO.setDepartmentDuty(""); + deptDTO.setDepartmentName(formDTO.getDeptName()); + deptDTO.setTotalUser(1); + Result deptResult = addDepartment(deptDTO); + //三、部门下新增人员关系数据 + CustomerStaffDepartmentEntity dept = new CustomerStaffDepartmentEntity(); + dept.setCustomerId(formDTO.getCustomerId()); + dept.setUserId(resultDTO.getStaffId()); + dept.setDepartmentId(deptResult.getData().getDepartmentId()); + customerStaffDepartmentService.insert(dept); + //修改联建单位/社会自组织业务数据 + resultDTO.setId(formDTO.getId()); + resultDTO.setDeptId(deptResult.getData().getDepartmentId()); + resultDTO.setDeptType(formDTO.getDeptType()); + resultDTO.setDeptStaffId(resultDTO.getStaffId()); + resultDTO.setSyncType("sync"); + Result heartResult = epmetHeartOpenFeignClient.editPartyOrCommunity(resultDTO); + if (!heartResult.success()) { + throw new RenException("修改联建单位/社会自组织业务数据失败" + heartResult.getMsg()); + } + } + + return resultDTO; + } + } \ No newline at end of file diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java index 5cd018c37c..d6f6215b11 100644 --- a/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/EpmetUserOpenFeignClient.java @@ -859,4 +859,10 @@ public interface EpmetUserOpenFeignClient { @PostMapping("/epmetuser/customerstaff/staffdetailinfo") Result staffDetailInfo(@RequestBody CustomerStaffFormDTO formDTO); + @PostMapping("/epmetuser/customerstaff/depttoaddstaff") + Result deptToAddStaff(@RequestBody StaffSubmitFromDTO fromDTO); + + @PostMapping("/epmetuser/customerstaff/edittostaff") + Result editToStaff(@RequestBody CustomerStaffDTO formDTO); + } diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/fallback/EpmetUserOpenFeignClientFallback.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/fallback/EpmetUserOpenFeignClientFallback.java index 6491dc477d..b6133865ad 100644 --- a/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/fallback/EpmetUserOpenFeignClientFallback.java +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/feign/fallback/EpmetUserOpenFeignClientFallback.java @@ -651,4 +651,14 @@ public class EpmetUserOpenFeignClientFallback implements EpmetUserOpenFeignClien return ModuleUtils.feignConError(ServiceConstant.EPMET_USER_SERVER, "staffDetailInfo", formDTO); } + @Override + public Result deptToAddStaff(StaffSubmitFromDTO fromDTO) { + return ModuleUtils.feignConError(ServiceConstant.EPMET_USER_SERVER, "deptToAddStaff", fromDTO); + } + + @Override + public Result editToStaff(CustomerStaffDTO formDTO) { + return ModuleUtils.feignConError(ServiceConstant.EPMET_USER_SERVER, "editToStaff", formDTO); + } + } diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java index f3a5d6bd99..cebe012041 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/CustomerStaffController.java @@ -498,5 +498,17 @@ public class CustomerStaffController { return new Result().ok(customerStaffService.staffDetailInfo(formDTO)); } + @PostMapping("depttoaddstaff") + public Result dedittostaffeptToAddStaff(@RequestBody StaffSubmitFromDTO fromDTO){ + Result result = customerStaffService.deptToAddStaff(fromDTO); + return result; + } + + @PostMapping(value = "edittostaff") + public Result editToStaff(@RequestBody CustomerStaffDTO formDTO) { + customerStaffService.editToStaff(formDTO); + return new Result(); + } + } diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/dao/CustomerStaffDao.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/dao/CustomerStaffDao.java index 725a456b46..3cce3ff4b6 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/dao/CustomerStaffDao.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/dao/CustomerStaffDao.java @@ -229,4 +229,6 @@ public interface CustomerStaffDao extends BaseDao { * @Description 工作人员基本信息 **/ List gridStaffMobileList(List staffIdList); + + void edit(CustomerStaffDTO formDTO); } diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/CustomerStaffService.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/CustomerStaffService.java index 16d6e83189..6e6000b6db 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/CustomerStaffService.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/CustomerStaffService.java @@ -349,4 +349,8 @@ public interface CustomerStaffService extends BaseService { List gridMobileList(String gridId, String userId); CustomerStaffDTO staffDetailInfo(CustomerStaffFormDTO formDTO); + + Result deptToAddStaff(StaffSubmitFromDTO fromDTO); + + void editToStaff(CustomerStaffDTO formDTO); } diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java index 1caf9abf5a..b25d014fc5 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java @@ -60,12 +60,14 @@ import com.epmet.service.UserService; import com.epmet.util.ModuleConstant; import lombok.extern.slf4j.Slf4j; import org.apache.commons.lang3.StringUtils; +import org.apache.ibatis.annotations.Param; import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; import org.springframework.util.CollectionUtils; +import org.springframework.web.bind.annotation.RequestBody; import java.util.*; import java.util.stream.Collectors; @@ -874,4 +876,32 @@ public class CustomerStaffServiceImpl extends BaseServiceImpl deptToAddStaff(StaffSubmitFromDTO fromDTO) { + //1.查询客户小程序端'工作人员'角色 + GovStaffRoleDTO govRole = govStaffRoleDao.getRoleByCustomerIdAndRoleKey(fromDTO.getCustomerId(), "staff"); + List roles = new ArrayList<>(); + roles.add(govRole.getId()); + fromDTO.setRoles(roles); + + //2.查询客户管理平台对应角色【联建单位负责人、社区自组织负责人】 + GovRoleListDTO roleDTO = new GovRoleListDTO(); + roleDTO.setName("party_unit".equals(fromDTO.getDeptType())?"联建单位负责人":"社区自组织负责人"); + Result resultRole = govAccessFeignClient.getGovRole(roleDTO); + if (!resultRole.success()) { + throw new RenException("人员添加失败" + resultRole.getMsg()); + } + List newRoles = new ArrayList<>(); + newRoles.add(resultRole.getData().getId()); + + //3.新增工作人员 + Result result = addStaff(fromDTO); + return result; + } + + @Override + public void editToStaff(CustomerStaffDTO formDTO) { + baseDao.edit(formDTO); + } + } diff --git a/epmet-user/epmet-user-server/src/main/resources/mapper/CustomerStaffDao.xml b/epmet-user/epmet-user-server/src/main/resources/mapper/CustomerStaffDao.xml index 10965b93ce..919b69fe0b 100644 --- a/epmet-user/epmet-user-server/src/main/resources/mapper/CustomerStaffDao.xml +++ b/epmet-user/epmet-user-server/src/main/resources/mapper/CustomerStaffDao.xml @@ -456,4 +456,15 @@ + + UPDATE customer_staff + SET real_name = #{realName}, + mobile = #{mobile}, + updated_time = NOW(), + updated_by = #{updatedBy} + WHERE + del_flag = '0' + AND user_id = #{userId} + + From e72fbfc1bdcfb8a49986c709c73b51820b98b7cd Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Thu, 28 Jul 2022 11:05:02 +0800 Subject: [PATCH 074/155] =?UTF-8?q?=E7=BC=BA=E4=B8=AA=E7=9F=AD=E4=BF=A1?= =?UTF-8?q?=E6=A8=A1=E6=9D=BF=E7=BC=96=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../epmet/service/IcUserDemandRecService.java | 3 ++ .../impl/IcServiceRecordV2ServiceImpl.java | 51 ++++++++++++++----- .../impl/IcUserDemandRecServiceImpl.java | 11 ++-- .../epmet/constant/SmsTemplateConstant.java | 8 +++ .../com/epmet/dto/form/SendSmsFormDTO.java | 6 +-- .../epmet/service/impl/SysSmsServiceImpl.java | 10 ++-- 6 files changed, 61 insertions(+), 28 deletions(-) diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/IcUserDemandRecService.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/IcUserDemandRecService.java index 1824e1feb3..68a295422a 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/IcUserDemandRecService.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/IcUserDemandRecService.java @@ -25,6 +25,7 @@ import com.epmet.dto.form.demand.*; import com.epmet.dto.result.PointRecordResultDTO; import com.epmet.dto.result.demand.*; import com.epmet.entity.IcUserDemandRecEntity; +import com.epmet.entity.ServerInfoDTO; import java.util.List; import java.util.Map; @@ -262,4 +263,6 @@ public interface IcUserDemandRecService extends BaseService page(Map params) { @@ -156,7 +153,35 @@ public class IcServiceRecordV2ServiceImpl extends BaseServiceImpl smsList = new ArrayList<>(); + SendSmsFormDTO sms = new SendSmsFormDTO(); + sms.setCustomerId(customerId); + sms.setMobile(serverInfoDTO.getMobile()); + sms.setAliyunTemplateCode(SmsTemplateConstant.COMMON_SMS_TEM); + Map paramMap = new HashMap<>(); + paramMap.put("content", String.format("%s发起一个【%s】服务,请服务完成后尽快反馈,谢谢合作。", staffInfoCacheResult.getAgencyName(), serviceName)); + sms.setParamMap(paramMap); + smsList.add(sms); + messageOpenFeignClient.sendMsg(smsList); } @Override diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java index 1e2784349f..355ca9f008 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java @@ -453,13 +453,12 @@ public class IcUserDemandRecServiceImpl extends BaseServiceImpl paramsContent=new ArrayList<>(); - paramsContent.add(String.format("%s给您指派了一个新的需求,请查看",staffInfoCacheResult.getAgencyName())); - sms.setParamsContent(paramsContent); + sms.setAliyunTemplateCode(SmsTemplateConstant.COMMON_SMS_TEM); + Map paramMap = new HashMap<>(); + paramMap.put("content", String.format("%s给您指派了一个新的需求,请查看", staffInfoCacheResult.getAgencyName())); + sms.setParamMap(paramMap); smsList.add(sms); messageOpenFeignClient.sendMsg(smsList); - } /** @@ -468,7 +467,7 @@ public class IcUserDemandRecServiceImpl extends BaseServiceImpl paramsContent; - + // private List paramsContent; + private Map paramMap; private String customerId; } diff --git a/epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/service/impl/SysSmsServiceImpl.java b/epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/service/impl/SysSmsServiceImpl.java index ee4c3be657..b001fd7978 100644 --- a/epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/service/impl/SysSmsServiceImpl.java +++ b/epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/service/impl/SysSmsServiceImpl.java @@ -13,7 +13,6 @@ import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; import com.epmet.commons.mybatis.service.impl.BaseServiceImpl; import com.epmet.commons.tools.constant.Constant; -import com.epmet.commons.tools.constant.NumConstant; import com.epmet.commons.tools.exception.EpmetErrorCode; import com.epmet.commons.tools.exception.ErrorCode; import com.epmet.commons.tools.exception.RenException; @@ -333,16 +332,15 @@ public class SysSmsServiceImpl extends BaseServiceImpl public void sendMsg(List formDTOList) { try { for(SendSmsFormDTO formDTO:formDTOList){ + if (StringUtils.isBlank(formDTO.getAliyunTemplateCode())) { + continue; + } SysSmsDTO sysSmsDTO = new SysSmsDTO(); sysSmsDTO.setMobile(formDTO.getMobile()); sysSmsDTO.setAliyunTemplateCode(formDTO.getAliyunTemplateCode()); sysSmsDTO.setCustomerId(formDTO.getCustomerId()); - HashMap map = new HashMap<>(); try{ - if(SmsTemplateConstant.PROJECT_TRANSFER.equals(formDTO.getAliyunTemplateCode())){ - map.put("params1", formDTO.getParamsContent().get(NumConstant.ZERO)); - } - String paramJson = new ObjectMapper().writeValueAsString(map); + String paramJson = new ObjectMapper().writeValueAsString(formDTO.getParamMap()); sysSmsDTO.setParams(paramJson); } catch (JsonProcessingException e) { log.warn("sendMsg JsonProcessingException", e); From b1f3b0c82f1fb34fa7ef98c212e9340cdc2536e3 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Thu, 28 Jul 2022 11:18:55 +0800 Subject: [PATCH 075/155] =?UTF-8?q?=E5=8D=A0=E4=B8=AA=E4=BD=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../CoverageAnalisisDataListLeftFormDTO.java | 45 +++++++++++++++++++ .../CoverageAnalisisDataListResultDTOV2.java | 26 +++++++++++ .../controller/CoverageController.java | 20 +++++++++ .../dataaggre/service/CoverageService.java | 9 ++++ .../service/impl/CoverageServiceImpl.java | 17 ++++++- 5 files changed, 116 insertions(+), 1 deletion(-) create mode 100644 epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageAnalisisDataListLeftFormDTO.java create mode 100644 epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/CoverageAnalisisDataListResultDTOV2.java diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageAnalisisDataListLeftFormDTO.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageAnalisisDataListLeftFormDTO.java new file mode 100644 index 0000000000..eec9aebeb2 --- /dev/null +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageAnalisisDataListLeftFormDTO.java @@ -0,0 +1,45 @@ +package com.epmet.dataaggre.dto.govorg.form; + +import com.epmet.commons.tools.validator.group.CustomerClientShowGroup; +import lombok.Data; + +import javax.validation.constraints.NotBlank; +import java.util.List; + +/** + * @Description + * @Author yzm + * @Date 2022/7/28 11:09 + */ +@Data +public class CoverageAnalisisDataListLeftFormDTO { + public interface ShowGroup extends CustomerClientShowGroup { + } + + /** + * + */ + @NotBlank(message = "组织不能为空", groups = ShowGroup.class) + private String orgId; + @NotBlank(message = "组织类型不能为空", groups = ShowGroup.class) + private String orgType; + + /** + * 图层类型列表 + */ + private List coverageTypes; + + /** + * 分类key + */ + private List categoryKeys; + + // 以下3个参数固定 + private Integer pageNo = 1; + private Integer pageSize = 20; + private Boolean isPage = false; + + private String customerId; + private String staffId; +} + diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/CoverageAnalisisDataListResultDTOV2.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/CoverageAnalisisDataListResultDTOV2.java new file mode 100644 index 0000000000..dcc46ae471 --- /dev/null +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/CoverageAnalisisDataListResultDTOV2.java @@ -0,0 +1,26 @@ +package com.epmet.dataaggre.dto.govorg.result; + +import lombok.Data; + +import java.util.List; + +/** + * @Description + * @Author yzm + * @Date 2022/7/28 11:13 + */ +@Data +public class CoverageAnalisisDataListResultDTOV2 { + /** + * 维度 + */ + private String latitude; + + /** + * 经度 + */ + private String longitude; + + private List dataList; +} + diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java index 67a4b52d04..3304d48b18 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java @@ -9,8 +9,10 @@ import com.epmet.commons.tools.utils.Result; import com.epmet.dataaggre.dto.coverage.AnalysisGovernedTargetsResult; import com.epmet.dataaggre.dto.coverage.AnalysisResourceCategoriesResult; import com.epmet.dataaggre.dto.govorg.form.CoverageAnalisisDataListFormDTO; +import com.epmet.dataaggre.dto.govorg.form.CoverageAnalisisDataListLeftFormDTO; import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; import com.epmet.dataaggre.dto.govorg.result.CoverageAnalisisDataListResultDTO; +import com.epmet.dataaggre.dto.govorg.result.CoverageAnalisisDataListResultDTOV2; import com.epmet.dataaggre.dto.govorg.result.CoverageHomeSearchResultDTO; import com.epmet.dataaggre.service.CoverageService; import org.apache.commons.collections4.CollectionUtils; @@ -94,4 +96,22 @@ public class CoverageController { return new Result>().ok(r); } + /** + * 五大图层,左侧菜单,点击事件,查询人.事的分布 + * + * @param formDTO + * @return + */ + @RequestMapping("dataList-left") + public Result> dataListLeft(@LoginUser TokenDto tokenDto, @RequestBody CoverageAnalisisDataListLeftFormDTO formDTO) { + List coverageTypes = formDTO.getCoverageTypes(); + List categoryKeys = formDTO.getCategoryKeys(); + if (CollectionUtils.isEmpty(coverageTypes)) { + return new Result().ok(new PageData<>(new ArrayList<>(), 0)); + } + formDTO.setCustomerId(tokenDto.getCustomerId()); + formDTO.setStaffId(tokenDto.getUserId()); + PageData page = coverageService.dataListLeft(formDTO); + return new Result>().ok(page); + } } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java index 651655f2e3..f9ebd60f63 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java @@ -3,8 +3,10 @@ package com.epmet.dataaggre.service; import com.epmet.commons.tools.page.PageData; import com.epmet.dataaggre.dto.coverage.AnalysisGovernedTargetsResult; import com.epmet.dataaggre.dto.coverage.AnalysisResourceCategoriesResult; +import com.epmet.dataaggre.dto.govorg.form.CoverageAnalisisDataListLeftFormDTO; import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; import com.epmet.dataaggre.dto.govorg.result.CoverageAnalisisDataListResultDTO; +import com.epmet.dataaggre.dto.govorg.result.CoverageAnalisisDataListResultDTOV2; import com.epmet.dataaggre.dto.govorg.result.CoverageHomeSearchResultDTO; import java.util.List; @@ -40,4 +42,11 @@ public interface CoverageService { List listAnalysisResourceCategories(); List listGovernedTargetCategories(); + + /** + * 五大图层,左侧菜单,点击事件,查询人.事的分布 + * @param formDTO + * @return + */ + PageData dataListLeft(CoverageAnalisisDataListLeftFormDTO formDTO); } \ No newline at end of file diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index dcc72dd756..7eeafa1652 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -12,8 +12,10 @@ import com.epmet.commons.tools.utils.EpmetRequestHolder; import com.epmet.dataaggre.dto.coverage.AnalysisGovernedTargetsResult; import com.epmet.dataaggre.dto.coverage.AnalysisResourceCategoriesResult; import com.epmet.dataaggre.dto.epmetuser.result.IcResiInfoResultDTO; +import com.epmet.dataaggre.dto.govorg.form.CoverageAnalisisDataListLeftFormDTO; import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; import com.epmet.dataaggre.dto.govorg.result.CoverageAnalisisDataListResultDTO; +import com.epmet.dataaggre.dto.govorg.result.CoverageAnalisisDataListResultDTOV2; import com.epmet.dataaggre.dto.govorg.result.CoverageHomeSearchResultDTO; import com.epmet.dataaggre.dto.govorg.result.IcEnterisePatrolResultDTO; import com.epmet.dataaggre.entity.epmetuser.IcResiUserEntity; @@ -29,7 +31,6 @@ import com.epmet.dataaggre.service.govorg.GovOrgService; import com.epmet.dataaggre.service.govproject.GovProjectService; import com.epmet.dataaggre.service.heart.HeartService; import com.epmet.dataaggre.service.opercustomize.IcResiCategoryWarnService; -import jodd.util.StringUtil; import lombok.extern.slf4j.Slf4j; import org.apache.commons.collections4.CollectionUtils; import org.apache.commons.lang3.StringUtils; @@ -591,4 +592,18 @@ public class CoverageServiceImpl implements CoverageService { results.add(ggfwRq); return results; } + + /** + * 五大图层,左侧菜单,点击事件,查询人.事的分布 + * + * @param formDTO + * @return + */ + @Override + public PageData dataListLeft(CoverageAnalisisDataListLeftFormDTO formDTO) { + //todo + + + return null; + } } \ No newline at end of file From 1f9e1c21c8cc3a2a3b626969fac6be1278fcc6c3 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Thu, 28 Jul 2022 14:18:55 +0800 Subject: [PATCH 076/155] =?UTF-8?q?=E5=9F=8E=E5=B8=82=E7=AE=A1=E7=90=86?= =?UTF-8?q?=E4=BA=8B=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../commons/tools/constant/StrConstant.java | 2 + .../epmet/dataaggre/constant/OrgConstant.java | 3 + .../form/CoverageAnalisisDataListFormDTO.java | 9 ++ .../CoverageAnalisisDataListLeftFormDTO.java | 15 ++- .../CoverageAnalisisDataListResultDTO.java | 19 ++++ .../controller/CoverageController.java | 8 +- .../dataaggre/service/CoverageService.java | 3 +- .../service/impl/CoverageServiceImpl.java | 97 +++++++++++++++---- 8 files changed, 125 insertions(+), 31 deletions(-) diff --git a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/constant/StrConstant.java b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/constant/StrConstant.java index 62d9fef763..7d2ad8ec03 100644 --- a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/constant/StrConstant.java +++ b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/constant/StrConstant.java @@ -110,4 +110,6 @@ public interface StrConstant { String YES = "是"; String NO = "否"; + + String ELLIPSIS="......"; } diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/constant/OrgConstant.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/constant/OrgConstant.java index 5119475926..28bc8e794c 100644 --- a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/constant/OrgConstant.java +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/constant/OrgConstant.java @@ -14,4 +14,7 @@ public interface OrgConstant { String GRID_ID="GRID_ID"; String GENDER="GENDER"; String HOUSE_TYPE_KEY="HOUSE_TYPE"; + + String AGENCY_ID="agencyId"; + String AGENC_PATH="agencyPath"; } diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageAnalisisDataListFormDTO.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageAnalisisDataListFormDTO.java index 179dc80aba..2b3b0127df 100644 --- a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageAnalisisDataListFormDTO.java +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageAnalisisDataListFormDTO.java @@ -9,7 +9,16 @@ import java.util.List; */ @Data public class CoverageAnalisisDataListFormDTO { + /** + * 目前都是组织id + */ + private String orgId; + /** + * agency + * grid + */ + private String orgType; /** * 图层类型列表 */ diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageAnalisisDataListLeftFormDTO.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageAnalisisDataListLeftFormDTO.java index eec9aebeb2..ca369fd4db 100644 --- a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageAnalisisDataListLeftFormDTO.java +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageAnalisisDataListLeftFormDTO.java @@ -15,15 +15,18 @@ import java.util.List; public class CoverageAnalisisDataListLeftFormDTO { public interface ShowGroup extends CustomerClientShowGroup { } - /** - * + * 目前都是组织id */ @NotBlank(message = "组织不能为空", groups = ShowGroup.class) private String orgId; + + /** + * agency + * grid + */ @NotBlank(message = "组织类型不能为空", groups = ShowGroup.class) private String orgType; - /** * 图层类型列表 */ @@ -34,12 +37,8 @@ public class CoverageAnalisisDataListLeftFormDTO { */ private List categoryKeys; - // 以下3个参数固定 - private Integer pageNo = 1; - private Integer pageSize = 20; - private Boolean isPage = false; - private String customerId; private String staffId; + } diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/CoverageAnalisisDataListResultDTO.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/CoverageAnalisisDataListResultDTO.java index fd566cb191..1af67eb36a 100644 --- a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/CoverageAnalisisDataListResultDTO.java +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/CoverageAnalisisDataListResultDTO.java @@ -1,8 +1,10 @@ package com.epmet.dataaggre.dto.govorg.result; +import com.epmet.commons.tools.constant.StrConstant; import lombok.AllArgsConstructor; import lombok.Data; import lombok.NoArgsConstructor; +import org.apache.commons.lang3.StringUtils; @Data @NoArgsConstructor @@ -40,4 +42,21 @@ public class CoverageAnalisisDataListResultDTO { */ private String longitude; + /** + * 经度,纬度:120.38862649282282,36.07138835989835 + */ + private String longLat; + + public CoverageAnalisisDataListResultDTO(String id, String categoryKey, String categoryName, String placeType, String content, String latitude, String longitude) { + this.id=id; + this.categoryKey=categoryKey; + this.categoryName=categoryName; + this.placeType=placeType; + this.content=content; + this.latitude=latitude; + this.longitude=longitude; + if(StringUtils.isNotBlank(latitude)&&StringUtils.isNotBlank(longitude)){ + this.longLat=longitude.concat(StrConstant.COMMA).concat(latitude); + } + } } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java index 3304d48b18..f300875b13 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java @@ -5,6 +5,7 @@ import com.epmet.commons.tools.dto.result.ZhzlCategorySelectDTO; import com.epmet.commons.tools.enums.ZhzlResiCategoryEnum; import com.epmet.commons.tools.page.PageData; import com.epmet.commons.tools.security.dto.TokenDto; +import com.epmet.commons.tools.utils.EpmetRequestHolder; import com.epmet.commons.tools.utils.Result; import com.epmet.dataaggre.dto.coverage.AnalysisGovernedTargetsResult; import com.epmet.dataaggre.dto.coverage.AnalysisResourceCategoriesResult; @@ -42,13 +43,16 @@ public class CoverageController { */ @RequestMapping("dataList") public Result> dataList(@RequestBody CoverageAnalisisDataListFormDTO input) { + // 获取跟组织的坐标 + String customerId = EpmetRequestHolder.getLoginUserCustomerId(); + String staffId = EpmetRequestHolder.getLoginUserId(); List coverageTypes = input.getCoverageTypes(); List categoryKeys = input.getCategoryKeys(); if (CollectionUtils.isEmpty(coverageTypes)) { return new Result().ok(new PageData<>(new ArrayList<>(), 0)); } - PageData page = coverageService.analysisDataList(coverageTypes, categoryKeys, + PageData page = coverageService.analysisDataList(customerId,staffId,input.getOrgId(),input.getOrgType(),coverageTypes, categoryKeys, input.getSearch(), input.getPageNo(), input.getPageSize(), input.getIsPage()); return new Result>().ok(page); } @@ -106,7 +110,7 @@ public class CoverageController { public Result> dataListLeft(@LoginUser TokenDto tokenDto, @RequestBody CoverageAnalisisDataListLeftFormDTO formDTO) { List coverageTypes = formDTO.getCoverageTypes(); List categoryKeys = formDTO.getCategoryKeys(); - if (CollectionUtils.isEmpty(coverageTypes)) { + if (CollectionUtils.isEmpty(coverageTypes)||CollectionUtils.isEmpty(categoryKeys)) { return new Result().ok(new PageData<>(new ArrayList<>(), 0)); } formDTO.setCustomerId(tokenDto.getCustomerId()); diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java index f9ebd60f63..5c39087be8 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java @@ -24,7 +24,8 @@ public interface CoverageService { * @param pageSize 页面大小 * @return */ - PageData analysisDataList(List coverageTypes, List categoryKeys, + PageData analysisDataList(String customerId,String staffId,String orgId,String orgType, + List coverageTypes, List categoryKeys, String search, Integer pageNo, Integer pageSize, Boolean isPage); /** diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index 7eeafa1652..a94b485714 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -1,14 +1,19 @@ package com.epmet.dataaggre.service.impl; +import com.epmet.commons.tools.constant.NumConstant; +import com.epmet.commons.tools.constant.StrConstant; import com.epmet.commons.tools.dto.result.CustomerStaffInfoCacheResult; import com.epmet.commons.tools.enums.CoverageEnums; import com.epmet.commons.tools.enums.CoveragePlaceTypeEnum; import com.epmet.commons.tools.exception.EpmetErrorCode; import com.epmet.commons.tools.exception.EpmetException; import com.epmet.commons.tools.page.PageData; +import com.epmet.commons.tools.redis.common.CustomerOrgRedis; import com.epmet.commons.tools.redis.common.CustomerStaffRedis; +import com.epmet.commons.tools.redis.common.bean.AgencyInfoCache; import com.epmet.commons.tools.redis.common.bean.BuildingInfoCache; import com.epmet.commons.tools.utils.EpmetRequestHolder; +import com.epmet.dataaggre.constant.OrgConstant; import com.epmet.dataaggre.dto.coverage.AnalysisGovernedTargetsResult; import com.epmet.dataaggre.dto.coverage.AnalysisResourceCategoriesResult; import com.epmet.dataaggre.dto.epmetuser.result.IcResiInfoResultDTO; @@ -33,6 +38,7 @@ import com.epmet.dataaggre.service.heart.HeartService; import com.epmet.dataaggre.service.opercustomize.IcResiCategoryWarnService; import lombok.extern.slf4j.Slf4j; import org.apache.commons.collections4.CollectionUtils; +import org.apache.commons.collections4.MapUtils; import org.apache.commons.lang3.StringUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; @@ -97,12 +103,11 @@ public class CoverageServiceImpl implements CoverageService { * @return */ @Override - public PageData analysisDataList(List coverageTypes, List categoryKeys, + public PageData analysisDataList(String customerId,String staffId,String orgId,String orgType, + List coverageTypes, List categoryKeys, String search, Integer pageNo, Integer pageSize, Boolean isPage) { // 获取跟组织的坐标 - String customerId = EpmetRequestHolder.getLoginUserCustomerId(); - String staffId = EpmetRequestHolder.getLoginUserId(); CustomerAgencyEntity rootAgency = govOrgService.getRootAgencyByCustomerId(customerId); // 1.根据categoryKeys分类key列表,查询他们和图层时间的关系,映射为一个map @@ -122,15 +127,9 @@ public class CoverageServiceImpl implements CoverageService { } // 2.循环coverageTypes,使用key到map中查询(为了顺序),得到categoryKeys列表之后,根据实际情况做相应的查询 - CustomerStaffInfoCacheResult staffInfo = CustomerStaffRedis.getStaffInfo(customerId, staffId); - - if (staffInfo == null) { - String msg = "未找到当前登录人信息。staffId:" + EpmetRequestHolder.getLoginUserId(); - throw new EpmetException(EpmetErrorCode.SERVER_ERROR.getCode(), msg, msg); - } - - String staffPids = getStaffPidsFromStaffInfo(staffInfo); - String agencyId = staffInfo.getAgencyId(); + Map agencyMap=getStaffPidsFromStaffInfo(customerId,staffId,orgId,orgType); + String agencyPath = agencyMap.get(OrgConstant.AGENC_PATH); + String agencyId = agencyMap.get(OrgConstant.AGENCY_ID); // 分页不太好分,先查出所有的数据,然后partation()吧 int start = (pageNo - 1) * pageSize; @@ -158,7 +157,7 @@ public class CoverageServiceImpl implements CoverageService { } for (GovOrgCoverageService.CategoryCoverageMapping e : ccm) { - Integer tempCount = doDataListCount(EpmetRequestHolder.getLoginUserCustomerId(), agencyId, staffPids, e.getPlaceType(), + Integer tempCount = doDataListCount(EpmetRequestHolder.getLoginUserCustomerId(), agencyId, agencyPath, e.getPlaceType(), e.getCategoryKey(), search); lastTotalCount = totalCount; totalCount += tempCount; @@ -167,7 +166,7 @@ public class CoverageServiceImpl implements CoverageService { // 不分页,查询所有 // 检索数据 List dataSegment = doDataListSearch( - EpmetRequestHolder.getLoginUserCustomerId(), agencyId, staffPids, e.getPlaceType(), + EpmetRequestHolder.getLoginUserCustomerId(), agencyId, agencyPath, e.getPlaceType(), e.getCategoryKey(), search, null, null, isPage, rootAgency); rls.addAll(dataSegment); continue; @@ -189,7 +188,7 @@ public class CoverageServiceImpl implements CoverageService { // 检索数据 List dataSegment = doDataListSearch( - EpmetRequestHolder.getLoginUserCustomerId(), agencyId, staffPids, e.getPlaceType(), + EpmetRequestHolder.getLoginUserCustomerId(), agencyId, agencyPath, e.getPlaceType(), e.getCategoryKey(), search, 1, end, isPage, rootAgency); if (firstTimeDataAppear) { @@ -239,6 +238,41 @@ public class CoverageServiceImpl implements CoverageService { } } + private Map getStaffPidsFromStaffInfo(String customerId, String staffId, String orgId, String orgType) { + Map map = new HashMap<>(); + String agencyPath = StrConstant.EPMETY_STR; + String agencyId = StrConstant.EPMETY_STR; + if (StringUtils.isBlank(orgId)) { + // 默认查询的是当前登录用户所属组织及下级 + CustomerStaffInfoCacheResult staffInfo = CustomerStaffRedis.getStaffInfo(customerId, staffId); + if (staffInfo == null) { + String msg = "未找到当前登录人信息。staffId:" + EpmetRequestHolder.getLoginUserId(); + throw new EpmetException(EpmetErrorCode.SERVER_ERROR.getCode(), msg, msg); + } + // staffPids + agencyPath = getStaffPidsFromStaffInfo(staffInfo); + agencyId = staffInfo.getAgencyId(); + } else { + // 根据传入的组织id来 + if (OrgConstant.AGENCY.equals(orgType)) { + AgencyInfoCache agencyInfoCache = CustomerOrgRedis.getAgencyInfo(orgId); + if (agencyInfoCache == null) { + String msg = "查询组织缓存信息异常。orgId:" + orgId; + throw new EpmetException(EpmetErrorCode.SERVER_ERROR.getCode(), msg, msg); + } + agencyId = orgId; + if (StringUtils.isNotBlank(agencyInfoCache.getPids()) && !"0".equals(agencyInfoCache.getPids()) && !"0".equals(agencyInfoCache)) { + agencyPath = agencyInfoCache.getPids().concat(":").concat(agencyId); + } else { + agencyPath = orgId; + } + } + } + map.put(OrgConstant.AGENCY_ID, agencyId); + map.put(OrgConstant.AGENC_PATH, agencyPath); + return map; + } + /** * 计算数据条数 * @param customerId @@ -346,7 +380,8 @@ public class CoverageServiceImpl implements CoverageService { return icEventEntities.stream() .map(e -> new CoverageAnalisisDataListResultDTO( - e.getId(), categoryKey, isPage ? categoryDict.getCategoryName() : null, placeType, isPage ? e.getName() : null, + e.getId(), categoryKey, isPage ? categoryDict.getCategoryName() : null, placeType, + e.getEventContent().length() < 51 ? e.getEventContent() : e.getEventContent().substring(NumConstant.ZERO, NumConstant.FIFTY).concat(StrConstant.ELLIPSIS), e.getLatitude(), e.getLongitude())) .collect(Collectors.toList()); @@ -601,9 +636,31 @@ public class CoverageServiceImpl implements CoverageService { */ @Override public PageData dataListLeft(CoverageAnalisisDataListLeftFormDTO formDTO) { - //todo - - - return null; + PageData page = analysisDataList(formDTO.getCustomerId(), formDTO.getStaffId(), formDTO.getOrgId(), formDTO.getOrgType(), + formDTO.getCoverageTypes(), formDTO.getCategoryKeys(), + StrConstant.EPMETY_STR,// 搜索关键词 默认空字符串 + NumConstant.ONE, + NumConstant.TWENTY, + false // 不分页 + ); + List list = new ArrayList<>(); + if (CollectionUtils.isNotEmpty(page.getList())) { + Map> group = page.getList().stream().collect(Collectors.groupingBy(CoverageAnalisisDataListResultDTO::getLongLat)); + if (MapUtils.isNotEmpty(group)) { + for (Map.Entry> entry : group.entrySet()) { + if (CollectionUtils.isEmpty(entry.getValue())) { + continue; + } + CoverageAnalisisDataListResultDTOV2 res = new CoverageAnalisisDataListResultDTOV2(); + res.setLatitude(entry.getValue().get(NumConstant.ZERO).getLatitude()); + res.setLongitude(entry.getValue().get(NumConstant.ZERO).getLongitude()); + res.setDataList(entry.getValue()); + list.add(res); + } + } + } + // int totalCount = CollectionUtils.isNotEmpty(list) ? list.size() : NumConstant.ZERO;//这个是实际返回的几个坐标点 + // page.getTotal()是多少条业务数据 + return new PageData<>(list, page.getTotal()); } } \ No newline at end of file From 6c06a8c829915ed7aae4c841509752020eb259df Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Thu, 28 Jul 2022 14:27:45 +0800 Subject: [PATCH 077/155] =?UTF-8?q?=E4=BA=8B=E4=BB=B6=E5=86=85=E5=AE=B920?= =?UTF-8?q?=E5=AD=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/epmet/dataaggre/service/impl/CoverageServiceImpl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index a94b485714..3d919688b2 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -381,7 +381,7 @@ public class CoverageServiceImpl implements CoverageService { return icEventEntities.stream() .map(e -> new CoverageAnalisisDataListResultDTO( e.getId(), categoryKey, isPage ? categoryDict.getCategoryName() : null, placeType, - e.getEventContent().length() < 51 ? e.getEventContent() : e.getEventContent().substring(NumConstant.ZERO, NumConstant.FIFTY).concat(StrConstant.ELLIPSIS), + e.getEventContent().length() < 21 ? e.getEventContent() : e.getEventContent().substring(NumConstant.ZERO, 20).concat(StrConstant.ELLIPSIS), e.getLatitude(), e.getLongitude())) .collect(Collectors.toList()); From 3661de73e32b43f9b339a26cfb75dbc124b1c3b2 Mon Sep 17 00:00:00 2001 From: sunyuchao Date: Thu, 28 Jul 2022 14:36:05 +0800 Subject: [PATCH 078/155] =?UTF-8?q?=E8=81=94=E5=BB=BA=E5=8D=95=E4=BD=8D?= =?UTF-8?q?=E3=80=81=E7=A4=BE=E4=BC=9A=E8=87=AA=E7=BB=84=E7=BB=87=E5=8F=96?= =?UTF-8?q?=E6=B6=88=E5=90=8C=E6=AD=A5=E6=93=8D=E4=BD=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../epmet/dto/form/CheckStaffInfoFormDTO.java | 5 +- .../controller/DepartmentController.java | 21 +++++- .../com/epmet/service/DepartmentService.java | 4 +- .../service/impl/DepartmentServiceImpl.java | 68 +++++++++++++++++-- .../feign/GovProjectOpenFeignClient.java | 2 + .../GovProjectOpenFeignClientFallback.java | 5 ++ .../epmet/controller/ProjectController.java | 8 +++ .../com/epmet/service/ProjectService.java | 1 + .../service/impl/ProjectServiceImpl.java | 9 +++ .../resources/mapper/CustomerStaffDao.xml | 12 ++-- 10 files changed, 120 insertions(+), 15 deletions(-) diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/CheckStaffInfoFormDTO.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/CheckStaffInfoFormDTO.java index 855755e1c1..b3fc9b036c 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/CheckStaffInfoFormDTO.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/CheckStaffInfoFormDTO.java @@ -34,7 +34,7 @@ public class CheckStaffInfoFormDTO implements Serializable { /** * 联建单位、社会自组织Id */ - @NotBlank(message = "id不能为空", groups = CheckAdd.class) + @NotBlank(message = "id不能为空", groups = {CheckAdd.class, CheckEdit.class}) private String id; /** * 部门名称 @@ -55,7 +55,7 @@ public class CheckStaffInfoFormDTO implements Serializable { * 联建单位: party_unit * 社会自组织: community_org */ - @NotBlank(message = "部门类型不能为空", groups = CheckAdd.class) + @NotBlank(message = "部门类型不能为空", groups = {CheckAdd.class, CheckEdit.class}) private String deptType; /** * 部门Id [取消同步时必填] @@ -65,6 +65,7 @@ public class CheckStaffInfoFormDTO implements Serializable { /** * 部门下工作人员Id */ + @NotBlank(message = "工作人员Id不能为空", groups = CheckEdit.class) private String deptStaffId; //token中信息 diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/DepartmentController.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/DepartmentController.java index 448181bf74..da70a814b7 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/DepartmentController.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/DepartmentController.java @@ -178,9 +178,24 @@ public class DepartmentController { * @Author sun * @Description 联建单位、社会自组织同步到通讯录操作 */ - @PostMapping("addoreditdeptorstaff") - public Result addOrEditDeptOrStaff(@RequestBody CheckStaffInfoFormDTO formDTO) { - return new Result().ok(departmentService.addOrEditDeptOrStaff(formDTO)); + @PostMapping("syncdept") + public Result syncDept(@LoginUser TokenDto tokenDTO, @RequestBody CheckStaffInfoFormDTO formDTO) { + ValidatorUtils.validateEntity(formDTO, CheckStaffInfoFormDTO.CheckAdd.class); + formDTO.setCustomerId(tokenDTO.getCustomerId()); + formDTO.setUserId(tokenDTO.getUserId()); + return new Result().ok(departmentService.syncDept(formDTO)); + } + + /** + * @Author sun + * @Description 联建单位、社会自组织取消同步 + */ + @PostMapping("notsyncdept") + public Result notSyncDept(@LoginUser TokenDto tokenDTO, @RequestBody CheckStaffInfoFormDTO formDTO) { + ValidatorUtils.validateEntity(formDTO, CheckStaffInfoFormDTO.CheckEdit.class); + formDTO.setCustomerId(tokenDTO.getCustomerId()); + formDTO.setUserId(tokenDTO.getUserId()); + return new Result().ok(departmentService.notSyncDept(formDTO)); } diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/DepartmentService.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/DepartmentService.java index 020ef3551e..adcf468e9d 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/DepartmentService.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/DepartmentService.java @@ -104,5 +104,7 @@ public interface DepartmentService { CheckStaffInfoResultDTO checkStaffInfo(CheckStaffInfoFormDTO formDTO); - CheckStaffInfoResultDTO addOrEditDeptOrStaff(CheckStaffInfoFormDTO formDTO); + CheckStaffInfoResultDTO syncDept(CheckStaffInfoFormDTO formDTO); + + CheckStaffInfoResultDTO notSyncDept(CheckStaffInfoFormDTO formDTO); } diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java index 69f3ab9ae2..22fcda5a1e 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java @@ -34,16 +34,14 @@ import com.epmet.dao.CustomerAgencyDao; import com.epmet.dao.CustomerDepartmentDao; import com.epmet.dao.CustomerStaffDepartmentDao; import com.epmet.dao.StaffOrgRelationDao; -import com.epmet.dto.CustomerDepartmentDTO; -import com.epmet.dto.CustomerIdDTO; -import com.epmet.dto.CustomerStaffDTO; -import com.epmet.dto.CustomerStaffDepartmentDTO; +import com.epmet.dto.*; import com.epmet.dto.form.*; import com.epmet.dto.result.*; import com.epmet.entity.*; import com.epmet.feign.EpmetHeartOpenFeignClient; import com.epmet.feign.EpmetUserFeignClient; import com.epmet.feign.EpmetUserOpenFeignClient; +import com.epmet.feign.GovProjectOpenFeignClient; import com.epmet.service.*; import com.epmet.util.ModuleConstant; import org.apache.commons.lang3.StringUtils; @@ -56,6 +54,7 @@ import org.springframework.util.CollectionUtils; import org.springframework.web.bind.annotation.RequestBody; import java.util.ArrayList; +import java.util.Date; import java.util.List; /** @@ -93,6 +92,8 @@ public class DepartmentServiceImpl implements DepartmentService { private StaffOrgRelationService staffOrgRelationService; @Autowired private EpmetHeartOpenFeignClient epmetHeartOpenFeignClient; + @Autowired + private GovProjectOpenFeignClient govProjectOpenFeignClient; /** * @param formDTO @@ -364,7 +365,8 @@ public class DepartmentServiceImpl implements DepartmentService { } @Override - public CheckStaffInfoResultDTO addOrEditDeptOrStaff(CheckStaffInfoFormDTO formDTO) { + @Transactional(rollbackFor = Exception.class) + public CheckStaffInfoResultDTO syncDept(CheckStaffInfoFormDTO formDTO) { CustomerStaffInfoCacheResult staffInfo = CustomerStaffRedis.getStaffInfo(formDTO.getCustomerId(), formDTO.getUserId()); if (null == staffInfo) { throw new EpmetException(String.format("查询工作人员%s缓存信息失败...", formDTO.getUserId())); @@ -438,9 +440,11 @@ public class DepartmentServiceImpl implements DepartmentService { if(("agency".equals(resultDTO.getOrgType()))){ //一、更新人员基础数据[姓名 手机号信息] CustomerStaffDTO staffDTO = new CustomerStaffDTO(); + staffDTO.setCustomerId(formDTO.getCustomerId()); staffDTO.setUserId(resultDTO.getStaffId()); staffDTO.setRealName(formDTO.getPersonName()); staffDTO.setMobile(formDTO.getMobile()); + staffDTO.setUpdatedTime(new Date()); staffDTO.setUpdatedBy(resultDTO.getUserId()); Result result = epmetUserOpenFeignClient.editToStaff(staffDTO); if (!result.success()) { @@ -474,5 +478,59 @@ public class DepartmentServiceImpl implements DepartmentService { return resultDTO; } + @Override + @Transactional(rollbackFor = Exception.class) + public CheckStaffInfoResultDTO notSyncDept(CheckStaffInfoFormDTO formDTO) { + CheckStaffInfoResultDTO resultDTO = new CheckStaffInfoResultDTO(); + //1.校验当前部门下工作人员是否有代办项目 + ProjectListFromDTO project = new ProjectListFromDTO(); + project.setUserId(formDTO.getDeptStaffId()); + Result> projectResult = govProjectOpenFeignClient.staffPendingProject(project); + if (!projectResult.success()) { + throw new RenException("获取工作人员代办项目数据失败" + projectResult.getMsg()); + } + if(projectResult.getData().size()>NumConstant.ZERO){ + String msg = String.format("当前%s下负责人存在未办结的项目,请先将待处理项目办结后再操作",("party_unit".equals(formDTO.getDeptType())?"联建单位":"社会自组织")); + resultDTO.setMsg(msg); + } + //2.无代办项目的则删除部门、工作人员信息、修改联建单位/社会自组织业务数据 + //2-1.删除部门 + customerDepartmentDao.deleteById(formDTO.getId()); + //2-2.删除部门人员关系数据 + LambdaQueryWrapper query = new LambdaQueryWrapper<>(); + query.eq(CustomerStaffDepartmentEntity::getDepartmentId, formDTO.getDeptId()); + query.eq(CustomerStaffDepartmentEntity::getUserId, formDTO.getDeptStaffId()); + customerStaffDepartmentDao.delete(query); + //2-3.删除人员注册关系数据 + LambdaQueryWrapper StaffOrgRelation = new LambdaQueryWrapper<>(); + StaffOrgRelation.eq(StaffOrgRelationEntity::getOrgId, formDTO.getDeptId()); + StaffOrgRelation.eq(StaffOrgRelationEntity::getStaffId, formDTO.getDeptStaffId()); + staffOrgRelationDao.delete(StaffOrgRelation); + //2-4.删除工作人员数据 + CustomerStaffDTO staffDTO = new CustomerStaffDTO(); + staffDTO.setCustomerId(formDTO.getCustomerId()); + staffDTO.setUserId(formDTO.getDeptStaffId()); + staffDTO.setDelFlag(1); + staffDTO.setUpdatedTime(new Date()); + staffDTO.setUpdatedBy(formDTO.getUserId()); + Result result = epmetUserOpenFeignClient.editToStaff(staffDTO); + if (!result.success()) { + throw new RenException("更新工作人员基础信息失败" + result.getMsg()); + } + //2-5.修改联建单位/社会自组织业务数据 + resultDTO.setId(formDTO.getId()); + resultDTO.setDeptId(formDTO.getDeptId()); + resultDTO.setDeptType(formDTO.getDeptType()); + resultDTO.setDeptStaffId(formDTO.getDeptStaffId()); + resultDTO.setSyncType("not_sync"); + Result heartResult = epmetHeartOpenFeignClient.editPartyOrCommunity(resultDTO); + if (!heartResult.success()) { + throw new RenException("修改联建单位/社会自组织业务数据失败" + heartResult.getMsg()); + } + + resultDTO.setType(true); + return resultDTO; + } + } \ No newline at end of file diff --git a/epmet-module/gov-project/gov-project-client/src/main/java/com/epmet/feign/GovProjectOpenFeignClient.java b/epmet-module/gov-project/gov-project-client/src/main/java/com/epmet/feign/GovProjectOpenFeignClient.java index 1242d3064b..7907ac7ec5 100644 --- a/epmet-module/gov-project/gov-project-client/src/main/java/com/epmet/feign/GovProjectOpenFeignClient.java +++ b/epmet-module/gov-project/gov-project-client/src/main/java/com/epmet/feign/GovProjectOpenFeignClient.java @@ -175,5 +175,7 @@ public interface GovProjectOpenFeignClient { @PostMapping("gov/project/icEvent/closeprojectordemand") Result closeProjectOrDemand(@RequestBody ColseProjectOrDemandFormDTO formDTO); + @PostMapping("gov/project/project/staffpendingproject") + Result> staffPendingProject(@RequestBody ProjectListFromDTO formDTO); } diff --git a/epmet-module/gov-project/gov-project-client/src/main/java/com/epmet/feign/fallback/GovProjectOpenFeignClientFallback.java b/epmet-module/gov-project/gov-project-client/src/main/java/com/epmet/feign/fallback/GovProjectOpenFeignClientFallback.java index 49a969f91e..51f7922ba5 100644 --- a/epmet-module/gov-project/gov-project-client/src/main/java/com/epmet/feign/fallback/GovProjectOpenFeignClientFallback.java +++ b/epmet-module/gov-project/gov-project-client/src/main/java/com/epmet/feign/fallback/GovProjectOpenFeignClientFallback.java @@ -169,4 +169,9 @@ public class GovProjectOpenFeignClientFallback implements GovProjectOpenFeignCli public Result closeProjectOrDemand(ColseProjectOrDemandFormDTO formDTO) { return ModuleUtils.feignConError(ServiceConstant.GOV_PROJECT_SERVER, "closeProjectOrDemand",formDTO); } + + @Override + public Result> staffPendingProject(ProjectListFromDTO formDTO) { + return ModuleUtils.feignConError(ServiceConstant.GOV_PROJECT_SERVER, "staffPendingProject",formDTO); + } } diff --git a/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/controller/ProjectController.java b/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/controller/ProjectController.java index 03bb218bd1..fb8bcad8fd 100644 --- a/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/controller/ProjectController.java +++ b/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/controller/ProjectController.java @@ -379,4 +379,12 @@ public class ProjectController { ValidatorUtils.validateEntity(formDTO, SatisfactionEvaluationListFormDTO.SatisfactionEvaluationListForm.class); return new Result().ok(projectService.satisfactionEvaluationList(formDTO)); } + + /** + * Desc: 查询客户下工作人员是否有代办项目 + */ + @PostMapping("staffpendingproject") + public Result> staffPendingProject(@RequestBody ProjectListFromDTO fromDTO){ + return new Result>().ok(projectService.staffPendingProject(fromDTO)); + } } \ No newline at end of file diff --git a/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/ProjectService.java b/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/ProjectService.java index 82a88d3a5b..2e5fd4fd76 100644 --- a/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/ProjectService.java +++ b/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/ProjectService.java @@ -395,4 +395,5 @@ public interface ProjectService extends BaseService { */ void projectListExport(HttpServletResponse response,ProjectManageListFormDTO formDTO) throws IOException; + List staffPendingProject(ProjectListFromDTO fromDTO); } \ No newline at end of file diff --git a/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/impl/ProjectServiceImpl.java b/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/impl/ProjectServiceImpl.java index a9f4ca0093..7d26d3f9a0 100644 --- a/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/impl/ProjectServiceImpl.java +++ b/epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/impl/ProjectServiceImpl.java @@ -3445,4 +3445,13 @@ public class ProjectServiceImpl extends BaseServiceImpl staffPendingProject(ProjectListFromDTO fromDTO) { + fromDTO.setPageNo(0); + fromDTO.setPageSize(1); + List projectList = baseDao.selectPendList(fromDTO); + return projectList; + } + } diff --git a/epmet-user/epmet-user-server/src/main/resources/mapper/CustomerStaffDao.xml b/epmet-user/epmet-user-server/src/main/resources/mapper/CustomerStaffDao.xml index 919b69fe0b..62a9312c6d 100644 --- a/epmet-user/epmet-user-server/src/main/resources/mapper/CustomerStaffDao.xml +++ b/epmet-user/epmet-user-server/src/main/resources/mapper/CustomerStaffDao.xml @@ -458,12 +458,16 @@ UPDATE customer_staff - SET real_name = #{realName}, - mobile = #{mobile}, - updated_time = NOW(), - updated_by = #{updatedBy} + + real_name = #{realName}, + mobile = #{mobile}, + updated_by = #{updatedBy}, + updated_time = #{updatedTime}, + del_flag = #{delFlag} + WHERE del_flag = '0' + AND customer_id = #{customerId} AND user_id = #{userId} From 960c3026443daf777e25ddf25d2eb7e1272e392c Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Thu, 28 Jul 2022 14:46:57 +0800 Subject: [PATCH 079/155] =?UTF-8?q?=E5=AE=89=E5=85=A8=E7=94=9F=E4=BA=A7?= =?UTF-8?q?=E9=9A=90=E6=82=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dao/govorg/IcEnterprisePatrolRecordDao.java | 4 ++-- .../service/govorg/GovOrgCoverageService.java | 7 ++----- .../govorg/impl/GovOrgCoverageServiceImpl.java | 14 ++++++++------ .../service/impl/CoverageServiceImpl.java | 16 ++++++++++++++-- .../govorg/IcEnterprisePatrolRecordDao.xml | 6 ++++++ 5 files changed, 32 insertions(+), 15 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcEnterprisePatrolRecordDao.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcEnterprisePatrolRecordDao.java index d6f5c83879..1019bb6f69 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcEnterprisePatrolRecordDao.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcEnterprisePatrolRecordDao.java @@ -26,7 +26,7 @@ public interface IcEnterprisePatrolRecordDao extends BaseDao listEnterprisePatrol(@Param("customerId") String customerId, @Param("agencyId") String agencyId, @Param("staffOrgIds") String staffOrgIds, @Param("search") String search, - @Param("categoryKey") String categoryKey); + @Param("categoryKey") String categoryKey, @Param("latestResult") String latestResult); } \ No newline at end of file diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java index 7b1779be57..10b94f81d9 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java @@ -1,16 +1,13 @@ package com.epmet.dataaggre.service.govorg; -import com.epmet.commons.mybatis.service.BaseService; import com.epmet.dataaggre.dto.govorg.result.IcEnterisePatrolResultDTO; import com.epmet.dataaggre.entity.govorg.*; -import com.epmet.dataaggre.entity.heart.IcCommunitySelfOrganizationEntity; import lombok.AllArgsConstructor; import lombok.Data; import lombok.NoArgsConstructor; import java.util.List; import java.util.Map; -import java.util.Set; /** * org库的图层service @@ -115,11 +112,11 @@ public interface GovOrgCoverageService { Integer countSuporiorResourceEntities(String customerId, String staffOrgIds, String search, String categoryKey); - Integer countEnterprisePatrol(String customerId, String agencyId, String staffOrgIds, String search, String categoryKey); + Integer countEnterprisePatrol(String customerId, String agencyId, String staffOrgIds, String search, String categoryKey,String latestResult); List listEnterprisePatrol(String customerId, String agencyId, String staffOrgIds, String search, String categoryKey, Boolean isPage, Integer pageNo, - Integer pageSize); + Integer pageSize, String latestResult); /** * 通过居民数量等条件查询房屋数量 diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java index bc64607a7f..e2987a1233 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java @@ -1,7 +1,6 @@ package com.epmet.dataaggre.service.govorg.impl; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; -import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.epmet.commons.dynamic.datasource.annotation.DataSource; import com.epmet.commons.tools.enums.CoverageEnums; import com.epmet.commons.tools.utils.EpmetRequestHolder; @@ -15,7 +14,10 @@ import org.apache.commons.lang3.StringUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; -import java.util.*; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; /** * org 图层service @@ -291,18 +293,18 @@ public class GovOrgCoverageServiceImpl implements GovOrgCoverageService { } @Override - public Integer countEnterprisePatrol(String customerId, String agencyId, String staffOrgIds, String search, String categoryKey) { - return enterprisePatrolRecordDao.countEnterprisePatrol(customerId, agencyId, staffOrgIds, search, categoryKey); + public Integer countEnterprisePatrol(String customerId, String agencyId, String staffOrgIds, String search, String categoryKey,String latestResult) { + return enterprisePatrolRecordDao.countEnterprisePatrol(customerId, agencyId, staffOrgIds, search, categoryKey,latestResult); } @Override public List listEnterprisePatrol(String customerId, String agencyId, String staffOrgIds, String search, String categoryKey, Boolean isPage, - Integer pageNo, Integer pageSize) { + Integer pageNo, Integer pageSize, String latestResult) { if (isPage) { PageHelper.startPage(pageNo, pageSize); } - return enterprisePatrolRecordDao.listEnterprisePatrol(customerId, agencyId, staffOrgIds, search, categoryKey); + return enterprisePatrolRecordDao.listEnterprisePatrol(customerId, agencyId, staffOrgIds, search, categoryKey, latestResult); } @Override diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index 3d919688b2..3e4e824fda 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -313,7 +313,7 @@ public class CoverageServiceImpl implements CoverageService { return orgCoverageService.countDangerousChemicalEntities(customerId, staffOrgIds, search, categoryKey); } else if (PLACE_TYPE_ENTERPRISE_PARTROL.equals(placeType)) { // 企事业单位巡查 - return orgCoverageService.countEnterprisePatrol(customerId, agencyId, staffOrgIds, search, categoryKey); + return orgCoverageService.countEnterprisePatrol(customerId, agencyId, staffOrgIds, search, categoryKey,null); } else if (PLACE_TYPE_GROUP_RENT.equals(placeType)) { // 群租房。出租的房屋,住的人口超过5人属于群租房(是个规定 return orgCoverageService.countByResiNumber(customerId, staffOrgIds, search, 5, HOUSE_RENT_FLAG_RENT); @@ -323,6 +323,10 @@ public class CoverageServiceImpl implements CoverageService { } else if (PLACE_TYPE_SUPERIOR_RESOURCE.equals(placeType)) { // 优势资源 return orgCoverageService.countSuporiorResourceEntities(customerId, staffOrgIds, search, categoryKey); + } else if(CoveragePlaceTypeEnum.ENTERPRISE_PATROL_UNQUALIFIED.equals(placeType)){ + // 企事业单位巡查 + // 最新巡查结果【0:合格 1:不合格】 + return orgCoverageService.countEnterprisePatrol(customerId, agencyId, staffOrgIds, search, categoryKey,NumConstant.ONE_STR ); } return 0; @@ -432,7 +436,7 @@ public class CoverageServiceImpl implements CoverageService { } else if (PLACE_TYPE_ENTERPRISE_PARTROL.equals(placeType)) { // 企事业单位巡查 List list = orgCoverageService.listEnterprisePatrol( - customerId, agencyId, staffOrgIds, search, categoryKey, isPage, pageNo, pageSize); + customerId, agencyId, staffOrgIds, search, categoryKey, isPage, pageNo, pageSize,null); return list.stream() .map(dc -> new CoverageAnalisisDataListResultDTO(dc.getEnterpriseId(), categoryKey, @@ -473,6 +477,14 @@ public class CoverageServiceImpl implements CoverageService { .map(dc -> new CoverageAnalisisDataListResultDTO(dc.getId(), categoryKey, isPage ? categoryDict.getCategoryName() : null, placeType, isPage ? dc.getName() : null, dc.getLatitude(), dc.getLongitude())) .collect(Collectors.toList()); + } else if(CoveragePlaceTypeEnum.ENTERPRISE_PATROL_UNQUALIFIED.equals(placeType)){ + List list = orgCoverageService.listEnterprisePatrol( + customerId, agencyId, staffOrgIds, search, categoryKey, isPage, pageNo, pageSize,NumConstant.ONE_STR); + + return list.stream() + .map(dc -> new CoverageAnalisisDataListResultDTO(dc.getEnterpriseId(), categoryKey, + isPage ? categoryDict.getCategoryName() : null, placeType, isPage ? dc.getPlaceOrgName() : null, dc.getLatitude(), dc.getLongitude())) + .collect(Collectors.toList()); } return new ArrayList<>(); } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcEnterprisePatrolRecordDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcEnterprisePatrolRecordDao.xml index 6aa433eb09..313eedb9c3 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcEnterprisePatrolRecordDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcEnterprisePatrolRecordDao.xml @@ -12,6 +12,9 @@ and (e.AGENCY_ID = #{agencyId} or e.AGENCY_PIDS like CONCAT(#{staffOrgIds}, '%')) and e.PLACE_TYPE = #{categoryKey} and e.DEL_FLAG = '0' + + and e.LATEST_RESULT = #{latestResult} + @@ -34,5 +37,8 @@ and (e.AGENCY_ID = #{agencyId} or e.AGENCY_PIDS like CONCAT(#{staffOrgIds}, '%')) and e.PLACE_TYPE = #{categoryKey} and e.DEL_FLAG = '0' + + and e.LATEST_RESULT = #{latestResult} + \ No newline at end of file From e5a9a3be4fa14c0f230d4a1ecfca2396d7c161c5 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Thu, 28 Jul 2022 15:33:07 +0800 Subject: [PATCH 080/155] =?UTF-8?q?=E5=AE=89=E5=85=A8=E7=94=9F=E4=BA=A7?= =?UTF-8?q?=E9=9A=90=E6=82=A32?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/CoverageServiceImpl.java | 17 +++++++++-------- .../govorg/IcEnterprisePatrolRecordDao.xml | 8 ++++++-- 2 files changed, 15 insertions(+), 10 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index 3e4e824fda..0bb8752a16 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -43,10 +43,7 @@ import org.apache.commons.lang3.StringUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; +import java.util.*; import java.util.concurrent.atomic.AtomicReference; import java.util.stream.Collectors; @@ -323,7 +320,7 @@ public class CoverageServiceImpl implements CoverageService { } else if (PLACE_TYPE_SUPERIOR_RESOURCE.equals(placeType)) { // 优势资源 return orgCoverageService.countSuporiorResourceEntities(customerId, staffOrgIds, search, categoryKey); - } else if(CoveragePlaceTypeEnum.ENTERPRISE_PATROL_UNQUALIFIED.equals(placeType)){ + } else if(CoveragePlaceTypeEnum.ENTERPRISE_PATROL_UNQUALIFIED.getCode().equals(placeType)){ // 企事业单位巡查 // 最新巡查结果【0:合格 1:不合格】 return orgCoverageService.countEnterprisePatrol(customerId, agencyId, staffOrgIds, search, categoryKey,NumConstant.ONE_STR ); @@ -477,13 +474,16 @@ public class CoverageServiceImpl implements CoverageService { .map(dc -> new CoverageAnalisisDataListResultDTO(dc.getId(), categoryKey, isPage ? categoryDict.getCategoryName() : null, placeType, isPage ? dc.getName() : null, dc.getLatitude(), dc.getLongitude())) .collect(Collectors.toList()); - } else if(CoveragePlaceTypeEnum.ENTERPRISE_PATROL_UNQUALIFIED.equals(placeType)){ + } else if(CoveragePlaceTypeEnum.ENTERPRISE_PATROL_UNQUALIFIED.getCode().equals(placeType)){ + //最新巡查结果【0:合格 1:不合格】 List list = orgCoverageService.listEnterprisePatrol( customerId, agencyId, staffOrgIds, search, categoryKey, isPage, pageNo, pageSize,NumConstant.ONE_STR); return list.stream() .map(dc -> new CoverageAnalisisDataListResultDTO(dc.getEnterpriseId(), categoryKey, - isPage ? categoryDict.getCategoryName() : null, placeType, isPage ? dc.getPlaceOrgName() : null, dc.getLatitude(), dc.getLongitude())) + isPage ? categoryDict.getCategoryName() : null, placeType, dc.getPlaceOrgName() , + StringUtils.isNotBlank(dc.getLatitude()) ? dc.getLatitude() : rootAgency.getLatitude(), + StringUtils.isNotBlank(dc.getLongitude()) ? dc.getLongitude() : rootAgency.getLongitude())) .collect(Collectors.toList()); } return new ArrayList<>(); @@ -657,7 +657,8 @@ public class CoverageServiceImpl implements CoverageService { ); List list = new ArrayList<>(); if (CollectionUtils.isNotEmpty(page.getList())) { - Map> group = page.getList().stream().collect(Collectors.groupingBy(CoverageAnalisisDataListResultDTO::getLongLat)); + Map> group = page.getList().stream().collect(Collectors.groupingBy(x->Optional.ofNullable(x.getLongLat()).orElse("O"))); + if (MapUtils.isNotEmpty(group)) { for (Map.Entry> entry : group.entrySet()) { if (CollectionUtils.isEmpty(entry.getValue())) { diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcEnterprisePatrolRecordDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcEnterprisePatrolRecordDao.xml index 313eedb9c3..c682c31548 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcEnterprisePatrolRecordDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcEnterprisePatrolRecordDao.xml @@ -10,7 +10,9 @@ where e.CUSTOMER_ID = #{customerId} and e.PLACE_ORG_NAME like CONCAT('%',#{search},'%') and (e.AGENCY_ID = #{agencyId} or e.AGENCY_PIDS like CONCAT(#{staffOrgIds}, '%')) - and e.PLACE_TYPE = #{categoryKey} + + and e.PLACE_TYPE = #{categoryKey} + and e.DEL_FLAG = '0' and e.LATEST_RESULT = #{latestResult} @@ -35,7 +37,9 @@ where e.CUSTOMER_ID = #{customerId} and e.PLACE_ORG_NAME like CONCAT('%',#{search},'%') and (e.AGENCY_ID = #{agencyId} or e.AGENCY_PIDS like CONCAT(#{staffOrgIds}, '%')) - and e.PLACE_TYPE = #{categoryKey} + + and e.PLACE_TYPE = #{categoryKey} + and e.DEL_FLAG = '0' and e.LATEST_RESULT = #{latestResult} From 9f2c565e6812dea8b97d994cf04753ffe13f61c5 Mon Sep 17 00:00:00 2001 From: sunyuchao Date: Thu, 28 Jul 2022 15:33:27 +0800 Subject: [PATCH 081/155] =?UTF-8?q?=E8=81=94=E5=BB=BA=E5=8D=95=E4=BD=8D?= =?UTF-8?q?=E3=80=81=E7=A4=BE=E4=BC=9A=E8=87=AA=E7=BB=84=E7=BB=87=E5=88=A0?= =?UTF-8?q?=E9=99=A4=E6=97=B6=E5=A2=9E=E5=8A=A0=E5=88=A4=E6=96=AD=E6=98=AF?= =?UTF-8?q?=E5=90=A6=E5=90=8C=E6=AD=A5=E5=88=B0=E9=80=9A=E8=AE=AF=E5=BD=95?= =?UTF-8?q?=20=E6=98=AF=E5=90=A6=E6=9C=89=E6=9C=AA=E5=8A=9E=E7=BB=93?= =?UTF-8?q?=E9=A1=B9=E7=9B=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ...cCommunitySelfOrganizationServiceImpl.java | 30 +++++++++++++++-- .../service/impl/IcPartyUnitServiceImpl.java | 32 +++++++++++++++---- .../epmet/feign/GovOrgOpenFeignClient.java | 3 ++ .../GovOrgOpenFeignClientFallback.java | 5 +++ 4 files changed, 62 insertions(+), 8 deletions(-) diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcCommunitySelfOrganizationServiceImpl.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcCommunitySelfOrganizationServiceImpl.java index 195343850e..bdfe777e7c 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcCommunitySelfOrganizationServiceImpl.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcCommunitySelfOrganizationServiceImpl.java @@ -41,10 +41,12 @@ import com.epmet.dto.result.*; import com.epmet.dto.result.demand.OptionDTO; import com.epmet.entity.IcCommunitySelfOrganizationEntity; import com.epmet.entity.IcCommunitySelfOrganizationPersonnelEntity; +import com.epmet.entity.IcPartyUnitEntity; import com.epmet.excel.CommunitySelfOrgImportExcel; import com.epmet.excel.ImportCommunitySelfOrganization; import com.epmet.feign.EpmetAdminOpenFeignClient; import com.epmet.feign.EpmetCommonServiceOpenFeignClient; +import com.epmet.feign.GovOrgOpenFeignClient; import com.epmet.feign.OssFeignClient; import com.epmet.service.IcCommunitySelfOrganizationPersonnelService; import com.epmet.service.IcCommunitySelfOrganizationService; @@ -66,6 +68,7 @@ import org.springframework.transaction.annotation.Transactional; import org.springframework.web.multipart.MultipartFile; import org.springframework.web.multipart.commons.CommonsMultipartFile; +import javax.annotation.Resource; import javax.servlet.http.HttpServletResponse; import java.io.IOException; import java.io.InputStream; @@ -97,6 +100,8 @@ public class IcCommunitySelfOrganizationServiceImpl extends BaseServiceImpl page(Map params) { @@ -374,8 +379,29 @@ public class IcCommunitySelfOrganizationServiceImpl extends BaseServiceImpl NumConstant.ZERO) { throw new EpmetException(EpmetErrorCode.EPMET_COMMON_OPERATION_FAIL.getCode(), "存在未完成的服务", "存在未完成的服务,不能删除"); } - baseDao.deleteById(formDTO.getOrgId()); - personnelService.deleteByOrgId(formDTO.getOrgId()); + //校验是否有同步到通讯录,是否存在工作人员下有未处理项目数据【社会自组织被同步到通讯录部门的,如果部门下人员存在未办结项目则不允许删除】 + boolean bl = true; + IcCommunitySelfOrganizationEntity entity = baseDao.selectById(formDTO.getOrgId()); + if (null != entity && "sync".equals(entity.getSyncType())) { + CheckStaffInfoFormDTO dto = new CheckStaffInfoFormDTO(); + dto.setId(formDTO.getOrgId()); + dto.setDeptId(entity.getDeptId()); + dto.setDeptType("community_org"); + dto.setDeptStaffId(entity.getDeptStaffId()); + Result result = govOrgOpenFeignClient.notSyncDept(dto); + if (!result.success()) { + throw new EpmetException(EpmetErrorCode.EPMET_COMMON_OPERATION_FAIL.getCode(), "社会自组织删除,取消同步到通讯录数据失败", "社会自组织删除,取消同步到通讯录数据失败"); + } + if (!result.getData().getType()) { + throw new EpmetException(EpmetErrorCode.EPMET_COMMON_OPERATION_FAIL.getCode(), result.getData().getMsg(), result.getData().getMsg()); + } + bl = result.getData().getType(); + } + if (bl) { + baseDao.deleteById(formDTO.getOrgId()); + personnelService.deleteByOrgId(formDTO.getOrgId()); + } + } /** diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcPartyUnitServiceImpl.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcPartyUnitServiceImpl.java index 7b8df1b923..7c6ca5c81c 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcPartyUnitServiceImpl.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcPartyUnitServiceImpl.java @@ -59,10 +59,7 @@ import com.epmet.entity.IcCommunitySelfOrganizationEntity; import com.epmet.entity.IcPartyUnitEntity; import com.epmet.excel.IcPartyUnitImportExcel; import com.epmet.excel.IcPartyUnitImportFailedExcel; -import com.epmet.feign.EpmetAdminOpenFeignClient; -import com.epmet.feign.EpmetCommonServiceOpenFeignClient; -import com.epmet.feign.EpmetHeartOpenFeignClient; -import com.epmet.feign.OssFeignClient; +import com.epmet.feign.*; import com.epmet.service.IcCommunitySelfOrganizationService; import com.epmet.service.IcPartyUnitService; import com.epmet.service.IcServiceItemDictService; @@ -80,6 +77,7 @@ import org.apache.http.entity.ContentType; import org.apache.poi.ss.usermodel.Workbook; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; +import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.multipart.MultipartFile; import org.springframework.web.multipart.commons.CommonsMultipartFile; @@ -115,6 +113,8 @@ public class IcPartyUnitServiceImpl extends BaseServiceImpl search(PartyUnitFormDTO formDTO) { @@ -261,8 +261,28 @@ public class IcPartyUnitServiceImpl extends BaseServiceImpl NumConstant.ZERO) { throw new EpmetException(EpmetErrorCode.EPMET_COMMON_OPERATION_FAIL.getCode(), "存在未完成的服务", "存在未完成的服务,不能删除"); } - // 逻辑删除(@TableLogic 注解) - baseDao.deleteById(id); + //校验是否有同步到通讯录,是否存在工作人员下有未处理项目数据【联建单位被同步到通讯录部门的,如果部门下人员存在未办结项目则不允许删除】 + boolean bl = true; + IcPartyUnitEntity entity = baseDao.selectById(id); + if (null != entity && "sync".equals(entity.getSyncType())) { + CheckStaffInfoFormDTO dto = new CheckStaffInfoFormDTO(); + dto.setId(id); + dto.setDeptId(entity.getDeptId()); + dto.setDeptType("party_unit"); + dto.setDeptStaffId(entity.getDeptStaffId()); + Result result = govOrgOpenFeignClient.notSyncDept(dto); + if (!result.success()) { + throw new EpmetException(EpmetErrorCode.EPMET_COMMON_OPERATION_FAIL.getCode(), "联建单位删除,取消同步到通讯录数据失败", "联建单位删除,取消同步到通讯录数据失败"); + } + if (!result.getData().getType()) { + throw new EpmetException(EpmetErrorCode.EPMET_COMMON_OPERATION_FAIL.getCode(), result.getData().getMsg(), result.getData().getMsg()); + } + } + if (bl) { + // 逻辑删除(@TableLogic 注解) + baseDao.deleteById(id); + } + } /** diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/GovOrgOpenFeignClient.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/GovOrgOpenFeignClient.java index 7e2bcae37e..3abfbc588e 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/GovOrgOpenFeignClient.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/GovOrgOpenFeignClient.java @@ -705,4 +705,7 @@ public interface GovOrgOpenFeignClient { */ @PostMapping("/gov/org/ichouse/getOwnerHouseList") Result> getOwnerHouseList(@RequestBody IcHouseDTO formDTO); + + @PostMapping("/gov/org/department/notsyncdept") + Result notSyncDept(@RequestBody CheckStaffInfoFormDTO formDTO); } diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/fallback/GovOrgOpenFeignClientFallback.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/fallback/GovOrgOpenFeignClientFallback.java index f9046d5979..8d020c4538 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/fallback/GovOrgOpenFeignClientFallback.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/feign/fallback/GovOrgOpenFeignClientFallback.java @@ -459,4 +459,9 @@ public class GovOrgOpenFeignClientFallback implements GovOrgOpenFeignClient { return ModuleUtils.feignConError(ServiceConstant.GOV_ORG_SERVER, "getOwnerHouseList", formDTO); } + @Override + public Result notSyncDept(CheckStaffInfoFormDTO formDTO) { + return ModuleUtils.feignConError(ServiceConstant.GOV_ORG_SERVER, "notSyncDept", formDTO); + } + } From dd6aa8efbcbf8cfbbb027573d207b528c09892df Mon Sep 17 00:00:00 2001 From: sunyuchao Date: Thu, 28 Jul 2022 15:51:07 +0800 Subject: [PATCH 082/155] =?UTF-8?q?=E6=96=B0=E5=A2=9E=E8=81=94=E5=BB=BA?= =?UTF-8?q?=E5=8D=95=E4=BD=8D=E8=B4=9F=E8=B4=A3=E4=BA=BA=E3=80=81=E7=A4=BE?= =?UTF-8?q?=E5=8C=BA=E8=87=AA=E7=BB=84=E7=BB=87=E8=B4=9F=E8=B4=A3=E4=BA=BA?= =?UTF-8?q?=E4=B8=A4=E4=B8=AA=E9=BB=98=E8=AE=A4=E8=A7=92=E8=89=B2=E4=B8=8D?= =?UTF-8?q?=E5=85=81=E8=AE=B8=E5=88=A0=E9=99=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/java/com/epmet/dto/GovRoleDTO.java | 5 +++++ .../src/main/java/com/epmet/entity/GovRoleEntity.java | 5 +++++ .../java/com/epmet/service/impl/GovRoleServiceImpl.java | 7 +++++++ 3 files changed, 17 insertions(+) diff --git a/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/dto/GovRoleDTO.java b/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/dto/GovRoleDTO.java index f4b7ce74e9..0915ba9348 100644 --- a/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/dto/GovRoleDTO.java +++ b/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/dto/GovRoleDTO.java @@ -60,6 +60,11 @@ public class GovRoleDTO implements Serializable { */ private Long deptId; + /** + * 是否默认角色【0:否 1:是】 + */ + private String defaultRole; + /** * 删除标识:0.未删除 1.已删除 */ diff --git a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/entity/GovRoleEntity.java b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/entity/GovRoleEntity.java index 654bee9ce6..7db443d5db 100644 --- a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/entity/GovRoleEntity.java +++ b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/entity/GovRoleEntity.java @@ -46,4 +46,9 @@ public class GovRoleEntity extends BaseEpmetEntity { */ private String customerId; + /** + * 是否默认角色【0:否 1:是】 + */ + private String defaultRole; + } diff --git a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovRoleServiceImpl.java b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovRoleServiceImpl.java index c171d081d9..be20a94427 100644 --- a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovRoleServiceImpl.java +++ b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovRoleServiceImpl.java @@ -22,6 +22,8 @@ import com.baomidou.mybatisplus.core.metadata.IPage; import com.epmet.commons.mybatis.service.impl.BaseServiceImpl; import com.epmet.commons.tools.constant.FieldConstant; import com.epmet.commons.tools.constant.NumConstant; +import com.epmet.commons.tools.exception.EpmetErrorCode; +import com.epmet.commons.tools.exception.EpmetException; import com.epmet.commons.tools.exception.RenException; import com.epmet.commons.tools.page.PageData; import com.epmet.commons.tools.security.user.LoginUserUtil; @@ -116,6 +118,11 @@ public class GovRoleServiceImpl extends BaseServiceImpl Date: Thu, 28 Jul 2022 15:59:55 +0800 Subject: [PATCH 083/155] =?UTF-8?q?=E3=80=90=E5=9B=BE=E5=B1=82=E3=80=91?= =?UTF-8?q?=E5=8F=AF=E8=A7=86=E5=8C=96=EF=BC=8C=E5=81=9A=E4=BA=86=E4=B8=80?= =?UTF-8?q?=E4=BA=9B=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../tools/enums/CoveragePlaceTypeEnum.java | 2 +- .../AnalysisGovernedTargetsResult.java | 2 +- .../AnalysisResourceCategoriesResult.java | 6 +- .../govorg/IcCoverageCategoryDictEntity.java | 5 ++ .../service/impl/CoverageServiceImpl.java | 62 +++++++++---------- .../govorg/IcCoverageCategoryDictDao.xml | 1 + .../entity/IcCoverageCategoryDictEntity.java | 5 +- 7 files changed, 46 insertions(+), 37 deletions(-) diff --git a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoveragePlaceTypeEnum.java b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoveragePlaceTypeEnum.java index 3e68bf0503..6078970cb2 100644 --- a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoveragePlaceTypeEnum.java +++ b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoveragePlaceTypeEnum.java @@ -13,7 +13,7 @@ public enum CoveragePlaceTypeEnum { CITY_MANAGEMENT("city_management", "城市管理"), COMMUNITY_ORG("community_org", "社区自组织"), PUBLIC_SERVICE("public_service", "公共服务"), - RESI("resi", "居民"), + RESI("resi", "公共服务人群"), PARTY_UNIT("party_unit", "联建单位"), VOLUNTEER("volunteer", "志愿者"), GROUP_RENT("group_rent", "群租房"), diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/coverage/AnalysisGovernedTargetsResult.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/coverage/AnalysisGovernedTargetsResult.java index 56988054ba..a925663491 100644 --- a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/coverage/AnalysisGovernedTargetsResult.java +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/coverage/AnalysisGovernedTargetsResult.java @@ -19,7 +19,7 @@ public class AnalysisGovernedTargetsResult { private String coverageType; private String placeType; private String placeTypeName; - private Integer count = 0; + private Integer quantity = 0; private List children; } diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/coverage/AnalysisResourceCategoriesResult.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/coverage/AnalysisResourceCategoriesResult.java index 216c41f705..a6ab7996ab 100644 --- a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/coverage/AnalysisResourceCategoriesResult.java +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/coverage/AnalysisResourceCategoriesResult.java @@ -26,7 +26,7 @@ public class AnalysisResourceCategoriesResult { /** * 个数 */ - private Integer count; + private Integer quantity; /** * 没有placeTypeInAnalysis,直接属于图层的 @@ -49,7 +49,7 @@ public class AnalysisResourceCategoriesResult { private String categoryName; private String coverageType; private String placeType; - private Integer count = 0; + private Integer quantity = 0; } /** @@ -61,7 +61,7 @@ public class AnalysisResourceCategoriesResult { public static class PlaceType { private String placeType; private String placeTypeName; - private Integer count = 0; + private Integer quantity = 0; private List categories; } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCoverageCategoryDictEntity.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCoverageCategoryDictEntity.java index bc0ae5c9e2..1ea7222208 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCoverageCategoryDictEntity.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCoverageCategoryDictEntity.java @@ -60,6 +60,11 @@ public class IcCoverageCategoryDictEntity extends BaseEpmetEntity { private String dataType; + /** + * 数量 + */ + private Integer quantity; + /** * 排序 */ diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index dcc72dd756..1bb44635a4 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -251,41 +251,41 @@ public class CoverageServiceImpl implements CoverageService { public Integer doDataListCount(String customerId, String agencyId, String staffOrgIds, String placeType, String categoryKey, String search) { - if (PLACE_TYPE_RESI.equals(placeType)) { + if (CoveragePlaceTypeEnum.RESI.getCode().equals(placeType)) { // 使用分类查询居民信息 return icResiService.countResisByCategories4Coverage(customerId, agencyId, staffOrgIds, categoryKey, search); - } else if (PLACE_TYPE_SPECIAL_RESI.equals(placeType)) { + } else if (CoveragePlaceTypeEnum.SPECIAL_RESI.getCode().equals(placeType)) { // 特殊人群 return icResiService.countSpecialResisBySpecialType(customerId, agencyId, staffOrgIds, categoryKey, search); - } else if (PLACE_TYPE_EVENT.equals(placeType)) { + } else if (CoveragePlaceTypeEnum.EVENT.getCode().equals(placeType)) { // 难点痛点 return govProjectService.countIcEventEntities(customerId, staffOrgIds, search, true); - } else if (PLACE_TYPE_CITY_MANAGEMENT.equals(placeType)) { + } else if (CoveragePlaceTypeEnum.CITY_MANAGEMENT.getCode().equals(placeType)) { // 城市资源管理 return orgCoverageService.countCityResourceEntities(customerId, staffOrgIds, search, categoryKey); - } else if (PLACE_TYPE_COMUNITY_ORG.equals(placeType)) { + } else if (CoveragePlaceTypeEnum.COMMUNITY_ORG.getCode().equals(placeType)) { // 社区自组织 return heartService.countCommunityOrgEntities(customerId, agencyId, staffOrgIds, search, categoryKey); - } else if (PLACE_TYPE_PARTY_UNIT.equals(placeType)) { + } else if (CoveragePlaceTypeEnum.PARTY_UNIT.getCode().equals(placeType)) { // 机关直属部门(联建单位) 楼宇党建 0;两新组织 1;区域单位党建 2;机关直属部门 3;社会团体 4;民办非企业单位 5;基金会 6;其他 7 if (categoryKey.equals("pu_jgzsbm")) { String partyUnitType = "3"; return heartService.countPartyUnitEntities(customerId, agencyId, staffOrgIds, partyUnitType, search); } - } else if (PLACE_TYPE_DANGEROUS_CHEMICALS.equals(placeType)) { + } else if (CoveragePlaceTypeEnum.DANGEROUS_CHEMICALS.getCode().equals(placeType)) { // 危化企业 return orgCoverageService.countDangerousChemicalEntities(customerId, staffOrgIds, search, categoryKey); - } else if (PLACE_TYPE_ENTERPRISE_PARTROL.equals(placeType)) { + } else if (CoveragePlaceTypeEnum.ENTERPRISE_PATROL.getCode().equals(placeType)) { // 企事业单位巡查 return orgCoverageService.countEnterprisePatrol(customerId, agencyId, staffOrgIds, search, categoryKey); - } else if (PLACE_TYPE_GROUP_RENT.equals(placeType)) { + } else if (CoveragePlaceTypeEnum.GROUP_RENT.getCode().equals(placeType)) { // 群租房。出租的房屋,住的人口超过5人属于群租房(是个规定 return orgCoverageService.countByResiNumber(customerId, staffOrgIds, search, 5, HOUSE_RENT_FLAG_RENT); - } else if (PLACE_TYPE_PUBLIC_SERVICE.equals(placeType)) { + } else if (CoveragePlaceTypeEnum.PUBLIC_SERVICE.getCode().equals(placeType)) { // 公共服务 return orgCoverageService.countPublicServiceEntities(customerId, staffOrgIds, search, categoryKey); - } else if (PLACE_TYPE_SUPERIOR_RESOURCE.equals(placeType)) { + } else if (CoveragePlaceTypeEnum.SUPERIOR_RESOURCE.getCode().equals(placeType)) { // 优势资源 return orgCoverageService.countSuporiorResourceEntities(customerId, staffOrgIds, search, categoryKey); } @@ -311,7 +311,7 @@ public class CoverageServiceImpl implements CoverageService { // 根据categoryKey查询类别名称 IcCoverageCategoryDictEntity categoryDict = orgCoverageService.selectByCategoryKey(categoryKey); - if (PLACE_TYPE_RESI.equals(placeType)) { + if (CoveragePlaceTypeEnum.RESI.getCode().equals(placeType)) { // 使用分类查询居民信息 List resiEntities = icResiService.listResisByCategories4Coverage( customerId, agencyId, staffOrgIds, categoryKey, search, pageNo, pageSize, isPage); @@ -325,7 +325,7 @@ public class CoverageServiceImpl implements CoverageService { coordinates[1], coordinates[0]); }).collect(Collectors.toList()); - } else if (PLACE_TYPE_SPECIAL_RESI.equals(placeType)) { + } else if (CoveragePlaceTypeEnum.SPECIAL_RESI.getCode().equals(placeType)) { // 特殊人群 List resiInfos = icResiService.listSpecialResisBySpecialType( customerId, agencyId, staffOrgIds, categoryKey, search, pageNo, pageSize, isPage); @@ -338,7 +338,7 @@ public class CoverageServiceImpl implements CoverageService { isPage ? re.getName() : null, coordinates[1], coordinates[0]); }).collect(Collectors.toList()); - } else if (PLACE_TYPE_EVENT.equals(placeType)) { + } else if (CoveragePlaceTypeEnum.EVENT.getCode().equals(placeType)) { // 难点痛点 List icEventEntities = govProjectService.searchIcEventEntities( customerId, staffOrgIds, search, true, isPage, pageNo, pageSize); @@ -349,7 +349,7 @@ public class CoverageServiceImpl implements CoverageService { e.getLatitude(), e.getLongitude())) .collect(Collectors.toList()); - } else if (PLACE_TYPE_CITY_MANAGEMENT.equals(placeType)) { + } else if (CoveragePlaceTypeEnum.CITY_MANAGEMENT.getCode().equals(placeType)) { // 城市资源管理 List cityResources = orgCoverageService.searchCityResourceEntities( customerId, staffOrgIds, search, categoryKey, isPage, pageNo, pageSize); @@ -359,7 +359,7 @@ public class CoverageServiceImpl implements CoverageService { isPage ? resource.getName() : null, resource.getLatitude(), resource.getLongitude())) .collect(Collectors.toList()); - } else if (PLACE_TYPE_COMUNITY_ORG.equals(placeType)) { + } else if (CoveragePlaceTypeEnum.COMMUNITY_ORG.getCode().equals(placeType)) { // 社区自组织 List l = heartService.searchCommunityOrgEntities( customerId, agencyId, staffOrgIds, search, categoryKey, isPage, pageNo, pageSize); @@ -370,7 +370,7 @@ public class CoverageServiceImpl implements CoverageService { isPage ? org.getOrganizationName() : null, org.getLatitude(), org.getLongitude())) .collect(Collectors.toList()); - } else if (PLACE_TYPE_PARTY_UNIT.equals(placeType)) { + } else if (CoveragePlaceTypeEnum.PARTY_UNIT.getCode().equals(placeType)) { // 机关直属部门(联建单位) 楼宇党建 0;两新组织 1;区域单位党建 2;机关直属部门 3;社会团体 4;民办非企业单位 5;基金会 6;其他 7 if (categoryKey.equals("pu_jgzsbm")) { String partyUnitType = "3"; @@ -383,7 +383,7 @@ public class CoverageServiceImpl implements CoverageService { .collect(Collectors.toList()); } return new ArrayList<>(); - } else if (PLACE_TYPE_DANGEROUS_CHEMICALS.equals(placeType)) { + } else if (CoveragePlaceTypeEnum.DANGEROUS_CHEMICALS.getCode().equals(placeType)) { // 危化企业 List l = orgCoverageService.searchDangerousChemicalEntities( customerId, staffOrgIds, search, categoryKey, isPage, pageNo, pageSize); @@ -393,7 +393,7 @@ public class CoverageServiceImpl implements CoverageService { isPage ? categoryDict.getCategoryName() : null, placeType, isPage ? dc.getName() : null, dc.getLatitude(), dc.getLongitude())) .collect(Collectors.toList()); - } else if (PLACE_TYPE_ENTERPRISE_PARTROL.equals(placeType)) { + } else if (CoveragePlaceTypeEnum.ENTERPRISE_PATROL.getCode().equals(placeType)) { // 企事业单位巡查 List list = orgCoverageService.listEnterprisePatrol( customerId, agencyId, staffOrgIds, search, categoryKey, isPage, pageNo, pageSize); @@ -403,7 +403,7 @@ public class CoverageServiceImpl implements CoverageService { isPage ? categoryDict.getCategoryName() : null, placeType, isPage ? dc.getPlaceOrgName() : null, dc.getLatitude(), dc.getLongitude())) .collect(Collectors.toList()); - } else if (PLACE_TYPE_GROUP_RENT.equals(placeType)) { + } else if (CoveragePlaceTypeEnum.GROUP_RENT.getCode().equals(placeType)) { // 群租房。出租的房屋,住的人口超过5人属于群租房(是个规定 List houses = orgCoverageService.searchByResiNumber( customerId, staffOrgIds, search, 5, HOUSE_RENT_FLAG_RENT, isPage, pageNo, pageSize); @@ -421,7 +421,7 @@ public class CoverageServiceImpl implements CoverageService { isPage ? categoryDict.getCategoryName() : null, placeType, isPage ? houseName : null, latitude, longitude); }).collect(Collectors.toList()); - } else if (PLACE_TYPE_PUBLIC_SERVICE.equals(placeType)) { + } else if (CoveragePlaceTypeEnum.PUBLIC_SERVICE.getCode().equals(placeType)) { // 公共服务 List l = orgCoverageService.searchPublicServiceEntities( customerId, staffOrgIds, search, categoryKey, isPage, pageNo, pageSize); @@ -429,7 +429,7 @@ public class CoverageServiceImpl implements CoverageService { .map(dc -> new CoverageAnalisisDataListResultDTO(dc.getId(), categoryKey, isPage ? categoryDict.getCategoryName() : null, placeType, isPage ? dc.getName() : null, dc.getLatitude(), dc.getLongitude())) .collect(Collectors.toList()); - } else if (PLACE_TYPE_SUPERIOR_RESOURCE.equals(placeType)) { + } else if (CoveragePlaceTypeEnum.SUPERIOR_RESOURCE.getCode().equals(placeType)) { // 优势资源 List l = orgCoverageService.searchSuporiorResourceEntities( customerId, staffOrgIds, search, categoryKey, isPage, pageNo, pageSize); @@ -504,31 +504,31 @@ public class CoverageServiceImpl implements CoverageService { // 没有placetype的 categoriesOfThisCoverage.getCategories() .add(new AnalysisResourceCategoriesResult.Category(c.getCategoryKey(), c.getCategoryName(), - c.getCoverageType(), c.getPlaceType(), 0)); + c.getCoverageType(), c.getPlaceType(), c.getQuantity())); } else { // 有placetype的 AnalysisResourceCategoriesResult.PlaceType placeType = placeTypeMap.get(c.getPlaceTypeInAnalysis()); if (placeType == null) { placeType = new AnalysisResourceCategoriesResult.PlaceType( - c.getPlaceTypeInAnalysis(), CoveragePlaceTypeEnum.getEnum(c.getPlaceTypeInAnalysis()).getName(), 0, new ArrayList<>()); + c.getPlaceTypeInAnalysis(), CoveragePlaceTypeEnum.getEnum(c.getPlaceTypeInAnalysis()).getName(), c.getQuantity(), new ArrayList<>()); placeTypeMap.put(c.getPlaceTypeInAnalysis(), placeType); } placeType.getCategories().add(new AnalysisResourceCategoriesResult.Category(c.getCategoryKey(), - c.getCategoryName(), c.getCoverageType(), c.getPlaceType(), 0)); + c.getCategoryName(), c.getCoverageType(), c.getPlaceType(), c.getQuantity())); - placeType.setCount(placeType.getCount() + 0); // todo 0改为category的count + placeType.setQuantity(placeType.getQuantity() + c.getQuantity()); // todo 0改为category的count } }); AtomicReference total = new AtomicReference<>(0); placeTypeMap.forEach((placeTypeKey, placeType) -> { categoriesOfThisCoverage.getPlaceTypesInAnalysis().add(placeType); - total.updateAndGet(v -> v + placeType.getCount()); + total.updateAndGet(v -> v + placeType.getQuantity()); }); categoriesOfThisCoverage.setCoverageType(coverage.getKey()); categoriesOfThisCoverage.setCoverageName(CoverageEnums.getEnum(coverage.getKey()).getCoverageName()); - categoriesOfThisCoverage.setCount(total.get()); + categoriesOfThisCoverage.setQuantity(total.get()); results.add(categoriesOfThisCoverage); } @@ -553,7 +553,7 @@ public class CoverageServiceImpl implements CoverageService { if (StringUtils.isEmpty(placeTypeInAnalysis)) { // 只有一层,没有子级 results.add(new AnalysisGovernedTargetsResult(rc.getCategoryKey(), rc.getCategoryName(), rc.getCoverageType(), - rc.getPlaceType(), CoveragePlaceTypeEnum.getEnum(rc.getPlaceType()).getName(), 0, new ArrayList<>())); + rc.getPlaceType(), CoveragePlaceTypeEnum.getEnum(rc.getPlaceType()).getName(), rc.getQuantity(), new ArrayList<>())); } else { // 有子级,需要使用placeTypeInAnalysis分组 List targets = placeTypeMap.get(placeTypeInAnalysis); @@ -562,7 +562,7 @@ public class CoverageServiceImpl implements CoverageService { placeTypeMap.put(placeTypeInAnalysis, targets); } targets.add(new AnalysisGovernedTargetsResult(rc.getCategoryKey(), rc.getCategoryName(), rc.getCoverageType(), - rc.getPlaceType(), CoveragePlaceTypeEnum.getEnum(rc.getPlaceType()).getName(), 0, new ArrayList<>())); + rc.getPlaceType(), CoveragePlaceTypeEnum.getEnum(rc.getPlaceType()).getName(), rc.getQuantity(), new ArrayList<>())); } }); @@ -580,7 +580,7 @@ public class CoverageServiceImpl implements CoverageService { List categoriesNeed2Warn = icResiCategoryWarnService.listResiCategoriesNeed2Warn(EpmetRequestHolder.getLoginUserCustomerId()); List ggfwrqCategories = categoriesNeed2Warn.stream().map(wc -> new AnalysisGovernedTargetsResult(wc.getColumnName(), wc.getTableName(), - CoverageEnums.GGFW.getKey(), CoveragePlaceTypeEnum.RESI.getCode(), CoveragePlaceTypeEnum.RESI.getCode(), + CoverageEnums.GGFW.getKey(), CoveragePlaceTypeEnum.RESI.getCode(), CoveragePlaceTypeEnum.RESI.getName(), 0, new ArrayList<>())).collect(Collectors.toList()); AnalysisGovernedTargetsResult ggfwRq = new AnalysisGovernedTargetsResult(); diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryDictDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryDictDao.xml index 94da6bd60c..599659a43b 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryDictDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryDictDao.xml @@ -13,6 +13,7 @@ + diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcCoverageCategoryDictEntity.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcCoverageCategoryDictEntity.java index 25a4e47299..57fbe777e1 100755 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcCoverageCategoryDictEntity.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcCoverageCategoryDictEntity.java @@ -62,7 +62,10 @@ public class IcCoverageCategoryDictEntity extends BaseEpmetEntity { private String coverageType; private String dataType; - + /** + * 数量 + */ + private Integer quantity; /** * 排序 */ From 90d2d7b14aaef83583a47398cc6ff7532e21edc0 Mon Sep 17 00:00:00 2001 From: zxc <1272811460@qq.com> Date: Thu, 28 Jul 2022 16:10:32 +0800 Subject: [PATCH 084/155] =?UTF-8?q?=E6=9A=82=E6=8F=90=E6=90=9C=E7=B4=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../epmet/dataaggre/constant/OrgConstant.java | 4 + .../dataaggre/constant/TableConstant.java | 22 +++ .../form/CoverageHomeSearchFormDTO.java | 22 ++- .../result/CoverageHomeSearchResultDTO.java | 14 ++ .../dto/govorg/result/EventInfoResultDTO.java | 13 ++ .../govorg/result/ResourceInfoResultDTO.java | 45 ++++++ .../dto/govorg/result/UserInfoResultDTO.java | 23 +++ .../com/epmet/dataaggre/enums/MenusEnums.java | 75 +++++++++ .../data-aggregator-server/pom.xml | 5 + .../dao/epmetuser/IcResiUserDao.java | 12 +- .../dao/govorg/IcCityManagementDao.java | 43 +++++ .../dao/govorg/IcCoverageCategoryDictDao.java | 14 +- .../dataaggre/dao/govproject/IcEventDao.java | 13 ++ .../heart/IcCommunitySelfOrganizationDao.java | 7 + .../dataaggre/redis/GovCustomerMenuRedis.java | 109 +++++++++++++ .../service/epmetuser/IcResiService.java | 10 ++ .../epmetuser/impl/IcResiServiceImpl.java | 13 ++ .../service/govorg/GovOrgCoverageService.java | 10 ++ .../service/govorg/GovOrgService.java | 44 ++++- .../impl/GovOrgCoverageServiceImpl.java | 12 ++ .../govorg/impl/GovOrgServiceImpl.java | 30 +++- .../service/govproject/GovProjectService.java | 12 +- .../impl/GovProjectServiceImpl.java | 10 +- .../dataaggre/service/heart/HeartService.java | 4 + .../service/heart/impl/HeartServiceImpl.java | 8 +- .../service/impl/CoverageServiceImpl.java | 152 +++++++++++++++++- .../IcResiCategoryStatsConfigService.java | 9 ++ .../mapper/epmetuser/IcResiUserDao.xml | 20 +++ .../mapper/govorg/IcCityManagementDao.xml | 92 +++++++++++ .../govorg/IcCoverageCategoryDictDao.xml | 9 ++ .../mapper/govproject/IcEventDao.xml | 17 +- .../heart/IcCommunitySelfOrganizationDao.xml | 18 +++ 32 files changed, 877 insertions(+), 14 deletions(-) create mode 100644 epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/constant/TableConstant.java create mode 100644 epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/enums/MenusEnums.java create mode 100644 epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/redis/GovCustomerMenuRedis.java create mode 100644 epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/opercustomize/IcResiCategoryStatsConfigService.java diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/constant/OrgConstant.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/constant/OrgConstant.java index 28bc8e794c..d69b12c4e5 100644 --- a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/constant/OrgConstant.java +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/constant/OrgConstant.java @@ -17,4 +17,8 @@ public interface OrgConstant { String AGENCY_ID="agencyId"; String AGENC_PATH="agencyPath"; + + String SEARCH_TYPE_USER = "user"; + String SEARCH_TYPE_EVENT = "event"; + String SEARCH_TYPE_RESOURCE = "resource"; } diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/constant/TableConstant.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/constant/TableConstant.java new file mode 100644 index 0000000000..1e80e51d2f --- /dev/null +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/constant/TableConstant.java @@ -0,0 +1,22 @@ +package com.epmet.dataaggre.constant; + +/** + * + */ +public interface TableConstant { + + String IC_DANGEROUS_CHEMICALS = "ic_dangerous_chemicals"; + + String IC_SUPERIOR_RESOURCE = "ic_superior_resource"; + + String IC_ENTERPRISE = "ic_enterprise"; + + String IC_COMMUNITY_SELF_ORGANIZATION = "ic_community_self_organization"; + + String IC_CITY_MANAGEMENT = "ic_city_management"; + + String IC_PUBLIC_SERVICE = "ic_public_service"; + + String IC_EVENT = "ic_event"; + +} diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageHomeSearchFormDTO.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageHomeSearchFormDTO.java index 61ff9e4c07..49575e02fc 100644 --- a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageHomeSearchFormDTO.java +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageHomeSearchFormDTO.java @@ -1,5 +1,6 @@ package com.epmet.dataaggre.dto.govorg.form; +import com.epmet.commons.tools.dto.form.PageFormDTO; import lombok.Data; import java.io.Serializable; @@ -10,11 +11,30 @@ import java.io.Serializable; * @DESC */ @Data -public class CoverageHomeSearchFormDTO implements Serializable { +public class CoverageHomeSearchFormDTO extends PageFormDTO implements Serializable { private static final long serialVersionUID = 3776954636762201010L; private String name; + private String customerId; + private String userId; + + private String orgId; + + private String pids; + + private String tableName; + + /** + * 搜索类型,居民:user;事件:event;资源:resource + */ + private String searchType; + + /** + * 资源类型:社区自组织:community_org;优势资源:superior_resource;城市管理:city_management;重点危化企业:dangerous_chemicals;公共服务:public_service;企事业单位巡查:enterprise_patrol; + * searchType为resource时,此字段必填 + */ + private String resourceType; } diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/CoverageHomeSearchResultDTO.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/CoverageHomeSearchResultDTO.java index 59d65d5741..508c63b69c 100644 --- a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/CoverageHomeSearchResultDTO.java +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/CoverageHomeSearchResultDTO.java @@ -1,8 +1,10 @@ package com.epmet.dataaggre.dto.govorg.result; +import com.epmet.commons.tools.constant.NumConstant; import lombok.Data; import java.io.Serializable; +import java.util.ArrayList; import java.util.List; /** @@ -19,14 +21,26 @@ public class CoverageHomeSearchResultDTO implements Serializable { * 居民信息 */ private List userInfos; + private Long userInfosTotal; /** * 事件信息 */ private List eventInfos; + private Long eventInfoTotal; /** * 资源信息 */ private List resourceInfos; + private Long resourceInfoTotal; + + public CoverageHomeSearchResultDTO() { + this.userInfos = new ArrayList<>(); + this.userInfosTotal = NumConstant.ZERO_L; + this.eventInfos = new ArrayList<>(); + this.eventInfoTotal = NumConstant.ZERO_L; + this.resourceInfos = new ArrayList<>(); + this.resourceInfoTotal = NumConstant.ZERO_L; + } } diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/EventInfoResultDTO.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/EventInfoResultDTO.java index 18c6221410..60866d7c3f 100644 --- a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/EventInfoResultDTO.java +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/EventInfoResultDTO.java @@ -1,5 +1,6 @@ package com.epmet.dataaggre.dto.govorg.result; +import com.fasterxml.jackson.annotation.JsonIgnore; import lombok.Data; import java.io.Serializable; @@ -24,6 +25,9 @@ public class EventInfoResultDTO implements Serializable { */ private String gridName; + @JsonIgnore + private String gridId; + /** * 发生时间 yyyy-dd-mm hh:ii:ss */ @@ -43,4 +47,13 @@ public class EventInfoResultDTO implements Serializable { * 纬度 */ private String latitude; + + public EventInfoResultDTO() { + this.eventId = ""; + this.gridName = ""; + this.happenTime = ""; + this.eventContent = ""; + this.longitude = ""; + this.latitude = ""; + } } diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/ResourceInfoResultDTO.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/ResourceInfoResultDTO.java index 772d6fd69f..c82110c7e9 100644 --- a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/ResourceInfoResultDTO.java +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/ResourceInfoResultDTO.java @@ -28,4 +28,49 @@ public class ResourceInfoResultDTO implements Serializable { * 纬度 */ private String latitude; + + /** + * 分类名称 + */ + private String categoryName; + private String category; + + /** + * 占地面积 + */ + private String areaCovered; + + /** + * 容纳人数 + */ + private String capacity; + + /** + * 地址 + */ + private String address; + + /** + * 联系电话 + */ + private String mobile; + + /** + * 联系人 + */ + private String principal; + + public ResourceInfoResultDTO() { + this.resourceId = ""; + this.resourceType = ""; + this.name = ""; + this.longitude = ""; + this.latitude = ""; + this.categoryName = ""; + this.areaCovered = ""; + this.capacity = ""; + this.address = ""; + this.mobile = ""; + this.principal = ""; + } } diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/UserInfoResultDTO.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/UserInfoResultDTO.java index 971606c625..efc74c0517 100644 --- a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/UserInfoResultDTO.java +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/result/UserInfoResultDTO.java @@ -1,8 +1,10 @@ package com.epmet.dataaggre.dto.govorg.result; +import com.fasterxml.jackson.annotation.JsonIgnore; import lombok.Data; import java.io.Serializable; +import java.util.ArrayList; import java.util.List; /** @@ -27,11 +29,17 @@ public class UserInfoResultDTO implements Serializable { */ private String gridName; + @JsonIgnore + private String gridId; + /** * 所属房屋 */ private String houseName; + @JsonIgnore + private String homeId; + /** * 手机号 */ @@ -66,4 +74,19 @@ public class UserInfoResultDTO implements Serializable { * 纬度 */ private String latitude; + + public UserInfoResultDTO() { + this.icUserId = ""; + this.name = ""; + this.gridName = ""; + this.houseName = ""; + this.homeId = ""; + this.mobile = ""; + this.idCard = ""; + this.gzdw = ""; + this.rhqk = ""; + this.type = new ArrayList<>(); + this.longitude = ""; + this.latitude = ""; + } } diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/enums/MenusEnums.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/enums/MenusEnums.java new file mode 100644 index 0000000000..c777cd1281 --- /dev/null +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/enums/MenusEnums.java @@ -0,0 +1,75 @@ +package com.epmet.dataaggre.enums; + +import org.apache.commons.lang3.StringUtils; + +public enum MenusEnums { + + IC_DANGEROUS_CHEMICALS("shequzhili/tuceng/anquan/weihua/index","ic_dangerous_chemicals","重点危化品企业","govorg"), + IC_SUPERIOR_RESOURCE("shequzhili/tuceng/yingji/ziyuan/index","ic_superior_resource","优势资源管理","govorg"), + IC_ENTERPRISE("shequzhili/tuceng/anquan/xuncha/index","ic_enterprise","企事业单位巡查","govorg"), + IC_COMMUNITY_SELF_ORGANIZATION("communityService/sqzzz/index","ic_community_self_organization","社区自组织","heart"), + IC_CITY_MANAGEMENT("shequzhili/csgltc/csgl","ic_city_management","城市管理图层","govorg"), + IC_PUBLIC_SERVICE("shequzhili/ggfwtc/ggfw","ic_public_service","公共服务图层","govorg"), + IC_EVENT("shequzhili/event/eventList","ic_event","事件管理","govproject"); + + private String url; + private String value; + private String name; + private String db; + + MenusEnums(String url, String value, String name, String db) { + this.url = url; + this.value = value; + this.name = name; + this.db = db; + } + + public static MenusEnums get(String url) { + for (MenusEnums gm : MenusEnums.values()) { + if (gm.url.equals(url)) { + return gm; + } + } + return null; + } + + public static String getValueByUrl(String url){ + if (StringUtils.isBlank(url)){ + return ""; + } + for (MenusEnums me : MenusEnums.values()) { + if (me.url.equals(url)) { + return me.getValue(); + } + } + return ""; + } + + public static String getDbByValue(String table){ + if (StringUtils.isBlank(table)){ + return ""; + } + for (MenusEnums me : MenusEnums.values()) { + if (me.value.equals(table)) { + return me.getDb(); + } + } + return ""; + } + + public String getUrl() { + return url; + } + + public String getValue() { + return value; + } + + public String getName() { + return name; + } + + public String getDb() { + return db; + } +} diff --git a/epmet-module/data-aggregator/data-aggregator-server/pom.xml b/epmet-module/data-aggregator/data-aggregator-server/pom.xml index efa4bca631..1c61ede4bc 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/pom.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/pom.xml @@ -13,6 +13,11 @@ data-aggregator-server + + com.epmet + gov-access-client + 2.0.0 + com.epmet epmet-heart-client diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/epmetuser/IcResiUserDao.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/epmetuser/IcResiUserDao.java index 8705014852..9aaf933745 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/epmetuser/IcResiUserDao.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/epmetuser/IcResiUserDao.java @@ -21,6 +21,8 @@ import com.epmet.commons.mybatis.dao.BaseDao; import com.epmet.dataaggre.dto.epmetuser.form.ResisByPolicyRulesFormDTO; import com.epmet.dataaggre.dto.epmetuser.result.IcResiInfoResultDTO; import com.epmet.dataaggre.dto.epmetuser.result.ResiByPolicyInfoResultDTO; +import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; +import com.epmet.dataaggre.dto.govorg.result.UserInfoResultDTO; import com.epmet.dataaggre.dto.govproject.result.ProjectAnalysisResultDTO; import com.epmet.dataaggre.entity.epmetuser.IcResiUserEntity; import com.epmet.dto.IcResiUserDTO; @@ -28,7 +30,6 @@ import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Param; import java.util.List; -import java.util.Set; /** * 用户基础信息 @@ -98,4 +99,13 @@ public interface IcResiUserDao extends BaseDao { @Param("name") String name, @Param("resiRules") List resiRule, @Param("houseIds") List houseIds); + + /** + * Desc: 获取icUser + * @param formDTO + * @author zxc + * @date 2022/7/27 17:09 + */ + List getAllIcUser(CoverageHomeSearchFormDTO formDTO); + } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcCityManagementDao.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcCityManagementDao.java index 46e2005b33..5fcc8ac3c2 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcCityManagementDao.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcCityManagementDao.java @@ -1,9 +1,13 @@ package com.epmet.dataaggre.dao.govorg; import com.epmet.commons.mybatis.dao.BaseDao; +import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; +import com.epmet.dataaggre.dto.govorg.result.ResourceInfoResultDTO; import com.epmet.dataaggre.entity.govorg.IcCityManagementEntity; import org.apache.ibatis.annotations.Mapper; +import java.util.List; + /** * 城市管理图层 * @@ -13,5 +17,44 @@ import org.apache.ibatis.annotations.Mapper; @Mapper public interface IcCityManagementDao extends BaseDao { + /** + * Desc: 【资源】获取城市管理信息 + * @param formDTO + * @author zxc + * @date 2022/7/28 10:22 + */ + List getCityManageInfos(CoverageHomeSearchFormDTO formDTO); + + /** + * Desc: 【资源】获取公共服务信息 + * @param formDTO + * @author zxc + * @date 2022/7/28 10:22 + */ + List getPublicServiceInfos(CoverageHomeSearchFormDTO formDTO); + + /** + * Desc: 【资源】获取重点危化品企业信息 + * @param formDTO + * @author zxc + * @date 2022/7/28 10:22 + */ + List getDangerousChemicalsInfos(CoverageHomeSearchFormDTO formDTO); + + /** + * Desc: 【资源】获取优势资源信息 + * @param formDTO + * @author zxc + * @date 2022/7/28 10:22 + */ + List getSuperiorResourceInfos(CoverageHomeSearchFormDTO formDTO); + + /** + * Desc: 【资源】获取企事业单位巡查信息 + * @param formDTO + * @author zxc + * @date 2022/7/28 10:22 + */ + List getEnterpriseInfos(CoverageHomeSearchFormDTO formDTO); } \ No newline at end of file diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcCoverageCategoryDictDao.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcCoverageCategoryDictDao.java index e81167fc39..8c438b9119 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcCoverageCategoryDictDao.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcCoverageCategoryDictDao.java @@ -3,6 +3,9 @@ package com.epmet.dataaggre.dao.govorg; import com.epmet.commons.mybatis.dao.BaseDao; import com.epmet.dataaggre.entity.govorg.IcCoverageCategoryDictEntity; import org.apache.ibatis.annotations.Mapper; +import org.apache.ibatis.annotations.Param; + +import java.util.List; /** * 五大图层类别字典表 @@ -12,5 +15,14 @@ import org.apache.ibatis.annotations.Mapper; */ @Mapper public interface IcCoverageCategoryDictDao extends BaseDao { - + + /** + * Desc: 根据客户ID和数据类型获取字典对应的url + * @param customerId + * @param dataType + * @author zxc + * @date 2022/7/27 16:52 + */ + List getAllTypeCoverageByCustomerAndType(@Param("customerId") String customerId, @Param("dataType") String dataType); + } \ No newline at end of file diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govproject/IcEventDao.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govproject/IcEventDao.java index c2305c3afc..7cbb6dd87f 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govproject/IcEventDao.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govproject/IcEventDao.java @@ -1,9 +1,13 @@ package com.epmet.dataaggre.dao.govproject; import com.epmet.commons.mybatis.dao.BaseDao; +import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; +import com.epmet.dataaggre.dto.govorg.result.EventInfoResultDTO; import com.epmet.dataaggre.entity.govproject.IcEventEntity; import org.apache.ibatis.annotations.Mapper; +import java.util.List; + /** * 事件管理表 * @@ -12,4 +16,13 @@ import org.apache.ibatis.annotations.Mapper; */ @Mapper public interface IcEventDao extends BaseDao { + + /** + * Desc: 【资源】获取事件信息 + * @param formDTO + * @author zxc + * @date 2022/7/28 10:48 + */ + List getEventInfos(CoverageHomeSearchFormDTO formDTO); + } \ No newline at end of file diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/heart/IcCommunitySelfOrganizationDao.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/heart/IcCommunitySelfOrganizationDao.java index 2499308cf6..2aab1d0be0 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/heart/IcCommunitySelfOrganizationDao.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/heart/IcCommunitySelfOrganizationDao.java @@ -18,9 +18,13 @@ package com.epmet.dataaggre.dao.heart; import com.epmet.commons.mybatis.dao.BaseDao; +import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; +import com.epmet.dataaggre.dto.govorg.result.ResourceInfoResultDTO; import com.epmet.dataaggre.entity.heart.IcCommunitySelfOrganizationEntity; import org.apache.ibatis.annotations.Mapper; +import java.util.List; + /** * 社区自组织表 * @@ -29,4 +33,7 @@ import org.apache.ibatis.annotations.Mapper; */ @Mapper public interface IcCommunitySelfOrganizationDao extends BaseDao { + + List getCommunitySelOrgInfos(CoverageHomeSearchFormDTO formDTO); + } \ No newline at end of file diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/redis/GovCustomerMenuRedis.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/redis/GovCustomerMenuRedis.java new file mode 100644 index 0000000000..fbeca4840e --- /dev/null +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/redis/GovCustomerMenuRedis.java @@ -0,0 +1,109 @@ +package com.epmet.dataaggre.redis; + +import cn.hutool.core.bean.BeanUtil; +import com.alibaba.fastjson.JSON; +import com.epmet.commons.tools.constant.NumConstant; +import com.epmet.commons.tools.exception.EpmetException; +import com.epmet.commons.tools.redis.RedisKeys; +import com.epmet.commons.tools.redis.RedisUtils; +import com.epmet.commons.tools.utils.ConvertUtils; +import com.epmet.commons.tools.utils.Result; +import com.epmet.dto.GovMenuDTO; +import com.epmet.dto.form.GetCustomerMenuListFormDTO; +import com.epmet.feign.GovAccessFeignClient; +import lombok.extern.slf4j.Slf4j; +import org.apache.commons.lang3.StringUtils; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Component; +import org.springframework.util.CollectionUtils; + +import java.util.ArrayList; +import java.util.List; +import java.util.Map; + +/** + * 客户菜单配置表 + * + * @author generator generator@elink-cn.com + * @since v1.0.0 2021-03-16 + */ +@Slf4j +@Component +public class GovCustomerMenuRedis { + @Autowired + private RedisUtils redisUtils; + + @Autowired + private GovAccessFeignClient govAccessFeignClient; + + /** + * Desc: 保存客户菜单缓存 + * @param customerId + * @param type + * @param govMenuDTOS + * @author zxc + * @date 2022/7/27 13:45 + */ + public void setCustomerMenuList(String customerId, Integer type, List govMenuDTOS) { + if (checkParam(customerId, type) && !CollectionUtils.isEmpty(govMenuDTOS) && StringUtils.isNotBlank(govMenuDTOS.get(NumConstant.ZERO).getName())) { + String key = RedisKeys.getCustomerMenuListFiveCoverage().concat(customerId); + govMenuDTOS.forEach(g -> { + Map map = BeanUtil.beanToMap(g, false, true); + redisUtils.listAdd(key,map); + }); + } + } + + /** + * Desc: 获取客户菜单缓存 + * @param customerId + * @param type + * @param tableName + * @author zxc + * @date 2022/7/27 13:45 + */ + public List getCustomerMenuList(String customerId, Integer type, String tableName) { + if (checkParam(customerId, type)) { + String key = RedisKeys.getCustomerMenuListFiveCoverage().concat(customerId); + List result = new ArrayList<>(); + List> maps = (List>) redisUtils.listGetAll(key, NumConstant.ZERO, NumConstant.ONE_NEG); + for (Map map : maps) { + result.add(ConvertUtils.mapToEntity(map,GovMenuDTO.class)); + } +// result = (List) redisUtils.listGetAll(key, NumConstant.ZERO,NumConstant.ONE_NEG); + if (CollectionUtils.isEmpty(result)){ + GetCustomerMenuListFormDTO formDTO = new GetCustomerMenuListFormDTO(); + formDTO.setCustomerId(customerId); + formDTO.setType(type); + formDTO.setTableName(tableName); + Result> customerMenuList = govAccessFeignClient.getCustomerMenuList(formDTO); + if (!customerMenuList.success()){ + throw new EpmetException("查询客户菜单失败"+ JSON.toJSONString(formDTO)); + } + result = customerMenuList.getData(); + setCustomerMenuList(customerId,type,customerMenuList.getData()); + } + return result; + } + return new ArrayList<>(); + } + + /** + * Desc: 删除客户菜单缓存 + * @param + * @author zxc + * @date 2022/7/27 13:47 + */ + public void delAllCustomerMenu(String customerId) { + String key = RedisKeys.getCustomerMenuListFiveCoverage().concat(customerId); + redisUtils.delete(key); + } + + private boolean checkParam(String customerId, Integer type) { + if (StringUtils.isBlank(customerId) || type == null){ + log.warn("checkParam fail, param is null"); + return false; + } + return true; + } +} diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/IcResiService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/IcResiService.java index 1900b75e89..c8d7f5ca36 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/IcResiService.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/IcResiService.java @@ -1,6 +1,8 @@ package com.epmet.dataaggre.service.epmetuser; import com.epmet.dataaggre.dto.epmetuser.result.IcResiInfoResultDTO; +import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; +import com.epmet.dataaggre.dto.govorg.result.UserInfoResultDTO; import com.epmet.dataaggre.entity.epmetuser.IcResiUserEntity; import java.util.List; @@ -39,4 +41,12 @@ public interface IcResiService { Integer pageNo, Integer pageSize, Boolean isPage); Integer countSpecialResisBySpecialType(String customerId, String agencyId, String staffOrgIds, String categoryKey, String search); + + /** + * Desc: 获取icUser + * @param formDTO + * @author zxc + * @date 2022/7/27 17:09 + */ + List getAllIcUser(CoverageHomeSearchFormDTO formDTO); } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/IcResiServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/IcResiServiceImpl.java index 74ba309792..5aa7c8d3a31 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/IcResiServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/IcResiServiceImpl.java @@ -5,6 +5,8 @@ import com.epmet.commons.dynamic.datasource.annotation.DataSource; import com.epmet.dataaggre.constant.DataSourceConstant; import com.epmet.dataaggre.dao.epmetuser.IcResiUserDao; import com.epmet.dataaggre.dto.epmetuser.result.IcResiInfoResultDTO; +import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; +import com.epmet.dataaggre.dto.govorg.result.UserInfoResultDTO; import com.epmet.dataaggre.entity.epmetuser.IcResiUserEntity; import com.epmet.dataaggre.service.epmetuser.IcResiService; import com.github.pagehelper.PageHelper; @@ -100,4 +102,15 @@ public class IcResiServiceImpl implements IcResiService { public Integer countSpecialResisBySpecialType(String customerId, String agencyId, String staffOrgIds, String categoryKey, String search) { return resiUserDao.countSpecialResisBySpecialType(customerId, agencyId, staffOrgIds, categoryKey, search); } + + /** + * Desc: 获取icUser + * @param formDTO + * @author zxc + * @date 2022/7/27 17:09 + */ + @Override + public List getAllIcUser(CoverageHomeSearchFormDTO formDTO) { + return resiUserDao.getAllIcUser(formDTO); + } } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java index 10b94f81d9..b13cd75b74 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java @@ -135,6 +135,16 @@ public interface GovOrgCoverageService { */ IcCoverageCategoryDictEntity selectByCategoryKey(String categoryKey); + List listCoverageCategoryEntities(String coverageType); + + /** + * Desc: 根据客户ID和数据类型获取字典对应的url + * @param customerId + * @param dataType + * @author zxc + * @date 2022/7/27 16:52 + */ + List getAllTypeCoverageByCustomerAndType(String customerId,String dataType); List listResourceCategoryEntities(String coverageType); List listGovernedTargetCategoryEntities(); diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgService.java index ee502bd493..adc04ab316 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgService.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgService.java @@ -11,13 +11,10 @@ import com.epmet.dataaggre.dto.govorg.form.*; import com.epmet.dataaggre.dto.govorg.result.*; import com.epmet.dataaggre.dto.resigroup.result.OrgInfoCommonDTO; import com.epmet.dataaggre.entity.govorg.CustomerAgencyEntity; -import com.epmet.dataaggre.entity.govorg.IcHouseEntity; import com.epmet.dto.IcNeighborHoodDTO; -import com.epmet.dto.result.NeighborHoodListResultDTO; import javax.servlet.http.HttpServletResponse; import java.util.List; -import java.util.Set; /** * @Author zxc @@ -223,4 +220,45 @@ public interface GovOrgService { List statRule, Integer pageNo, Integer pageSize); List neighborhoodsByIds(List neighborhoodIds); + + /** + * Desc: 【资源】获取城市管理信息 + * @param formDTO + * @author zxc + * @date 2022/7/28 10:22 + */ + List getCityManageInfos(CoverageHomeSearchFormDTO formDTO); + + /** + * Desc: 【资源】获取公共服务信息 + * @param formDTO + * @author zxc + * @date 2022/7/28 10:22 + */ + List getPublicServiceInfos(CoverageHomeSearchFormDTO formDTO); + + /** + * Desc: 【资源】获取重点危化品企业信息 + * @param formDTO + * @author zxc + * @date 2022/7/28 10:22 + */ + List getDangerousChemicalsInfos(CoverageHomeSearchFormDTO formDTO); + + /** + * Desc: 【资源】获取优势资源信息 + * @param formDTO + * @author zxc + * @date 2022/7/28 10:22 + */ + List getSuperiorResourceInfos(CoverageHomeSearchFormDTO formDTO); + + /** + * Desc: 【资源】获取企事业单位巡查信息 + * @param formDTO + * @author zxc + * @date 2022/7/28 10:22 + */ + List getEnterpriseInfos(CoverageHomeSearchFormDTO formDTO); + } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java index e2987a1233..56b32dad29 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java @@ -346,4 +346,16 @@ public class GovOrgCoverageServiceImpl implements GovOrgCoverageService { query.eq(IcCoverageCategoryDictEntity::getDataType, CoverageEnums.DATA_TYPE_GOVERNED_TARGET.getKey()); return coverageCategoryDictDao.selectList(query); } + + /** + * Desc: 根据客户ID和数据类型获取字典对应的url + * @param customerId + * @param dataType + * @author zxc + * @date 2022/7/27 16:52 + */ + @Override + public List getAllTypeCoverageByCustomerAndType(String customerId, String dataType) { + return coverageCategoryDictDao.getAllTypeCoverageByCustomerAndType(customerId, dataType); + } } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgServiceImpl.java index 86999e17bd..4eaab080a5 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgServiceImpl.java @@ -5,7 +5,6 @@ import cn.afterturn.easypoi.excel.entity.ExportParams; import cn.afterturn.easypoi.excel.entity.enmus.ExcelType; import com.alibaba.fastjson.JSON; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; -import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.dingtalk.api.request.OapiRobotSendRequest; import com.epmet.commons.dynamic.datasource.annotation.DataSource; import com.epmet.commons.tools.constant.Constant; @@ -27,7 +26,6 @@ import com.epmet.commons.tools.redis.common.bean.BuildingInfoCache; import com.epmet.commons.tools.redis.common.bean.GridInfoCache; import com.epmet.commons.tools.security.dto.TokenDto; import com.epmet.commons.tools.utils.ConvertUtils; -import com.epmet.commons.tools.utils.EpmetRequestHolder; import com.epmet.commons.tools.utils.HttpClientManager; import com.epmet.commons.tools.utils.Result; import com.epmet.dataaggre.constant.DataSourceConstant; @@ -41,7 +39,6 @@ import com.epmet.dataaggre.dto.govorg.form.*; import com.epmet.dataaggre.dto.govorg.result.*; import com.epmet.dataaggre.dto.resigroup.result.OrgInfoCommonDTO; import com.epmet.dataaggre.entity.govorg.CustomerAgencyEntity; -import com.epmet.dataaggre.entity.govorg.IcHouseEntity; import com.epmet.dataaggre.excel.GridLivelyDetailExcel; import com.epmet.dataaggre.excel.GridLivelyExcel; import com.epmet.dataaggre.service.commonservice.AreaCodeService; @@ -117,6 +114,8 @@ public class GovOrgServiceImpl implements GovOrgService { private IcHouseDao houseDao; @Autowired private IcNeighborhoodDao neighborhoodDao; + @Autowired + private IcCityManagementDao cityManagementDao; /** * @param staffId @@ -1130,4 +1129,29 @@ public class GovOrgServiceImpl implements GovOrgService { public List neighborhoodsByIds(List neighborhoodIds) { return neighborhoodDao.neighborhoodsByIds(neighborhoodIds); } + + @Override + public List getCityManageInfos(CoverageHomeSearchFormDTO formDTO) { + return cityManagementDao.getCityManageInfos(formDTO); + } + + @Override + public List getPublicServiceInfos(CoverageHomeSearchFormDTO formDTO) { + return cityManagementDao.getPublicServiceInfos(formDTO); + } + + @Override + public List getDangerousChemicalsInfos(CoverageHomeSearchFormDTO formDTO) { + return cityManagementDao.getDangerousChemicalsInfos(formDTO); + } + + @Override + public List getSuperiorResourceInfos(CoverageHomeSearchFormDTO formDTO) { + return cityManagementDao.getSuperiorResourceInfos(formDTO); + } + + @Override + public List getEnterpriseInfos(CoverageHomeSearchFormDTO formDTO) { + return cityManagementDao.getEnterpriseInfos(formDTO); + } } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/GovProjectService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/GovProjectService.java index 44ec60c4cd..e64525a1fc 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/GovProjectService.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/GovProjectService.java @@ -2,10 +2,12 @@ package com.epmet.dataaggre.service.govproject; import com.epmet.commons.tools.security.dto.TokenDto; import com.epmet.dataaggre.dto.govissue.result.IssueListResultDTO; +import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; +import com.epmet.dataaggre.dto.govorg.result.EventInfoResultDTO; +import com.epmet.dataaggre.dto.govorg.result.ResourceInfoResultDTO; import com.epmet.dataaggre.dto.govproject.form.*; import com.epmet.dataaggre.dto.govproject.result.*; import com.epmet.dataaggre.entity.govproject.IcEventEntity; -import com.sun.org.apache.xpath.internal.operations.Bool; import java.util.LinkedList; import java.util.List; @@ -121,4 +123,12 @@ public interface GovProjectService { List searchIcEventEntities(String customerId, String staffOrgIds, String search, Boolean isDifficultPoint, Boolean isPage, Integer pageNo, Integer pageSize); + /** + * Desc: 【资源】获取事件信息 + * @param formDTO + * @author zxc + * @date 2022/7/28 10:48 + */ + List getEventInfos(CoverageHomeSearchFormDTO formDTO); + } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/impl/GovProjectServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/impl/GovProjectServiceImpl.java index de4c2c2bc5..0a400fe927 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/impl/GovProjectServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/impl/GovProjectServiceImpl.java @@ -26,6 +26,9 @@ import com.epmet.dataaggre.dto.datastats.result.FactAgencyProjectResultDTO; import com.epmet.dataaggre.dto.govissue.IssueProjectCategoryDictDTO; import com.epmet.dataaggre.dto.govissue.result.IssueInfoDTO; import com.epmet.dataaggre.dto.govissue.result.IssueListResultDTO; +import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; +import com.epmet.dataaggre.dto.govorg.result.EventInfoResultDTO; +import com.epmet.dataaggre.dto.govorg.result.ResourceInfoResultDTO; import com.epmet.dataaggre.dto.govproject.ProjectDTO; import com.epmet.dataaggre.dto.govproject.ProjectRelatedPersonnelDTO; import com.epmet.dataaggre.dto.govproject.ResiEventDTO; @@ -665,7 +668,12 @@ public class GovProjectServiceImpl implements GovProjectService { return icEventDao.selectList(query); } - /** + @Override + public List getEventInfos(CoverageHomeSearchFormDTO formDTO) { + return icEventDao.getEventInfos(formDTO); + } + + /** * 构造事件查询 * @param customerId * @param staffOrgIds diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/heart/HeartService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/heart/HeartService.java index e1b4e3692b..d97044b718 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/heart/HeartService.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/heart/HeartService.java @@ -1,5 +1,7 @@ package com.epmet.dataaggre.service.heart; +import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; +import com.epmet.dataaggre.dto.govorg.result.ResourceInfoResultDTO; import com.epmet.dataaggre.entity.heart.IcCommunitySelfOrganizationEntity; import com.epmet.dataaggre.entity.heart.IcPartyUnitEntity; @@ -40,4 +42,6 @@ public interface HeartService { Integer countPartyUnitEntities(String customerId, String agencyId, String staffOrgIds, String partyUnitType, String search); Integer countCommunityOrgEntities(String customerId, String agencyId, String staffOrgIds, String search, String categoryKey); + + List getCommunitySelOrgInfos(CoverageHomeSearchFormDTO formDTO); } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/heart/impl/HeartServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/heart/impl/HeartServiceImpl.java index c29f54c5ff..314c5d7672 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/heart/impl/HeartServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/heart/impl/HeartServiceImpl.java @@ -5,10 +5,11 @@ import com.epmet.commons.dynamic.datasource.annotation.DataSource; import com.epmet.dataaggre.constant.DataSourceConstant; import com.epmet.dataaggre.dao.heart.IcCommunitySelfOrganizationDao; import com.epmet.dataaggre.dao.heart.IcPartyUnitDao; +import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; +import com.epmet.dataaggre.dto.govorg.result.ResourceInfoResultDTO; import com.epmet.dataaggre.entity.heart.IcCommunitySelfOrganizationEntity; import com.epmet.dataaggre.entity.heart.IcPartyUnitEntity; import com.epmet.dataaggre.service.heart.HeartService; -import com.epmet.dto.result.PartyMemberUserIdsResultDTO; import com.github.pagehelper.PageHelper; import org.apache.commons.lang3.StringUtils; import org.springframework.beans.factory.annotation.Autowired; @@ -57,6 +58,11 @@ public class HeartServiceImpl implements HeartService { return communitySelfOrganizationDao.selectCount(query); } + @Override + public List getCommunitySelOrgInfos(CoverageHomeSearchFormDTO formDTO) { + return communitySelfOrganizationDao.getCommunitySelOrgInfos(formDTO); + } + private LambdaQueryWrapper constructCommunityOrgQueryWrapper( String customerId, String agencyId, String staffOrgIds, String search, String categoryKey) { LambdaQueryWrapper query = new LambdaQueryWrapper<>(); diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index 0a34e94edc..4f9216b5d4 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -15,6 +15,8 @@ import com.epmet.commons.tools.redis.common.bean.BuildingInfoCache; import com.epmet.commons.tools.utils.EpmetRequestHolder; import com.epmet.dataaggre.constant.OrgConstant; import com.epmet.dataaggre.dto.coverage.AnalysisGovernedTargetsResult; +import com.epmet.dataaggre.constant.OrgConstant; +import com.epmet.dataaggre.constant.TableConstant; import com.epmet.dataaggre.dto.coverage.AnalysisResourceCategoriesResult; import com.epmet.dataaggre.dto.epmetuser.result.IcResiInfoResultDTO; import com.epmet.dataaggre.dto.govorg.form.CoverageAnalisisDataListLeftFormDTO; @@ -23,11 +25,14 @@ import com.epmet.dataaggre.dto.govorg.result.CoverageAnalisisDataListResultDTO; import com.epmet.dataaggre.dto.govorg.result.CoverageAnalisisDataListResultDTOV2; import com.epmet.dataaggre.dto.govorg.result.CoverageHomeSearchResultDTO; import com.epmet.dataaggre.dto.govorg.result.IcEnterisePatrolResultDTO; +import com.epmet.dataaggre.dto.govorg.result.*; import com.epmet.dataaggre.entity.epmetuser.IcResiUserEntity; import com.epmet.dataaggre.entity.govorg.*; import com.epmet.dataaggre.entity.govproject.IcEventEntity; import com.epmet.dataaggre.entity.heart.IcCommunitySelfOrganizationEntity; import com.epmet.dataaggre.entity.heart.IcPartyUnitEntity; +import com.epmet.dataaggre.enums.MenusEnums; +import com.epmet.dataaggre.redis.GovCustomerMenuRedis; import com.epmet.dataaggre.entity.opercustomize.IcResiCategoryWarnConfigEntity; import com.epmet.dataaggre.service.CoverageService; import com.epmet.dataaggre.service.epmetuser.IcResiService; @@ -35,6 +40,9 @@ import com.epmet.dataaggre.service.govorg.GovOrgCoverageService; import com.epmet.dataaggre.service.govorg.GovOrgService; import com.epmet.dataaggre.service.govproject.GovProjectService; import com.epmet.dataaggre.service.heart.HeartService; +import com.epmet.dto.GovMenuDTO; +import com.github.pagehelper.PageHelper; +import com.github.pagehelper.PageInfo; import com.epmet.dataaggre.service.opercustomize.IcResiCategoryWarnService; import lombok.extern.slf4j.Slf4j; import org.apache.commons.collections4.CollectionUtils; @@ -69,6 +77,9 @@ public class CoverageServiceImpl implements CoverageService { @Autowired private GovOrgCoverageService govOrgCoverageService; + @Autowired + private GovCustomerMenuRedis govCustomerMenuRedis; + @Autowired private IcResiCategoryWarnService icResiCategoryWarnService; @@ -217,7 +228,146 @@ public class CoverageServiceImpl implements CoverageService { */ @Override public CoverageHomeSearchResultDTO coverageHomeSearch(CoverageHomeSearchFormDTO formDTO) { - return null; + String customerId = formDTO.getCustomerId(); + CustomerStaffInfoCacheResult staffInfo = CustomerStaffRedis.getStaffInfo(customerId, formDTO.getUserId()); + if (null == staffInfo){ + throw new EpmetException("查询工作人员失败:"+formDTO.getUserId()); + } + formDTO.setOrgId(staffInfo.getAgencyId()); + CoverageHomeSearchResultDTO result = new CoverageHomeSearchResultDTO(); + // 缓存的客户菜单 + List customerMenuList = govCustomerMenuRedis.getCustomerMenuList(customerId, 0, "gov_menu"); + // org库配置的 + List resources = govOrgCoverageService.getAllTypeCoverageByCustomerAndType(customerId, "resources"); + if (CollectionUtils.isEmpty(resources)){ + return result; + } + if (CollectionUtils.isEmpty(customerMenuList)){ + return result; + } + List tables = new ArrayList<>(); + customerMenuList.forEach(cm -> { + resources.forEach(r -> { + if (cm.getUrl().equals(r)){ + String tableName = MenusEnums.getValueByUrl(r); + if (StringUtils.isNotBlank(tableName)){ + tables.add(tableName); + } + } + }); + }); + if (CollectionUtils.isEmpty(tables)){ + return result; + } + if (StringUtils.isNotBlank(formDTO.getSearchType())){ + if (formDTO.getSearchType().equals(OrgConstant.SEARCH_TYPE_USER)){ + PageInfo allIcUserPageInfo = getIcUserPageInfo(formDTO); + result.setUserInfos(allIcUserPageInfo.getList()); + result.setUserInfosTotal(allIcUserPageInfo.getTotal()); + }else if (formDTO.getSearchType().equals(OrgConstant.SEARCH_TYPE_EVENT)){ + for (String resource : resources) { + if (MenusEnums.IC_EVENT.getUrl().equals(resource)){ + PageInfo eventPageInfo = getEventInfo(formDTO); + result.setEventInfos(eventPageInfo.getList()); + result.setEventInfoTotal(eventPageInfo.getTotal()); + break; + } + } + }else if (formDTO.getSearchType().equals(OrgConstant.SEARCH_TYPE_RESOURCE)){ + + } + }else { + // 查询居民 + PageInfo allIcUserPageInfo = getIcUserPageInfo(formDTO); + result.setUserInfos(allIcUserPageInfo.getList()); + result.setUserInfosTotal(allIcUserPageInfo.getTotal()); + List reInfos = new ArrayList<>(); + for (String table : tables) { + switch (table){ + case TableConstant.IC_SUPERIOR_RESOURCE: + PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize(),formDTO.getIsPage()).doSelectPageInfo(() -> govOrgService.getSuperiorResourceInfos(formDTO)); + List superiorResourceInfos = govOrgService.getSuperiorResourceInfos(formDTO); + if (!superiorResourceInfos.isEmpty()){ + reInfos.addAll(superiorResourceInfos); + } + break; + case TableConstant.IC_CITY_MANAGEMENT: + PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize(),formDTO.getIsPage()).doSelectPageInfo(() -> govOrgService.getCityManageInfos(formDTO)); + List cityManageInfos = govOrgService.getCityManageInfos(formDTO); + if (!cityManageInfos.isEmpty()){ + reInfos.addAll(cityManageInfos); + } + break; + case TableConstant.IC_COMMUNITY_SELF_ORGANIZATION: + PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize(),formDTO.getIsPage()).doSelectPageInfo(() -> heartService.getCommunitySelOrgInfos(formDTO)); + List communitySelOrgInfos = heartService.getCommunitySelOrgInfos(formDTO); + if (!communitySelOrgInfos.isEmpty()){ + reInfos.addAll(communitySelOrgInfos); + } + break; + case TableConstant.IC_DANGEROUS_CHEMICALS: + PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize(),formDTO.getIsPage()).doSelectPageInfo(() -> govOrgService.getDangerousChemicalsInfos(formDTO)); + List dangerousChemicalsInfos = govOrgService.getDangerousChemicalsInfos(formDTO); + if (!dangerousChemicalsInfos.isEmpty()){ + reInfos.addAll(dangerousChemicalsInfos); + } + break; + case TableConstant.IC_ENTERPRISE: + PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize(),formDTO.getIsPage()).doSelectPageInfo(() -> govOrgService.getEnterpriseInfos(formDTO)); + List enterpriseInfos = govOrgService.getEnterpriseInfos(formDTO); + if (!enterpriseInfos.isEmpty()){ + reInfos.addAll(enterpriseInfos); + } + break; + case TableConstant.IC_PUBLIC_SERVICE: + PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize(),formDTO.getIsPage()).doSelectPageInfo(() -> govOrgService.getPublicServiceInfos(formDTO)); + List publicServiceInfos = govOrgService.getPublicServiceInfos(formDTO); + if (!publicServiceInfos.isEmpty()){ + reInfos.addAll(publicServiceInfos); + } + break; + case TableConstant.IC_EVENT: + PageInfo eventPageInfo = getEventInfo(formDTO); + result.setEventInfos(eventPageInfo.getList()); + result.setEventInfoTotal(eventPageInfo.getTotal()); + break; + default: + break; + } + } + result.setResourceInfos(reInfos); + } + return result; + } + + public PageInfo getIcUserPageInfo (CoverageHomeSearchFormDTO formDTO){ + PageInfo result = new PageInfo<>(); + if (formDTO.getIsPage()){ + result = PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize(), formDTO.getIsPage()).doSelectPageInfo(() -> icResiService.getAllIcUser(formDTO)); + }else { + List allIcUser = icResiService.getAllIcUser(formDTO); + result.setTotal(Long.valueOf(String.valueOf(allIcUser.size()))); + result.setList(allIcUser); + } + return result; + } + + /** + * Desc: 事件查询 + * @param formDTO + * @author zxc + * @date 2022/7/28 16:03 + */ + public PageInfo getEventInfo (CoverageHomeSearchFormDTO formDTO){ + PageInfo result = new PageInfo<>(); + if (formDTO.getIsPage()){ + result = PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize(), formDTO.getIsPage()).doSelectPageInfo(() -> govProjectService.getEventInfos(formDTO)); + }else { + List eventInfos = govProjectService.getEventInfos(formDTO); + result.setTotal(Long.valueOf(String.valueOf(eventInfos.size()))); + result.setList(eventInfos); + } + return result; } /** diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/opercustomize/IcResiCategoryStatsConfigService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/opercustomize/IcResiCategoryStatsConfigService.java new file mode 100644 index 0000000000..5910c9d9f1 --- /dev/null +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/opercustomize/IcResiCategoryStatsConfigService.java @@ -0,0 +1,9 @@ +package com.epmet.dataaggre.service.opercustomize; + +/** + * @Author zxc + * @DateTime 2022/7/27 17:20 + * @DESC + */ +public interface IcResiCategoryStatsConfigService { +} diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml index 58fc07506f..1a461c213a 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml @@ -151,4 +151,24 @@ + + + diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCityManagementDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCityManagementDao.xml index 8cdd63a520..21c839a27e 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCityManagementDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCityManagementDao.xml @@ -3,4 +3,96 @@ + + + + + + + + + \ No newline at end of file diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryDictDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryDictDao.xml index 599659a43b..c756992558 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryDictDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryDictDao.xml @@ -3,6 +3,15 @@ + + diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govproject/IcEventDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govproject/IcEventDao.xml index ad5afc48d2..f35dd89392 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govproject/IcEventDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govproject/IcEventDao.xml @@ -1,6 +1,21 @@ - + + \ No newline at end of file diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/heart/IcCommunitySelfOrganizationDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/heart/IcCommunitySelfOrganizationDao.xml index c785e28c0d..4e660c06dd 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/heart/IcCommunitySelfOrganizationDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/heart/IcCommunitySelfOrganizationDao.xml @@ -2,4 +2,22 @@ + + + \ No newline at end of file From 4a70c115983a94f5d63ea036c286355723724b54 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Thu, 28 Jul 2022 16:11:52 +0800 Subject: [PATCH 085/155] =?UTF-8?q?=E5=85=AC=E5=85=B1=E6=9C=8D=E5=8A=A1?= =?UTF-8?q?=E4=BA=BA=E7=BE=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../commons/tools/enums/ResiCategoryEnum.java | 42 +++++++++++++++++++ .../epmetuser/impl/IcResiServiceImpl.java | 37 ++++++++++++++++ 2 files changed, 79 insertions(+) create mode 100644 epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/ResiCategoryEnum.java diff --git a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/ResiCategoryEnum.java b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/ResiCategoryEnum.java new file mode 100644 index 0000000000..b7ab6cbddc --- /dev/null +++ b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/ResiCategoryEnum.java @@ -0,0 +1,42 @@ +package com.epmet.commons.tools.enums; + +public enum ResiCategoryEnum { + IS_PARTY("IS_PARTY", "党员"), + IS_DBH("IS_DBH", "低保人员"), + IS_ENSURE_HOUSE("IS_ENSURE_HOUSE", "保障房人员"), + IS_UNEMPLOYED("IS_UNEMPLOYED", "失业人员"), + IS_YLFN("IS_YLFN", "育龄妇女"), + IS_VETERANS("IS_VETERANS", "退役军人"), + IS_UNITED_FRONT("IS_UNITED_FRONT", "统战人员"), + IS_XFRY("IS_XFRY", "信访人员"), + IS_VOLUNTEER("IS_VOLUNTEER", "志愿者"), + IS_OLD_PEOPLE("IS_OLD_PEOPLE", "老年人"), + IS_KC("IS_KC", "空巢"), + IS_SD("IS_SD", "失独人员"), + IS_SN("IS_SN", "失能"), + IS_SZ("IS_SZ", "失智"), + IS_CJ("IS_CJ", "残疾"), + IS_DB("IS_DB", "大病"), + IS_MB("IS_MB", "慢病"), + IS_SPECIAL("IS_SPECIAL", "特殊人群"); + private String colName; + private String label; + + + ResiCategoryEnum(String colName, String label) { + this.colName = colName; + this.label = label; + } + + public String getColName() { + return colName; + } + + public String getLabel() { + return label; + } + + public void setLabel(String label) { + this.label = label; + } +} diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/IcResiServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/IcResiServiceImpl.java index 74ba309792..7525d751d6 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/IcResiServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/IcResiServiceImpl.java @@ -2,6 +2,7 @@ package com.epmet.dataaggre.service.epmetuser.impl; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.epmet.commons.dynamic.datasource.annotation.DataSource; +import com.epmet.commons.tools.enums.ResiCategoryEnum; import com.epmet.dataaggre.constant.DataSourceConstant; import com.epmet.dataaggre.dao.epmetuser.IcResiUserDao; import com.epmet.dataaggre.dto.epmetuser.result.IcResiInfoResultDTO; @@ -78,6 +79,42 @@ public class IcResiServiceImpl implements IcResiService { query.eq(IcResiUserEntity::getIsSn, true); } else if ("resi_szry".equals(categoryKey)) { query.eq(IcResiUserEntity::getIsSz, true); + } else if (ResiCategoryEnum.IS_PARTY.getColName().equals(categoryKey)) { + query.eq(IcResiUserEntity::getIsParty, true); + } else if (ResiCategoryEnum.IS_DBH.getColName().equals(categoryKey)) { + query.eq(IcResiUserEntity::getIsDbh, true); + } else if (ResiCategoryEnum.IS_ENSURE_HOUSE.getColName().equals(categoryKey)) { + query.eq(IcResiUserEntity::getIsEnsureHouse, true); + } else if (ResiCategoryEnum.IS_UNEMPLOYED.getColName().equals(categoryKey)) { + query.eq(IcResiUserEntity::getIsUnemployed, true); + } else if (ResiCategoryEnum.IS_YLFN.getColName().equals(categoryKey)) { + query.eq(IcResiUserEntity::getIsYlfn, true); + } else if (ResiCategoryEnum.IS_VETERANS.getColName().equals(categoryKey)) { + query.eq(IcResiUserEntity::getIsVeterans, true); + } else if (ResiCategoryEnum.IS_UNITED_FRONT.getColName().equals(categoryKey)) { + query.eq(IcResiUserEntity::getIsUnitedFront, true); + } else if (ResiCategoryEnum.IS_XFRY.getColName().equals(categoryKey)) { + query.eq(IcResiUserEntity::getIsXfry, true); + } else if (ResiCategoryEnum.IS_VOLUNTEER.getColName().equals(categoryKey)) { + query.eq(IcResiUserEntity::getIsVolunteer, true); + } else if (ResiCategoryEnum.IS_OLD_PEOPLE.getColName().equals(categoryKey)) { + query.eq(IcResiUserEntity::getIsOldPeople, true); + } else if (ResiCategoryEnum.IS_KC.getColName().equals(categoryKey)) { + query.eq(IcResiUserEntity::getIsKc, true); + } else if (ResiCategoryEnum.IS_SD.getColName().equals(categoryKey)) { + query.eq(IcResiUserEntity::getIsSd, true); + } else if (ResiCategoryEnum.IS_SN.getColName().equals(categoryKey)) { + query.eq(IcResiUserEntity::getIsSn, true); + } else if (ResiCategoryEnum.IS_SZ.getColName().equals(categoryKey)) { + query.eq(IcResiUserEntity::getIsSz, true); + } else if (ResiCategoryEnum.IS_CJ.getColName().equals(categoryKey)) { + query.eq(IcResiUserEntity::getIsCj, true); + } else if (ResiCategoryEnum.IS_DB.getColName().equals(categoryKey)) { + query.eq(IcResiUserEntity::getIsDb, true); + } else if (ResiCategoryEnum.IS_MB.getColName().equals(categoryKey)) { + query.eq(IcResiUserEntity::getIsMb, true); + } else if (ResiCategoryEnum.IS_SPECIAL.getColName().equals(categoryKey)) { + query.eq(IcResiUserEntity::getIsSpecial, true); } if (StringUtils.isNotBlank(search)) { From 9c71c9779828309fb29a007905084bea77176f5c Mon Sep 17 00:00:00 2001 From: sunyuchao Date: Thu, 28 Jul 2022 16:16:54 +0800 Subject: [PATCH 086/155] =?UTF-8?q?=E7=A4=BE=E4=BC=9A=E8=87=AA=E7=BB=84?= =?UTF-8?q?=E7=BB=87=E3=80=81=E8=81=94=E5=BB=BA=E5=8D=95=E4=BD=8D=E5=88=97?= =?UTF-8?q?=E8=A1=A8=E5=A2=9E=E5=8A=A0=E8=BF=94=E5=8F=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../result/CommunitySelfOrganizationListDTO.java | 16 ++++++++++++++++ .../mapper/IcCommunitySelfOrganizationDao.xml | 5 ++++- 2 files changed, 20 insertions(+), 1 deletion(-) diff --git a/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/result/CommunitySelfOrganizationListDTO.java b/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/result/CommunitySelfOrganizationListDTO.java index 39552f7654..790c8c2a44 100644 --- a/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/result/CommunitySelfOrganizationListDTO.java +++ b/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/result/CommunitySelfOrganizationListDTO.java @@ -100,6 +100,22 @@ public class CommunitySelfOrganizationListDTO implements Serializable { * 积分 */ private Integer score; + + /** + * 同步状态【已同步:sync 未同步:not_sync】 + */ + private String syncType; + + /** + * 部门ID customer_department.id + */ + private String deptId; + + /** + * 部门下工作人员Id + */ + private String deptStaffId; + /** * 社区自组织人员 */ diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/resources/mapper/IcCommunitySelfOrganizationDao.xml b/epmet-module/epmet-heart/epmet-heart-server/src/main/resources/mapper/IcCommunitySelfOrganizationDao.xml index 872caf9999..1ab8c2264b 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/resources/mapper/IcCommunitySelfOrganizationDao.xml +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/resources/mapper/IcCommunitySelfOrganizationDao.xml @@ -63,7 +63,10 @@ so.LATITUDE AS latitude, so.ADDRESS as address, so.ID as orgId, - so.remark + so.remark, + so.sync_type AS syncType, + so.dept_id AS deptId, + so.dept_staff_id AS deptStaffId FROM ic_community_self_organization so WHERE so.DEL_FLAG = 0 From 36a89abc4a4ea5e853e803751dc6659d79156556 Mon Sep 17 00:00:00 2001 From: zxc <1272811460@qq.com> Date: Thu, 28 Jul 2022 16:27:32 +0800 Subject: [PATCH 087/155] =?UTF-8?q?=E6=BC=8F=E6=8F=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../epmet/dataaggre/service/govorg/GovOrgCoverageService.java | 2 -- 1 file changed, 2 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java index b13cd75b74..26faa47e81 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java @@ -135,8 +135,6 @@ public interface GovOrgCoverageService { */ IcCoverageCategoryDictEntity selectByCategoryKey(String categoryKey); - List listCoverageCategoryEntities(String coverageType); - /** * Desc: 根据客户ID和数据类型获取字典对应的url * @param customerId From bb57374c87c364f531ad3d4d69258396d2d8b249 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Thu, 28 Jul 2022 16:28:16 +0800 Subject: [PATCH 088/155] =?UTF-8?q?z=E7=BB=BC=E5=90=88=E6=B2=BB=E7=90=86?= =?UTF-8?q?=E4=BA=BA=E7=BE=A4=EF=BC=8C=E5=85=AC=E5=85=B1=E6=9C=8D=E5=8A=A1?= =?UTF-8?q?=EF=BC=8C=E8=BF=99=E4=BA=9B=E5=B1=85=E6=B0=91=EF=BC=8C=E6=98=BE?= =?UTF-8?q?=E7=A4=BA=E5=A7=93=E5=90=8D(=E8=BA=AB=E4=BB=BD=E8=AF=81?= =?UTF-8?q?=E5=8F=B7)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../commons/tools/constant/StrConstant.java | 3 +++ .../epmetuser/result/IcResiInfoResultDTO.java | 1 + .../service/impl/CoverageServiceImpl.java | 17 +++++++---------- .../mapper/epmetuser/IcResiUserDao.xml | 2 +- 4 files changed, 12 insertions(+), 11 deletions(-) diff --git a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/constant/StrConstant.java b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/constant/StrConstant.java index 7d2ad8ec03..b89a521218 100644 --- a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/constant/StrConstant.java +++ b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/constant/StrConstant.java @@ -112,4 +112,7 @@ public interface StrConstant { String NO = "否"; String ELLIPSIS="......"; + + String BRACKET_LEFT="("; + String BRACKET_RIGNT=")"; } diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/epmetuser/result/IcResiInfoResultDTO.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/epmetuser/result/IcResiInfoResultDTO.java index 659805383f..a4ba26b37b 100644 --- a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/epmetuser/result/IcResiInfoResultDTO.java +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/epmetuser/result/IcResiInfoResultDTO.java @@ -10,4 +10,5 @@ public class IcResiInfoResultDTO { private String id; private String name; private String buildId; + private String idNum; } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index 4f9216b5d4..3ec40ef572 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -14,36 +14,31 @@ import com.epmet.commons.tools.redis.common.bean.AgencyInfoCache; import com.epmet.commons.tools.redis.common.bean.BuildingInfoCache; import com.epmet.commons.tools.utils.EpmetRequestHolder; import com.epmet.dataaggre.constant.OrgConstant; -import com.epmet.dataaggre.dto.coverage.AnalysisGovernedTargetsResult; -import com.epmet.dataaggre.constant.OrgConstant; import com.epmet.dataaggre.constant.TableConstant; +import com.epmet.dataaggre.dto.coverage.AnalysisGovernedTargetsResult; import com.epmet.dataaggre.dto.coverage.AnalysisResourceCategoriesResult; import com.epmet.dataaggre.dto.epmetuser.result.IcResiInfoResultDTO; import com.epmet.dataaggre.dto.govorg.form.CoverageAnalisisDataListLeftFormDTO; import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; -import com.epmet.dataaggre.dto.govorg.result.CoverageAnalisisDataListResultDTO; -import com.epmet.dataaggre.dto.govorg.result.CoverageAnalisisDataListResultDTOV2; -import com.epmet.dataaggre.dto.govorg.result.CoverageHomeSearchResultDTO; -import com.epmet.dataaggre.dto.govorg.result.IcEnterisePatrolResultDTO; import com.epmet.dataaggre.dto.govorg.result.*; import com.epmet.dataaggre.entity.epmetuser.IcResiUserEntity; import com.epmet.dataaggre.entity.govorg.*; import com.epmet.dataaggre.entity.govproject.IcEventEntity; import com.epmet.dataaggre.entity.heart.IcCommunitySelfOrganizationEntity; import com.epmet.dataaggre.entity.heart.IcPartyUnitEntity; +import com.epmet.dataaggre.entity.opercustomize.IcResiCategoryWarnConfigEntity; import com.epmet.dataaggre.enums.MenusEnums; import com.epmet.dataaggre.redis.GovCustomerMenuRedis; -import com.epmet.dataaggre.entity.opercustomize.IcResiCategoryWarnConfigEntity; import com.epmet.dataaggre.service.CoverageService; import com.epmet.dataaggre.service.epmetuser.IcResiService; import com.epmet.dataaggre.service.govorg.GovOrgCoverageService; import com.epmet.dataaggre.service.govorg.GovOrgService; import com.epmet.dataaggre.service.govproject.GovProjectService; import com.epmet.dataaggre.service.heart.HeartService; +import com.epmet.dataaggre.service.opercustomize.IcResiCategoryWarnService; import com.epmet.dto.GovMenuDTO; import com.github.pagehelper.PageHelper; import com.github.pagehelper.PageInfo; -import com.epmet.dataaggre.service.opercustomize.IcResiCategoryWarnService; import lombok.extern.slf4j.Slf4j; import org.apache.commons.collections4.CollectionUtils; import org.apache.commons.collections4.MapUtils; @@ -507,7 +502,8 @@ public class CoverageServiceImpl implements CoverageService { String[] coordinates = getUserCoordinates(re.getId(), re.getBuildId(), rootAgency); return new CoverageAnalisisDataListResultDTO( - re.getId(), categoryKey, isPage ? categoryDict.getCategoryName() : null, placeType, isPage ? re.getName() : null, + re.getId(), categoryKey, isPage ? categoryDict.getCategoryName() : null, placeType, + re.getName().concat(StrConstant.BRACKET_LEFT).concat(re.getIdCard()).concat(StrConstant.BRACKET_RIGNT), coordinates[1], coordinates[0]); }).collect(Collectors.toList()); @@ -521,7 +517,8 @@ public class CoverageServiceImpl implements CoverageService { return new CoverageAnalisisDataListResultDTO( re.getId(), categoryKey, isPage ? categoryDict.getCategoryName() : null, placeType, - isPage ? re.getName() : null, coordinates[1], coordinates[0]); + re.getName().concat(StrConstant.BRACKET_LEFT).concat(re.getIdNum()).concat(StrConstant.BRACKET_RIGNT), + coordinates[1], coordinates[0]); }).collect(Collectors.toList()); } else if (CoveragePlaceTypeEnum.EVENT.getCode().equals(placeType)) { diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml index 1a461c213a..dfcd87920f 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml @@ -38,7 +38,7 @@ SELECT - customer_id AS customerId + customer_id AS customerId, + dept_type AS deptType FROM customer_department WHERE From 452b6d75f5e5035ba2baf268ddbf46a7f31e3f65 Mon Sep 17 00:00:00 2001 From: wangxianzhang Date: Thu, 28 Jul 2022 16:37:27 +0800 Subject: [PATCH 090/155] =?UTF-8?q?=E3=80=90=E5=9B=BE=E5=B1=82=E3=80=91?= =?UTF-8?q?=E5=8F=AF=E8=A7=86=E5=8C=96-=E5=B7=A6=E4=BE=A7=E8=8F=9C?= =?UTF-8?q?=E5=8D=95=E5=A2=9E=E5=8A=A0menu=E6=8E=A7=E5=88=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/CoverageServiceImpl.java | 34 ++++++++----------- 1 file changed, 15 insertions(+), 19 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index 4f9216b5d4..d916e9cb13 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -83,21 +83,6 @@ public class CoverageServiceImpl implements CoverageService { @Autowired private IcResiCategoryWarnService icResiCategoryWarnService; - /** - * 场所类型常量 - */ - public static final String PLACE_TYPE_RESI = "resi"; - public static final String PLACE_TYPE_SPECIAL_RESI = "special_resi"; - public static final String PLACE_TYPE_EVENT= "event"; - public static final String PLACE_TYPE_CITY_MANAGEMENT= "city_management"; - public static final String PLACE_TYPE_COMUNITY_ORG= "community_org"; - public static final String PLACE_TYPE_DANGEROUS_CHEMICALS= "dangerous_chemicals"; - public static final String PLACE_TYPE_ENTERPRISE_PARTROL= "enterprise_patrol"; - public static final String PLACE_TYPE_GROUP_RENT= "group_rent"; - public static final String PLACE_TYPE_PUBLIC_SERVICE= "public_service"; - public static final String PLACE_TYPE_SUPERIOR_RESOURCE= "superior_resource"; - public static final String PLACE_TYPE_PARTY_UNIT= "party_unit"; - // 1:出租 0:自住 2:闲置 3:未售出 public static final Integer HOUSE_RENT_FLAG_RENT = 1; @@ -736,6 +721,13 @@ public class CoverageServiceImpl implements CoverageService { @Override public List listGovernedTargetCategories() { + List menuUrls = new ArrayList<>(128); + + List menus = govCustomerMenuRedis.getCustomerMenuList(EpmetRequestHolder.getLoginUserCustomerId(), 0, "gov_menu"); + if (CollectionUtils.isNotEmpty(menus)) { + menus.stream().forEach(m -> menuUrls.add(m.getUrl())); + } + // 1.从表中取数据出来 List targetCategories = govOrgCoverageService.listGovernedTargetCategoryEntities(); @@ -750,8 +742,10 @@ public class CoverageServiceImpl implements CoverageService { String placeTypeInAnalysis = rc.getPlaceTypeInAnalysis(); if (StringUtils.isEmpty(placeTypeInAnalysis)) { // 只有一层,没有子级 - results.add(new AnalysisGovernedTargetsResult(rc.getCategoryKey(), rc.getCategoryName(), rc.getCoverageType(), - rc.getPlaceType(), CoveragePlaceTypeEnum.getEnum(rc.getPlaceType()).getName(), rc.getQuantity(), new ArrayList<>())); + if (menuUrls.contains(rc.getMenuUrl()) || "all".equals(rc.getMenuUrl())) { + results.add(new AnalysisGovernedTargetsResult(rc.getCategoryKey(), rc.getCategoryName(), rc.getCoverageType(), + rc.getPlaceType(), CoveragePlaceTypeEnum.getEnum(rc.getPlaceType()).getName(), rc.getQuantity(), new ArrayList<>())); + } } else { // 有子级,需要使用placeTypeInAnalysis分组 List targets = placeTypeMap.get(placeTypeInAnalysis); @@ -759,8 +753,10 @@ public class CoverageServiceImpl implements CoverageService { targets = new ArrayList<>(); placeTypeMap.put(placeTypeInAnalysis, targets); } - targets.add(new AnalysisGovernedTargetsResult(rc.getCategoryKey(), rc.getCategoryName(), rc.getCoverageType(), - rc.getPlaceType(), CoveragePlaceTypeEnum.getEnum(rc.getPlaceType()).getName(), rc.getQuantity(), new ArrayList<>())); + if (menuUrls.contains(rc.getMenuUrl()) || "all".equals(rc.getMenuUrl())) { + targets.add(new AnalysisGovernedTargetsResult(rc.getCategoryKey(), rc.getCategoryName(), rc.getCoverageType(), + rc.getPlaceType(), CoveragePlaceTypeEnum.getEnum(rc.getPlaceType()).getName(), rc.getQuantity(), new ArrayList<>())); + } } }); From 390d0a6408196b56cc49c021a5d87a9adb373178 Mon Sep 17 00:00:00 2001 From: zxc <1272811460@qq.com> Date: Thu, 28 Jul 2022 17:24:00 +0800 Subject: [PATCH 091/155] =?UTF-8?q?=E5=8F=88=E6=9A=82=E6=8F=90=E4=BA=86?= =?UTF-8?q?=E6=90=9C=E7=B4=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dao/govorg/IcCityManagementDao.java | 5 ++ .../service/impl/CoverageServiceImpl.java | 70 ++++++++++++------- .../mapper/govorg/IcCityManagementDao.xml | 70 +++++++++++++++++-- .../mapper/govproject/IcEventDao.xml | 4 +- 4 files changed, 118 insertions(+), 31 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcCityManagementDao.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcCityManagementDao.java index 5fcc8ac3c2..04746db059 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcCityManagementDao.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcCityManagementDao.java @@ -24,6 +24,7 @@ public interface IcCityManagementDao extends BaseDao { * @date 2022/7/28 10:22 */ List getCityManageInfos(CoverageHomeSearchFormDTO formDTO); + Integer getCityManageInfosCount(CoverageHomeSearchFormDTO formDTO); /** * Desc: 【资源】获取公共服务信息 @@ -32,6 +33,7 @@ public interface IcCityManagementDao extends BaseDao { * @date 2022/7/28 10:22 */ List getPublicServiceInfos(CoverageHomeSearchFormDTO formDTO); + Integer getPublicServiceInfosCount(CoverageHomeSearchFormDTO formDTO); /** * Desc: 【资源】获取重点危化品企业信息 @@ -40,6 +42,7 @@ public interface IcCityManagementDao extends BaseDao { * @date 2022/7/28 10:22 */ List getDangerousChemicalsInfos(CoverageHomeSearchFormDTO formDTO); + Integer getDangerousChemicalsInfosCount(CoverageHomeSearchFormDTO formDTO); /** * Desc: 【资源】获取优势资源信息 @@ -48,6 +51,7 @@ public interface IcCityManagementDao extends BaseDao { * @date 2022/7/28 10:22 */ List getSuperiorResourceInfos(CoverageHomeSearchFormDTO formDTO); + Integer getSuperiorResourceInfosCount(CoverageHomeSearchFormDTO formDTO); /** * Desc: 【资源】获取企事业单位巡查信息 @@ -56,5 +60,6 @@ public interface IcCityManagementDao extends BaseDao { * @date 2022/7/28 10:22 */ List getEnterpriseInfos(CoverageHomeSearchFormDTO formDTO); + Integer getEnterpriseInfosCount(CoverageHomeSearchFormDTO formDTO); } \ No newline at end of file diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index 0d2b4a922a..5a050263b6 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -244,17 +244,23 @@ public class CoverageServiceImpl implements CoverageService { PageInfo allIcUserPageInfo = getIcUserPageInfo(formDTO); result.setUserInfos(allIcUserPageInfo.getList()); result.setUserInfosTotal(allIcUserPageInfo.getTotal()); - }else if (formDTO.getSearchType().equals(OrgConstant.SEARCH_TYPE_EVENT)){ + }else if (formDTO.getSearchType().equals(OrgConstant.SEARCH_TYPE_RESOURCE)){ + for (String resource : resources) { - if (MenusEnums.IC_EVENT.getUrl().equals(resource)){ - PageInfo eventPageInfo = getEventInfo(formDTO); - result.setEventInfos(eventPageInfo.getList()); - result.setEventInfoTotal(eventPageInfo.getTotal()); - break; + if (MenusEnums.IC_SUPERIOR_RESOURCE.getUrl().equals(resource)){ + + }else if (MenusEnums.IC_CITY_MANAGEMENT.getUrl().equals(resource)){ + + }else if (MenusEnums.IC_COMMUNITY_SELF_ORGANIZATION.getUrl().equals(resource)){ + + }else if (MenusEnums.IC_DANGEROUS_CHEMICALS.getUrl().equals(resource)){ + + }else if (MenusEnums.IC_ENTERPRISE.getUrl().equals(resource)){ + + }else if (MenusEnums.IC_PUBLIC_SERVICE.getUrl().equals(resource)){ + } } - }else if (formDTO.getSearchType().equals(OrgConstant.SEARCH_TYPE_RESOURCE)){ - } }else { // 查询居民 @@ -263,59 +269,73 @@ public class CoverageServiceImpl implements CoverageService { result.setUserInfosTotal(allIcUserPageInfo.getTotal()); List reInfos = new ArrayList<>(); for (String table : tables) { + if (formDTO.getIsPage() && reInfos.size() == formDTO.getPageSize()){ + break; + } + Integer flag = formDTO.getPageSize() - reInfos.size(); switch (table){ case TableConstant.IC_SUPERIOR_RESOURCE: - PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize(),formDTO.getIsPage()).doSelectPageInfo(() -> govOrgService.getSuperiorResourceInfos(formDTO)); List superiorResourceInfos = govOrgService.getSuperiorResourceInfos(formDTO); - if (!superiorResourceInfos.isEmpty()){ + if (formDTO.getIsPage() && superiorResourceInfos.size() > flag){ + reInfos.addAll(superiorResourceInfos.subList(NumConstant.ZERO, flag)); + }else { reInfos.addAll(superiorResourceInfos); } break; case TableConstant.IC_CITY_MANAGEMENT: - PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize(),formDTO.getIsPage()).doSelectPageInfo(() -> govOrgService.getCityManageInfos(formDTO)); List cityManageInfos = govOrgService.getCityManageInfos(formDTO); - if (!cityManageInfos.isEmpty()){ + if (formDTO.getIsPage() && cityManageInfos.size() > flag){ + reInfos.addAll(cityManageInfos.subList(NumConstant.ZERO,flag)); + }else { reInfos.addAll(cityManageInfos); } break; case TableConstant.IC_COMMUNITY_SELF_ORGANIZATION: - PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize(),formDTO.getIsPage()).doSelectPageInfo(() -> heartService.getCommunitySelOrgInfos(formDTO)); List communitySelOrgInfos = heartService.getCommunitySelOrgInfos(formDTO); - if (!communitySelOrgInfos.isEmpty()){ + if (formDTO.getIsPage() && communitySelOrgInfos.size() > flag){ + reInfos.addAll(communitySelOrgInfos.subList(NumConstant.ZERO,flag)); + }else { reInfos.addAll(communitySelOrgInfos); } break; case TableConstant.IC_DANGEROUS_CHEMICALS: - PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize(),formDTO.getIsPage()).doSelectPageInfo(() -> govOrgService.getDangerousChemicalsInfos(formDTO)); List dangerousChemicalsInfos = govOrgService.getDangerousChemicalsInfos(formDTO); - if (!dangerousChemicalsInfos.isEmpty()){ + if (formDTO.getIsPage() && dangerousChemicalsInfos.size() > flag){ + reInfos.addAll(dangerousChemicalsInfos.subList(NumConstant.ZERO,flag)); + }else { reInfos.addAll(dangerousChemicalsInfos); } break; case TableConstant.IC_ENTERPRISE: - PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize(),formDTO.getIsPage()).doSelectPageInfo(() -> govOrgService.getEnterpriseInfos(formDTO)); List enterpriseInfos = govOrgService.getEnterpriseInfos(formDTO); - if (!enterpriseInfos.isEmpty()){ + if (formDTO.getIsPage() && enterpriseInfos.size() > flag){ + reInfos.addAll(enterpriseInfos.subList(NumConstant.ZERO,flag)); + }else { reInfos.addAll(enterpriseInfos); } break; case TableConstant.IC_PUBLIC_SERVICE: - PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize(),formDTO.getIsPage()).doSelectPageInfo(() -> govOrgService.getPublicServiceInfos(formDTO)); List publicServiceInfos = govOrgService.getPublicServiceInfos(formDTO); - if (!publicServiceInfos.isEmpty()){ + if (formDTO.getIsPage() && publicServiceInfos.size() > flag){ + reInfos.addAll(publicServiceInfos.subList(NumConstant.ZERO,flag)); + }else { reInfos.addAll(publicServiceInfos); } break; - case TableConstant.IC_EVENT: - PageInfo eventPageInfo = getEventInfo(formDTO); - result.setEventInfos(eventPageInfo.getList()); - result.setEventInfoTotal(eventPageInfo.getTotal()); - break; default: break; } } result.setResourceInfos(reInfos); + result.setResourceInfoTotal(Long.valueOf(String.valueOf(reInfos.size()))); + } + for (String resource : resources) { + if (MenusEnums.IC_EVENT.getUrl().equals(resource)){ + PageInfo eventPageInfo = getEventInfo(formDTO); + result.setEventInfos(eventPageInfo.getList()); + result.setEventInfoTotal(eventPageInfo.getTotal()); + break; + } } return result; } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCityManagementDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCityManagementDao.xml index 21c839a27e..29476955de 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCityManagementDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCityManagementDao.xml @@ -20,7 +20,9 @@ WHERE DEL_FLAG = 0 AND CUSTOMER_ID = #{customerId} AND AGENCY_ID_PATH LIKE CONCAT('%',#{orgId},'%') - AND `NAME` LIKE CONCAT('%',#{name},'%') + + AND `NAME` LIKE CONCAT('%',#{name},'%') + + + + + + \ No newline at end of file diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govproject/IcEventDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govproject/IcEventDao.xml index f35dd89392..547ff69899 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govproject/IcEventDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govproject/IcEventDao.xml @@ -16,6 +16,8 @@ AND customer_id = #{customerId} AND DIFFICULT_POINT = '1' AND GRID_PIDS LIKE CONCAT('%',#{orgId},'%') - AND EVENT_CONTENT LIKE CONCAT('%',#{name},'%') + + AND EVENT_CONTENT LIKE CONCAT('%',#{name},'%') + \ No newline at end of file From 257ec3c2be7f3d350833044c224fb3b172b037a0 Mon Sep 17 00:00:00 2001 From: sunyuchao Date: Thu, 28 Jul 2022 17:35:52 +0800 Subject: [PATCH 092/155] =?UTF-8?q?=E7=A8=8B=E5=BA=8F=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/epmet/service/impl/DepartmentServiceImpl.java | 9 +++++---- .../com/epmet/service/impl/CustomerStaffServiceImpl.java | 5 +++-- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java index 51ab136d05..8f71eb4716 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java @@ -328,6 +328,7 @@ public class DepartmentServiceImpl implements DepartmentService { } //查不到工作人员就直接返回 if (null == userResult.getData()) { + resultDTO.setType(true); return resultDTO; } @@ -497,13 +498,14 @@ public class DepartmentServiceImpl implements DepartmentService { if (!projectResult.success()) { throw new RenException("获取工作人员代办项目数据失败" + projectResult.getMsg()); } - if(projectResult.getData().size()>NumConstant.ZERO){ - String msg = String.format("当前%s下负责人存在未办结的项目,请先将待处理项目办结后再操作",("party_unit".equals(formDTO.getDeptType())?"联建单位":"社会自组织")); + if (projectResult.getData().size() > NumConstant.ZERO) { + String msg = String.format("当前%s下负责人存在未办结的项目,请先将待处理项目办结后再操作", ("party_unit".equals(formDTO.getDeptType()) ? "联建单位" : "社会自组织")); resultDTO.setMsg(msg); + return resultDTO; } //2.无代办项目的则删除部门、工作人员信息、修改联建单位/社会自组织业务数据 //2-1.删除部门 - customerDepartmentDao.deleteById(formDTO.getId()); + customerDepartmentDao.deleteById(formDTO.getDeptId()); //2-2.删除部门人员关系数据 LambdaQueryWrapper query = new LambdaQueryWrapper<>(); query.eq(CustomerStaffDepartmentEntity::getDepartmentId, formDTO.getDeptId()); @@ -511,7 +513,6 @@ public class DepartmentServiceImpl implements DepartmentService { customerStaffDepartmentDao.delete(query); //2-3.删除人员注册关系数据 LambdaQueryWrapper StaffOrgRelation = new LambdaQueryWrapper<>(); - StaffOrgRelation.eq(StaffOrgRelationEntity::getOrgId, formDTO.getDeptId()); StaffOrgRelation.eq(StaffOrgRelationEntity::getStaffId, formDTO.getDeptStaffId()); staffOrgRelationDao.delete(StaffOrgRelation); //2-4.删除工作人员数据 diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java index b25d014fc5..8fcc9b5338 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java @@ -886,9 +886,10 @@ public class CustomerStaffServiceImpl extends BaseServiceImpl resultRole = govAccessFeignClient.getGovRole(roleDTO); - if (!resultRole.success()) { + if (!resultRole.success() || null == resultRole.getData()) { throw new RenException("人员添加失败" + resultRole.getMsg()); } List newRoles = new ArrayList<>(); From 5177ad45412148cf37161eba3796f560bdb5aee7 Mon Sep 17 00:00:00 2001 From: sunyuchao Date: Thu, 28 Jul 2022 17:37:09 +0800 Subject: [PATCH 093/155] =?UTF-8?q?=E7=A8=8B=E5=BA=8F=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- epmet-gateway/pom.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/epmet-gateway/pom.xml b/epmet-gateway/pom.xml index dc505b1985..6b7db20347 100644 --- a/epmet-gateway/pom.xml +++ b/epmet-gateway/pom.xml @@ -317,6 +317,7 @@ lb://gov-access-server + From 3678169c94f7a5d797354faff05ea7348c8ef7a4 Mon Sep 17 00:00:00 2001 From: wangxianzhang Date: Thu, 28 Jul 2022 22:18:45 +0800 Subject: [PATCH 094/155] =?UTF-8?q?=E3=80=90=E5=9B=BE=E5=B1=82=E3=80=91?= =?UTF-8?q?=E5=8F=AF=E8=A7=86=E5=8C=96-=201.=E5=B0=86=E8=BF=94=E5=9B=9E?= =?UTF-8?q?=E7=9A=84=E5=B7=A6=E5=8F=B3=E8=8F=9C=E5=8D=95=E8=B7=9Fmenu?= =?UTF-8?q?=E7=BB=91=E5=AE=9A;2.=E5=B9=B6=E4=B8=94=E5=B0=86=E5=85=AC?= =?UTF-8?q?=E5=85=B1=E6=9C=8D=E5=8A=A1=E4=BA=BA=E7=BE=A4=E7=9A=84=E8=BF=94?= =?UTF-8?q?=E5=9B=9E=EF=BC=8C=E4=BB=8Ecategory=5Fdict=E4=B8=AD=E5=8F=96?= =?UTF-8?q?=EF=BC=8C=E7=84=B6=E5=90=8E=E8=B7=9Foper=5Fcustomize.ic=5Fresi?= =?UTF-8?q?=5Fcategory=5Fwarn=5Fconfig=E4=B8=AD=E5=AF=B9=E5=BA=94?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/CoverageServiceImpl.java | 90 +++++++++++-------- 1 file changed, 52 insertions(+), 38 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index 0d2b4a922a..38ad15d704 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -655,6 +655,14 @@ public class CoverageServiceImpl implements CoverageService { @Override public List listAnalysisResourceCategories() { + // 获取所有菜单的url + List menuUrls = new ArrayList<>(128); + + List menus = govCustomerMenuRedis.getCustomerMenuList(EpmetRequestHolder.getLoginUserCustomerId(), 0, "gov_menu"); + if (CollectionUtils.isNotEmpty(menus)) { + menus.stream().forEach(m -> menuUrls.add(m.getUrl())); + } + //结果集 ArrayList results = new ArrayList<>(); @@ -674,29 +682,31 @@ public class CoverageServiceImpl implements CoverageService { continue; } - // 2.根据menuUrl过滤 todo - - // 2.计算各类数量 todo - // 3.对上一步得到的数据进行分组,使用PLACE_TYPE_IN_ANALYSIS分组,然后放入placeType,这一列为空的说明不分组,直接属于coverage - categoryDictEntities.forEach(c -> { - if (StringUtils.isBlank(c.getPlaceTypeInAnalysis())) { + categoryDictEntities.forEach(category -> { + if (StringUtils.isBlank(category.getPlaceTypeInAnalysis())) { // 没有placetype的 - categoriesOfThisCoverage.getCategories() - .add(new AnalysisResourceCategoriesResult.Category(c.getCategoryKey(), c.getCategoryName(), - c.getCoverageType(), c.getPlaceType(), c.getQuantity())); + if ("all".equals(category.getMenuUrl()) || menuUrls.contains(category.getMenuUrl())) { + categoriesOfThisCoverage.getCategories() + .add(new AnalysisResourceCategoriesResult.Category(category.getCategoryKey(), category.getCategoryName(), + category.getCoverageType(), category.getPlaceType(), category.getQuantity())); + } } else { // 有placetype的 - AnalysisResourceCategoriesResult.PlaceType placeType = placeTypeMap.get(c.getPlaceTypeInAnalysis()); - if (placeType == null) { - placeType = new AnalysisResourceCategoriesResult.PlaceType( - c.getPlaceTypeInAnalysis(), CoveragePlaceTypeEnum.getEnum(c.getPlaceTypeInAnalysis()).getName(), c.getQuantity(), new ArrayList<>()); - placeTypeMap.put(c.getPlaceTypeInAnalysis(), placeType); + AnalysisResourceCategoriesResult.PlaceType placeType = placeTypeMap.get(category.getPlaceTypeInAnalysis()); + if ("all".equals(category.getMenuUrl()) || menuUrls.contains(category.getMenuUrl())) { + + if (placeType == null) { + placeType = new AnalysisResourceCategoriesResult.PlaceType( + category.getPlaceTypeInAnalysis(), CoveragePlaceTypeEnum.getEnum(category.getPlaceTypeInAnalysis()).getName(), category.getQuantity(), new ArrayList<>()); + placeTypeMap.put(category.getPlaceTypeInAnalysis(), placeType); + } + + placeType.getCategories().add(new AnalysisResourceCategoriesResult.Category(category.getCategoryKey(), + category.getCategoryName(), category.getCoverageType(), category.getPlaceType(), category.getQuantity())); + placeType.setQuantity(placeType.getQuantity() + category.getQuantity()); // todo 0改为category的count } - placeType.getCategories().add(new AnalysisResourceCategoriesResult.Category(c.getCategoryKey(), - c.getCategoryName(), c.getCoverageType(), c.getPlaceType(), c.getQuantity())); - placeType.setQuantity(placeType.getQuantity() + c.getQuantity()); // todo 0改为category的count } }); @@ -718,6 +728,7 @@ public class CoverageServiceImpl implements CoverageService { @Override public List listGovernedTargetCategories() { + // 获取所有菜单的url List menuUrls = new ArrayList<>(128); List menus = govCustomerMenuRedis.getCustomerMenuList(EpmetRequestHolder.getLoginUserCustomerId(), 0, "gov_menu"); @@ -732,11 +743,22 @@ public class CoverageServiceImpl implements CoverageService { return new ArrayList<>(); } + //2.从oper_customize.ic_resi_category_warn_config表中取18大类居民中需要预警的类出来 + List categoriesNeed2Warn = icResiCategoryWarnService.listResiCategoriesNeed2Warn(EpmetRequestHolder.getLoginUserCustomerId()); + List resiCategories2Show = categoriesNeed2Warn.stream().map(wc -> wc.getColumnName()).collect(Collectors.toList()); + List results = new ArrayList<>(); - HashMap> placeTypeMap = new HashMap<>(); + HashMap> placeTypeTargetMap = new HashMap<>(); + HashMap placeTypeQuantityMap = new HashMap<>(); targetCategories.forEach(rc -> { String placeTypeInAnalysis = rc.getPlaceTypeInAnalysis(); + if (CoveragePlaceTypeEnum.RESI.getCode().equals(placeTypeInAnalysis) && !resiCategories2Show.contains(rc.getCategoryKey())) { + // 因为公共服务-人群,是需要跟oper_customize.ic_resi_category_warn_config表对应,只显示warn=1的, + // 所以如果是被管理对象中的公共服务人群,如果不开启预警,就跳过;其他情况都放进去 + return; + } + if (StringUtils.isEmpty(placeTypeInAnalysis)) { // 只有一层,没有子级 if (menuUrls.contains(rc.getMenuUrl()) || "all".equals(rc.getMenuUrl())) { @@ -745,41 +767,33 @@ public class CoverageServiceImpl implements CoverageService { } } else { // 有子级,需要使用placeTypeInAnalysis分组 - List targets = placeTypeMap.get(placeTypeInAnalysis); - if (CollectionUtils.isEmpty(targets)) { - targets = new ArrayList<>(); - placeTypeMap.put(placeTypeInAnalysis, targets); - } if (menuUrls.contains(rc.getMenuUrl()) || "all".equals(rc.getMenuUrl())) { + List targets = placeTypeTargetMap.get(placeTypeInAnalysis); + if (CollectionUtils.isEmpty(targets)) { + targets = new ArrayList<>(); + placeTypeTargetMap.put(placeTypeInAnalysis, targets); + placeTypeQuantityMap.put(placeTypeInAnalysis, 0); + } targets.add(new AnalysisGovernedTargetsResult(rc.getCategoryKey(), rc.getCategoryName(), rc.getCoverageType(), rc.getPlaceType(), CoveragePlaceTypeEnum.getEnum(rc.getPlaceType()).getName(), rc.getQuantity(), new ArrayList<>())); + + placeTypeQuantityMap.put(placeTypeInAnalysis, placeTypeQuantityMap.get(placeTypeInAnalysis) + rc.getQuantity()); } } }); - if (placeTypeMap.size() > 0) { - placeTypeMap.forEach((placeTypeInAnalysis, targetObjects) -> { + // 最后,把需要分组的"公共服务人群","综合治理人群"放到最后的结果列表中 + if (placeTypeTargetMap.size() > 0) { + placeTypeTargetMap.forEach((placeTypeInAnalysis, targetObjects) -> { AnalysisGovernedTargetsResult tr = new AnalysisGovernedTargetsResult(); tr.setPlaceType(placeTypeInAnalysis); + tr.setQuantity(placeTypeQuantityMap.get(placeTypeInAnalysis)); tr.setPlaceTypeName(CoveragePlaceTypeEnum.getEnum(placeTypeInAnalysis).getName()); tr.setChildren(targetObjects); results.add(tr); }); } - //2.从oper_customize.ic_resi_category_warn_config表中取18大类居民中需要预警的类出来 - List categoriesNeed2Warn = icResiCategoryWarnService.listResiCategoriesNeed2Warn(EpmetRequestHolder.getLoginUserCustomerId()); - List ggfwrqCategories = categoriesNeed2Warn.stream().map(wc -> - new AnalysisGovernedTargetsResult(wc.getColumnName(), wc.getTableName(), - CoverageEnums.GGFW.getKey(), CoveragePlaceTypeEnum.RESI.getCode(), CoveragePlaceTypeEnum.RESI.getName(), - 0, new ArrayList<>())).collect(Collectors.toList()); - - AnalysisGovernedTargetsResult ggfwRq = new AnalysisGovernedTargetsResult(); - ggfwRq.setPlaceType(CoveragePlaceTypeEnum.RESI.getCode()); - ggfwRq.setPlaceTypeName(CoveragePlaceTypeEnum.RESI.getName()); - ggfwRq.setChildren(ggfwrqCategories); - - results.add(ggfwRq); return results; } From 2c9d66709c9b73ff95e2e5fcdaf4ab7c900d8205 Mon Sep 17 00:00:00 2001 From: zxc <1272811460@qq.com> Date: Fri, 29 Jul 2022 08:43:43 +0800 Subject: [PATCH 095/155] =?UTF-8?q?=E5=8F=88=E6=9A=82=E6=8F=90=E4=BA=86?= =?UTF-8?q?=E6=90=9C=E7=B4=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../heart/IcCommunitySelfOrganizationDao.java | 1 + .../service/govorg/GovOrgService.java | 5 + .../govorg/impl/GovOrgServiceImpl.java | 25 ++++ .../dataaggre/service/heart/HeartService.java | 1 + .../service/heart/impl/HeartServiceImpl.java | 5 + .../service/impl/CoverageServiceImpl.java | 112 +++++++++++++++++- .../heart/IcCommunitySelfOrganizationDao.xml | 14 ++- 7 files changed, 159 insertions(+), 4 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/heart/IcCommunitySelfOrganizationDao.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/heart/IcCommunitySelfOrganizationDao.java index 2aab1d0be0..b0adcb3773 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/heart/IcCommunitySelfOrganizationDao.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/heart/IcCommunitySelfOrganizationDao.java @@ -35,5 +35,6 @@ import java.util.List; public interface IcCommunitySelfOrganizationDao extends BaseDao { List getCommunitySelOrgInfos(CoverageHomeSearchFormDTO formDTO); + Integer getCommunitySelOrgInfosCount(CoverageHomeSearchFormDTO formDTO); } \ No newline at end of file diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgService.java index adc04ab316..8f0faeb52e 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgService.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgService.java @@ -228,6 +228,7 @@ public interface GovOrgService { * @date 2022/7/28 10:22 */ List getCityManageInfos(CoverageHomeSearchFormDTO formDTO); + Integer getCityManageInfosCount(CoverageHomeSearchFormDTO formDTO); /** * Desc: 【资源】获取公共服务信息 @@ -236,6 +237,7 @@ public interface GovOrgService { * @date 2022/7/28 10:22 */ List getPublicServiceInfos(CoverageHomeSearchFormDTO formDTO); + Integer getPublicServiceInfosCount(CoverageHomeSearchFormDTO formDTO); /** * Desc: 【资源】获取重点危化品企业信息 @@ -244,6 +246,7 @@ public interface GovOrgService { * @date 2022/7/28 10:22 */ List getDangerousChemicalsInfos(CoverageHomeSearchFormDTO formDTO); + Integer getDangerousChemicalsInfosCount(CoverageHomeSearchFormDTO formDTO); /** * Desc: 【资源】获取优势资源信息 @@ -252,6 +255,7 @@ public interface GovOrgService { * @date 2022/7/28 10:22 */ List getSuperiorResourceInfos(CoverageHomeSearchFormDTO formDTO); + Integer getSuperiorResourceInfosCount(CoverageHomeSearchFormDTO formDTO); /** * Desc: 【资源】获取企事业单位巡查信息 @@ -260,5 +264,6 @@ public interface GovOrgService { * @date 2022/7/28 10:22 */ List getEnterpriseInfos(CoverageHomeSearchFormDTO formDTO); + Integer getEnterpriseInfosCount(CoverageHomeSearchFormDTO formDTO); } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgServiceImpl.java index 4eaab080a5..1cf12a56dd 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgServiceImpl.java @@ -1135,23 +1135,48 @@ public class GovOrgServiceImpl implements GovOrgService { return cityManagementDao.getCityManageInfos(formDTO); } + @Override + public Integer getCityManageInfosCount(CoverageHomeSearchFormDTO formDTO) { + return cityManagementDao.getCityManageInfosCount(formDTO); + } + @Override public List getPublicServiceInfos(CoverageHomeSearchFormDTO formDTO) { return cityManagementDao.getPublicServiceInfos(formDTO); } + @Override + public Integer getPublicServiceInfosCount(CoverageHomeSearchFormDTO formDTO) { + return cityManagementDao.getPublicServiceInfosCount(formDTO); + } + @Override public List getDangerousChemicalsInfos(CoverageHomeSearchFormDTO formDTO) { return cityManagementDao.getDangerousChemicalsInfos(formDTO); } + @Override + public Integer getDangerousChemicalsInfosCount(CoverageHomeSearchFormDTO formDTO) { + return cityManagementDao.getDangerousChemicalsInfosCount(formDTO); + } + @Override public List getSuperiorResourceInfos(CoverageHomeSearchFormDTO formDTO) { return cityManagementDao.getSuperiorResourceInfos(formDTO); } + @Override + public Integer getSuperiorResourceInfosCount(CoverageHomeSearchFormDTO formDTO) { + return cityManagementDao.getSuperiorResourceInfosCount(formDTO); + } + @Override public List getEnterpriseInfos(CoverageHomeSearchFormDTO formDTO) { return cityManagementDao.getEnterpriseInfos(formDTO); } + + @Override + public Integer getEnterpriseInfosCount(CoverageHomeSearchFormDTO formDTO) { + return cityManagementDao.getEnterpriseInfosCount(formDTO); + } } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/heart/HeartService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/heart/HeartService.java index d97044b718..03d6de4431 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/heart/HeartService.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/heart/HeartService.java @@ -44,4 +44,5 @@ public interface HeartService { Integer countCommunityOrgEntities(String customerId, String agencyId, String staffOrgIds, String search, String categoryKey); List getCommunitySelOrgInfos(CoverageHomeSearchFormDTO formDTO); + Integer getCommunitySelOrgInfosCount(CoverageHomeSearchFormDTO formDTO); } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/heart/impl/HeartServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/heart/impl/HeartServiceImpl.java index 314c5d7672..7af8676a08 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/heart/impl/HeartServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/heart/impl/HeartServiceImpl.java @@ -63,6 +63,11 @@ public class HeartServiceImpl implements HeartService { return communitySelfOrganizationDao.getCommunitySelOrgInfos(formDTO); } + @Override + public Integer getCommunitySelOrgInfosCount(CoverageHomeSearchFormDTO formDTO) { + return communitySelfOrganizationDao.getCommunitySelOrgInfosCount(formDTO); + } + private LambdaQueryWrapper constructCommunityOrgQueryWrapper( String customerId, String agencyId, String staffOrgIds, String search, String categoryKey) { LambdaQueryWrapper query = new LambdaQueryWrapper<>(); diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index 1b94a0f270..ee4a6682fe 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -245,14 +245,24 @@ public class CoverageServiceImpl implements CoverageService { result.setUserInfos(allIcUserPageInfo.getList()); result.setUserInfosTotal(allIcUserPageInfo.getTotal()); }else if (formDTO.getSearchType().equals(OrgConstant.SEARCH_TYPE_RESOURCE)){ - + Integer total = NumConstant.ZERO; + Integer start = (formDTO.getPageNo() - NumConstant.ONE) * formDTO.getPageSize(); + Integer end = start + formDTO.getPageSize(); + Integer flag; for (String resource : resources) { if (MenusEnums.IC_SUPERIOR_RESOURCE.getUrl().equals(resource)){ - + Integer superiorResourceInfosCount = govOrgService.getSuperiorResourceInfosCount(formDTO); + total = total + superiorResourceInfosCount; + if (superiorResourceInfosCount > start){ + + } }else if (MenusEnums.IC_CITY_MANAGEMENT.getUrl().equals(resource)){ + Integer cityManageInfosCount = govOrgService.getCityManageInfosCount(formDTO); + total = total + cityManageInfosCount; }else if (MenusEnums.IC_COMMUNITY_SELF_ORGANIZATION.getUrl().equals(resource)){ - + Integer communitySelOrgInfosCount = heartService.getCommunitySelOrgInfosCount(formDTO); + total = total + communitySelOrgInfosCount; }else if (MenusEnums.IC_DANGEROUS_CHEMICALS.getUrl().equals(resource)){ }else if (MenusEnums.IC_ENTERPRISE.getUrl().equals(resource)){ @@ -340,6 +350,102 @@ public class CoverageServiceImpl implements CoverageService { return result; } + /** + * Desc: 【资源】优势资源查询 + * @param formDTO + * @author zxc + * @date 2022/7/29 08:37 + */ + public PageInfo getSuperiorResourcePageInfo (CoverageHomeSearchFormDTO formDTO){ + PageInfo result = new PageInfo<>(); + if (formDTO.getIsPage()){ + result = PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize(), formDTO.getIsPage()).doSelectPageInfo(() -> govOrgService.getSuperiorResourceInfos(formDTO)); + }else { + List superiorResourceInfos = govOrgService.getSuperiorResourceInfos(formDTO); + result.setTotal(Long.valueOf(String.valueOf(superiorResourceInfos.size()))); + result.setList(superiorResourceInfos); + } + return result; + } + + /** + * Desc: 【资源】城市管理查询 + * @param formDTO + * @author zxc + * @date 2022/7/29 08:37 + */ + public PageInfo getCityManagePageInfo (CoverageHomeSearchFormDTO formDTO){ + PageInfo result = new PageInfo<>(); + if (formDTO.getIsPage()){ + result = PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize(), formDTO.getIsPage()).doSelectPageInfo(() -> govOrgService.getCityManageInfos(formDTO)); + }else { + List cityManageInfos = govOrgService.getCityManageInfos(formDTO); + result.setTotal(Long.valueOf(String.valueOf(cityManageInfos.size()))); + result.setList(cityManageInfos); + } + return result; + } + + /** + * Desc: 【资源】公共服务查询 + * @param formDTO + * @author zxc + * @date 2022/7/29 08:37 + */ + public PageInfo getPublicServicePageInfo (CoverageHomeSearchFormDTO formDTO){ + PageInfo result = new PageInfo<>(); + if (formDTO.getIsPage()){ + result = PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize(), formDTO.getIsPage()).doSelectPageInfo(() -> govOrgService.getPublicServiceInfos(formDTO)); + }else { + List publicServiceInfos = govOrgService.getPublicServiceInfos(formDTO); + result.setTotal(Long.valueOf(String.valueOf(publicServiceInfos.size()))); + result.setList(publicServiceInfos); + } + return result; + } + + /** + * Desc: 【资源】重点危化品企业查询 + * @param formDTO + * @author zxc + * @date 2022/7/29 08:37 + */ + public PageInfo getDangerousChemicalsPageInfo (CoverageHomeSearchFormDTO formDTO){ + PageInfo result = new PageInfo<>(); + if (formDTO.getIsPage()){ + result = PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize(), formDTO.getIsPage()).doSelectPageInfo(() -> govOrgService.getDangerousChemicalsInfos(formDTO)); + }else { + List dangerousChemicalsInfos = govOrgService.getDangerousChemicalsInfos(formDTO); + result.setTotal(Long.valueOf(String.valueOf(dangerousChemicalsInfos.size()))); + result.setList(dangerousChemicalsInfos); + } + return result; + } + + /** + * Desc: 【资源】企事业单位查询 + * @param formDTO + * @author zxc + * @date 2022/7/29 08:37 + */ + public PageInfo getEnterpriseInfosPageInfo (CoverageHomeSearchFormDTO formDTO){ + PageInfo result = new PageInfo<>(); + if (formDTO.getIsPage()){ + result = PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize(), formDTO.getIsPage()).doSelectPageInfo(() -> govOrgService.getEnterpriseInfos(formDTO)); + }else { + List enterpriseInfos = govOrgService.getEnterpriseInfos(formDTO); + result.setTotal(Long.valueOf(String.valueOf(enterpriseInfos.size()))); + result.setList(enterpriseInfos); + } + return result; + } + + /** + * Desc: 居民信息查询 + * @param formDTO + * @author zxc + * @date 2022/7/29 08:34 + */ public PageInfo getIcUserPageInfo (CoverageHomeSearchFormDTO formDTO){ PageInfo result = new PageInfo<>(); if (formDTO.getIsPage()){ diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/heart/IcCommunitySelfOrganizationDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/heart/IcCommunitySelfOrganizationDao.xml index 4e660c06dd..b374071590 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/heart/IcCommunitySelfOrganizationDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/heart/IcCommunitySelfOrganizationDao.xml @@ -18,6 +18,18 @@ WHERE DEL_FLAG = 0 AND CUSTOMER_ID = #{customerId} AND CONCAT(PIDS,':',ORG_ID) LIKE CONCAT('%',#{orgId},'%') - AND ORGANIZATION_NAME LIKE CONCAT('%',#{name},'%') + + AND ORGANIZATION_NAME LIKE CONCAT('%',#{name},'%') + + + \ No newline at end of file From 973d88fd9d87b4294b867ce931349dbe859b0d76 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Fri, 29 Jul 2022 09:14:25 +0800 Subject: [PATCH 096/155] duanxin --- .../impl/IcServiceRecordV2ServiceImpl.java | 5 +++-- .../impl/IcUserDemandRecServiceImpl.java | 4 ++-- .../epmet/constant/SmsTemplateConstant.java | 22 ++++++++++++++----- 3 files changed, 22 insertions(+), 9 deletions(-) diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcServiceRecordV2ServiceImpl.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcServiceRecordV2ServiceImpl.java index 13937dd7a5..cf208a032e 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcServiceRecordV2ServiceImpl.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcServiceRecordV2ServiceImpl.java @@ -176,9 +176,10 @@ public class IcServiceRecordV2ServiceImpl extends BaseServiceImpl paramMap = new HashMap<>(); - paramMap.put("content", String.format("%s发起一个【%s】服务,请服务完成后尽快反馈,谢谢合作。", staffInfoCacheResult.getAgencyName(), serviceName)); + paramMap.put("name",staffInfoCacheResult.getAgencyName()); + paramMap.put("serviceName",serviceName); sms.setParamMap(paramMap); smsList.add(sms); messageOpenFeignClient.sendMsg(smsList); diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java index 355ca9f008..e7863747c5 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java @@ -453,9 +453,9 @@ public class IcUserDemandRecServiceImpl extends BaseServiceImpl paramMap = new HashMap<>(); - paramMap.put("content", String.format("%s给您指派了一个新的需求,请查看", staffInfoCacheResult.getAgencyName())); + paramMap.put("name",staffInfoCacheResult.getAgencyName()); sms.setParamMap(paramMap); smsList.add(sms); messageOpenFeignClient.sendMsg(smsList); diff --git a/epmet-module/epmet-message/epmet-message-client/src/main/java/com/epmet/constant/SmsTemplateConstant.java b/epmet-module/epmet-message/epmet-message-client/src/main/java/com/epmet/constant/SmsTemplateConstant.java index 225e61bacc..3f1ec288ac 100644 --- a/epmet-module/epmet-message/epmet-message-client/src/main/java/com/epmet/constant/SmsTemplateConstant.java +++ b/epmet-module/epmet-message/epmet-message-client/src/main/java/com/epmet/constant/SmsTemplateConstant.java @@ -39,10 +39,22 @@ public interface SmsTemplateConstant { String PROJECT_OVERDUE = "SMS_206885207"; /** - * 通用的短信模板,翻出来的内容 - *【党群e事通】:XXXXX - * 参数key:content + * 模板名称 + * 数字社区-服务方接收消息模板 + * 模板CODE + * SMS_247205033 + * 模板内容 + * ${nane}发起一个${serviceName}服务,请服务完成后尽快反馈,谢谢合作。 */ - // todo - String COMMON_SMS_TEM=""; + String IC_SERVICE_TEM="SMS_247205033"; + + /** + * 模板名称 + * 数字社区-需求服务方接收消息模板 + * 模板CODE + * SMS_247645013 + * 模板内容 + * ${name}给您指派了一个新的需求,请服务完成后尽快反馈,谢谢合作。 + */ + String DEMAND_SERVICE_TEM="SMS_247645013"; } From b2713613d88c8a4626d33514bd869bba16aefc8d Mon Sep 17 00:00:00 2001 From: jianjun Date: Fri, 29 Jul 2022 09:41:27 +0800 Subject: [PATCH 097/155] =?UTF-8?q?=E5=AD=97=E5=85=B8=E7=BC=96=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java index 18c2f11420..67fd29285b 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java @@ -162,7 +162,7 @@ public class GridInfoPingyinServiceImpl extends BaseServiceImpl 10) { entity.setLat(new BigDecimal(ag.getLatitude().substring(0, 10))); } else { From d776d6aa55b1befc52560963f37ce1df2961bd69 Mon Sep 17 00:00:00 2001 From: zxc <1272811460@qq.com> Date: Fri, 29 Jul 2022 09:41:48 +0800 Subject: [PATCH 098/155] =?UTF-8?q?=E5=B1=85=E6=B0=91=E3=80=81=E4=BA=8B?= =?UTF-8?q?=E4=BB=B6=E3=80=81=E8=B5=84=E6=BA=90=E8=AF=A6=E6=83=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../form/CoverageHomeSearchFormDTO.java | 4 + .../dto/govorg/form/SearchDetailFormDTO.java | 39 ++++++++ .../controller/CoverageController.java | 28 +++++- .../dataaggre/service/CoverageService.java | 12 ++- .../service/impl/CoverageServiceImpl.java | 77 +++++++++++++++ .../mapper/govorg/IcCityManagementDao.xml | 98 +++++++++++++++---- 6 files changed, 232 insertions(+), 26 deletions(-) create mode 100644 epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/SearchDetailFormDTO.java diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageHomeSearchFormDTO.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageHomeSearchFormDTO.java index 49575e02fc..4650740bf6 100644 --- a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageHomeSearchFormDTO.java +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/CoverageHomeSearchFormDTO.java @@ -37,4 +37,8 @@ public class CoverageHomeSearchFormDTO extends PageFormDTO implements Serializab * searchType为resource时,此字段必填 */ private String resourceType; + + private String resourceId; + private String icEventId; + private String icUserId; } diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/SearchDetailFormDTO.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/SearchDetailFormDTO.java new file mode 100644 index 0000000000..61fe3607a5 --- /dev/null +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/govorg/form/SearchDetailFormDTO.java @@ -0,0 +1,39 @@ +package com.epmet.dataaggre.dto.govorg.form; + +import lombok.Data; + +import javax.validation.constraints.NotBlank; +import java.io.Serializable; + +/** + * @Author zxc + * @DateTime 2022/7/29 08:48 + * @DESC + */ +@Data +public class SearchDetailFormDTO implements Serializable { + + private static final long serialVersionUID = 3499320376768396157L; + + public interface SearchUserDetailForm{} + public interface SearchEventDetailForm{} + public interface SearchResourceDetailForm{} + + @NotBlank(message = "icUserId不能为空",groups = SearchUserDetailForm.class) + private String icUserId; + + @NotBlank(message = "icEventId不能为空",groups = SearchEventDetailForm.class) + private String icEventId; + + @NotBlank(message = "resourceId不能为空",groups = SearchResourceDetailForm.class) + private String resourceId; + + /** + * 资源类型:社区自组织:community_org;优势资源:superior_resource;城市管理:city_management;重点危化企业:dangerous_chemicals;公共服务:public_service;企事业单位巡查:enterprise_patrol; + */ + @NotBlank(message = "resourceType不能为空",groups = SearchResourceDetailForm.class) + private String resourceType; + + private String customerId; + +} diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java index f300875b13..ea436eb916 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java @@ -7,14 +7,14 @@ import com.epmet.commons.tools.page.PageData; import com.epmet.commons.tools.security.dto.TokenDto; import com.epmet.commons.tools.utils.EpmetRequestHolder; import com.epmet.commons.tools.utils.Result; +import com.epmet.commons.tools.validator.ValidatorUtils; import com.epmet.dataaggre.dto.coverage.AnalysisGovernedTargetsResult; import com.epmet.dataaggre.dto.coverage.AnalysisResourceCategoriesResult; import com.epmet.dataaggre.dto.govorg.form.CoverageAnalisisDataListFormDTO; import com.epmet.dataaggre.dto.govorg.form.CoverageAnalisisDataListLeftFormDTO; import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; -import com.epmet.dataaggre.dto.govorg.result.CoverageAnalisisDataListResultDTO; -import com.epmet.dataaggre.dto.govorg.result.CoverageAnalisisDataListResultDTOV2; -import com.epmet.dataaggre.dto.govorg.result.CoverageHomeSearchResultDTO; +import com.epmet.dataaggre.dto.govorg.form.SearchDetailFormDTO; +import com.epmet.dataaggre.dto.govorg.result.*; import com.epmet.dataaggre.service.CoverageService; import org.apache.commons.collections4.CollectionUtils; import org.springframework.beans.factory.annotation.Autowired; @@ -118,4 +118,26 @@ public class CoverageController { PageData page = coverageService.dataListLeft(formDTO); return new Result>().ok(page); } + + @PostMapping("search-user-detail") + public Result searchUserDetail(@RequestBody SearchDetailFormDTO formDTO,@LoginUser TokenDto tokenDto){ + ValidatorUtils.validateEntity(formDTO, SearchDetailFormDTO.SearchUserDetailForm.class); + formDTO.setCustomerId(tokenDto.getCustomerId()); + return new Result().ok(coverageService.searchUserDetail(formDTO)); + } + + @PostMapping("search-event-detail") + public Result searchEventDetail(@RequestBody SearchDetailFormDTO formDTO,@LoginUser TokenDto tokenDto){ + ValidatorUtils.validateEntity(formDTO, SearchDetailFormDTO.SearchEventDetailForm.class); + formDTO.setCustomerId(tokenDto.getCustomerId()); + return new Result().ok(coverageService.searchEventDetail(formDTO)); + } + + @PostMapping("search-resource-detail") + public Result searchResourceDetail(@RequestBody SearchDetailFormDTO formDTO,@LoginUser TokenDto tokenDto){ + ValidatorUtils.validateEntity(formDTO, SearchDetailFormDTO.SearchResourceDetailForm.class); + formDTO.setCustomerId(tokenDto.getCustomerId()); + return new Result().ok(coverageService.searchResourceDetail(formDTO)); + } + } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java index 5c39087be8..9c2179e7e8 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java @@ -5,9 +5,8 @@ import com.epmet.dataaggre.dto.coverage.AnalysisGovernedTargetsResult; import com.epmet.dataaggre.dto.coverage.AnalysisResourceCategoriesResult; import com.epmet.dataaggre.dto.govorg.form.CoverageAnalisisDataListLeftFormDTO; import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; -import com.epmet.dataaggre.dto.govorg.result.CoverageAnalisisDataListResultDTO; -import com.epmet.dataaggre.dto.govorg.result.CoverageAnalisisDataListResultDTOV2; -import com.epmet.dataaggre.dto.govorg.result.CoverageHomeSearchResultDTO; +import com.epmet.dataaggre.dto.govorg.form.SearchDetailFormDTO; +import com.epmet.dataaggre.dto.govorg.result.*; import java.util.List; @@ -50,4 +49,11 @@ public interface CoverageService { * @return */ PageData dataListLeft(CoverageAnalisisDataListLeftFormDTO formDTO); + + UserInfoResultDTO searchUserDetail(SearchDetailFormDTO formDTO); + + EventInfoResultDTO searchEventDetail(SearchDetailFormDTO formDTO); + + ResourceInfoResultDTO searchResourceDetail(SearchDetailFormDTO formDTO); + } \ No newline at end of file diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index ee4a6682fe..3d5b75f9bd 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -8,10 +8,14 @@ import com.epmet.commons.tools.enums.CoveragePlaceTypeEnum; import com.epmet.commons.tools.exception.EpmetErrorCode; import com.epmet.commons.tools.exception.EpmetException; import com.epmet.commons.tools.page.PageData; +import com.epmet.commons.tools.redis.common.CustomerIcHouseRedis; import com.epmet.commons.tools.redis.common.CustomerOrgRedis; import com.epmet.commons.tools.redis.common.CustomerStaffRedis; import com.epmet.commons.tools.redis.common.bean.AgencyInfoCache; import com.epmet.commons.tools.redis.common.bean.BuildingInfoCache; +import com.epmet.commons.tools.redis.common.bean.GridInfoCache; +import com.epmet.commons.tools.redis.common.bean.HouseInfoCache; +import com.epmet.commons.tools.utils.ConvertUtils; import com.epmet.commons.tools.utils.EpmetRequestHolder; import com.epmet.dataaggre.constant.OrgConstant; import com.epmet.dataaggre.constant.TableConstant; @@ -20,6 +24,7 @@ import com.epmet.dataaggre.dto.coverage.AnalysisResourceCategoriesResult; import com.epmet.dataaggre.dto.epmetuser.result.IcResiInfoResultDTO; import com.epmet.dataaggre.dto.govorg.form.CoverageAnalisisDataListLeftFormDTO; import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; +import com.epmet.dataaggre.dto.govorg.form.SearchDetailFormDTO; import com.epmet.dataaggre.dto.govorg.result.*; import com.epmet.dataaggre.entity.epmetuser.IcResiUserEntity; import com.epmet.dataaggre.entity.govorg.*; @@ -959,4 +964,76 @@ public class CoverageServiceImpl implements CoverageService { // page.getTotal()是多少条业务数据 return new PageData<>(list, page.getTotal()); } + + @Override + public UserInfoResultDTO searchUserDetail(SearchDetailFormDTO formDTO) { + CoverageHomeSearchFormDTO dto = ConvertUtils.sourceToTarget(formDTO, CoverageHomeSearchFormDTO.class); + UserInfoResultDTO result = new UserInfoResultDTO(); + List allIcUser = icResiService.getAllIcUser(dto); + if (CollectionUtils.isNotEmpty(allIcUser)){ + result = allIcUser.get(NumConstant.ZERO); + GridInfoCache gridInfo = CustomerOrgRedis.getGridInfo(result.getGridId()); + if (null == gridInfo){ + throw new EpmetException("获取网格信息失败:"+result.getGridId()); + } + result.setGridName(gridInfo.getGridNamePath()); + HouseInfoCache houseInfo = CustomerIcHouseRedis.getHouseInfo(formDTO.getCustomerId(), result.getHomeId()); + if (null == houseInfo){ + throw new EpmetException("获取房屋信息失败:"+result.getHomeId()); + } + result.setHouseName(houseInfo.getAllName()); + result.setLongitude(houseInfo.getBuildingLongitude()); + result.setLatitude(houseInfo.getBuildingLatitude()); + } + return result; + } + + @Override + public EventInfoResultDTO searchEventDetail(SearchDetailFormDTO formDTO) { + CoverageHomeSearchFormDTO dto = ConvertUtils.sourceToTarget(formDTO, CoverageHomeSearchFormDTO.class); + EventInfoResultDTO result = new EventInfoResultDTO(); + List eventInfos = govProjectService.getEventInfos(dto); + if (CollectionUtils.isNotEmpty(eventInfos)){ + result = eventInfos.get(NumConstant.ZERO); + GridInfoCache gridInfo = CustomerOrgRedis.getGridInfo(result.getGridId()); + if (null == gridInfo){ + throw new EpmetException("获取网格信息失败:"+result.getGridId()); + } + result.setGridName(gridInfo.getGridNamePath()); + } + return result; + } + + @Override + public ResourceInfoResultDTO searchResourceDetail(SearchDetailFormDTO formDTO) { + CoverageHomeSearchFormDTO dto = ConvertUtils.sourceToTarget(formDTO, CoverageHomeSearchFormDTO.class); + ResourceInfoResultDTO result = new ResourceInfoResultDTO(); + List infos = new ArrayList<>(); + switch (formDTO.getResourceType()){ + case "community_org": + infos = heartService.getCommunitySelOrgInfos(dto); + break; + case "superior_resource": + infos = govOrgService.getSuperiorResourceInfos(dto); + break; + case "city_management": + infos = govOrgService.getCityManageInfos(dto); + break; + case "dangerous_chemicals": + infos = govOrgService.getDangerousChemicalsInfos(dto); + break; + case "public_service": + infos = govOrgService.getPublicServiceInfos(dto); + break; + case "enterprise_patrol": + infos = govOrgService.getEnterpriseInfos(dto); + break; + default: + break; + } + if (CollectionUtils.isNotEmpty(infos)){ + result = infos.get(NumConstant.ZERO); + } + return result; + } } \ No newline at end of file diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCityManagementDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCityManagementDao.xml index 29476955de..c0696d0d94 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCityManagementDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCityManagementDao.xml @@ -18,8 +18,15 @@ IFNULL(MOBILE,'') AS MOBILE FROM ic_city_management WHERE DEL_FLAG = 0 - AND CUSTOMER_ID = #{customerId} - AND AGENCY_ID_PATH LIKE CONCAT('%',#{orgId},'%') + + AND ID = #{resourceId} + + + AND CUSTOMER_ID = #{customerId} + + + AND AGENCY_ID_PATH LIKE CONCAT('%',#{orgId},'%') + AND `NAME` LIKE CONCAT('%',#{name},'%') @@ -40,8 +47,15 @@ IFNULL(MOBILE,'') AS MOBILE FROM ic_public_service WHERE DEL_FLAG = 0 - AND CUSTOMER_ID = #{customerId} - AND AGENCY_ID_PATH LIKE CONCAT('%',#{orgId},'%') + + AND ID = #{resourceId} + + + AND CUSTOMER_ID = #{customerId} + + + AND AGENCY_ID_PATH LIKE CONCAT('%',#{orgId},'%') + AND `NAME` LIKE CONCAT('%',#{name},'%') @@ -60,8 +74,15 @@ ifnull(PRINCIPAL_MOBILE,'') AS mobile FROM ic_dangerous_chemicals WHERE DEL_FLAG = 0 - AND CUSTOMER_ID = #{customerId} - AND AGENCY_ID_PATH LIKE CONCAT('%',#{orgId},'%') + + AND ID = #{resourceId} + + + AND CUSTOMER_ID = #{customerId} + + + AND AGENCY_ID_PATH LIKE CONCAT('%',#{orgId},'%') + AND `NAME` LIKE CONCAT('%',#{name},'%') @@ -80,8 +101,15 @@ ifnull(ADDRESS,'') as ADDRESS FROM ic_superior_resource WHERE DEL_FLAG = 0 - AND CUSTOMER_ID = #{customerId} - AND AGENCY_ID_PATH LIKE CONCAT('%',#{orgId},'%') + + AND ID = #{resourceId} + + + AND CUSTOMER_ID = #{customerId} + + + AND AGENCY_ID_PATH LIKE CONCAT('%',#{orgId},'%') + AND `NAME` LIKE CONCAT('%',#{name},'%') @@ -99,8 +127,15 @@ ifnull(MOBILE,'') AS mobile FROM ic_enterprise WHERE DEL_FLAG = 0 - AND CUSTOMER_ID = #{customerId} - AND CONCAT(AGENCY_PIDS,':',AGENCY_ID) LIKE CONCAT('%',#{orgId},'%') + + AND ID = #{resourceId} + + + AND CUSTOMER_ID = #{customerId} + + + AND CONCAT(AGENCY_PIDS,':',AGENCY_ID) LIKE CONCAT('%',#{orgId},'%') + AND PLACE_ORG_NAME LIKE CONCAT('%',#{name},'%') @@ -109,8 +144,15 @@ select count(id) FROM ic_city_management WHERE DEL_FLAG = 0 - AND CUSTOMER_ID = #{customerId} - AND AGENCY_ID_PATH LIKE CONCAT('%',#{orgId},'%') + + AND ID = #{resourceId} + + + AND CUSTOMER_ID = #{customerId} + + + AND AGENCY_ID_PATH LIKE CONCAT('%',#{orgId},'%') + AND `NAME` LIKE CONCAT('%',#{name},'%') @@ -119,8 +161,12 @@ select count(id) FROM ic_public_service WHERE DEL_FLAG = 0 - AND CUSTOMER_ID = #{customerId} - AND AGENCY_ID_PATH LIKE CONCAT('%',#{orgId},'%') + + AND CUSTOMER_ID = #{customerId} + + + AND AGENCY_ID_PATH LIKE CONCAT('%',#{orgId},'%') + AND `NAME` LIKE CONCAT('%',#{name},'%') @@ -129,8 +175,12 @@ select count(id) FROM ic_dangerous_chemicals WHERE DEL_FLAG = 0 - AND CUSTOMER_ID = #{customerId} - AND AGENCY_ID_PATH LIKE CONCAT('%',#{orgId},'%') + + AND CUSTOMER_ID = #{customerId} + + + AND AGENCY_ID_PATH LIKE CONCAT('%',#{orgId},'%') + AND `NAME` LIKE CONCAT('%',#{name},'%') @@ -139,8 +189,12 @@ select count(id) FROM ic_superior_resource WHERE DEL_FLAG = 0 - AND CUSTOMER_ID = #{customerId} - AND AGENCY_ID_PATH LIKE CONCAT('%',#{orgId},'%') + + AND CUSTOMER_ID = #{customerId} + + + AND AGENCY_ID_PATH LIKE CONCAT('%',#{orgId},'%') + AND `NAME` LIKE CONCAT('%',#{name},'%') @@ -149,8 +203,12 @@ select count(id) FROM ic_enterprise WHERE DEL_FLAG = 0 - AND CUSTOMER_ID = #{customerId} - AND CONCAT(AGENCY_PIDS,':',AGENCY_ID) LIKE CONCAT('%',#{orgId},'%') + + AND CUSTOMER_ID = #{customerId} + + + AND CONCAT(AGENCY_PIDS,':',AGENCY_ID) LIKE CONCAT('%',#{orgId},'%') + AND PLACE_ORG_NAME LIKE CONCAT('%',#{name},'%') From f23b9f9ec38e81302d735f875612180f8590fa6b Mon Sep 17 00:00:00 2001 From: jianjun Date: Fri, 29 Jul 2022 09:54:32 +0800 Subject: [PATCH 099/155] =?UTF-8?q?=E5=88=A0=E9=99=A4=E7=8A=B6=E6=80=81?= =?UTF-8?q?=E9=BB=98=E8=AE=A4=E4=B8=BAN?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java | 1 + 1 file changed, 1 insertion(+) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java index 67fd29285b..4a997b1f6d 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java @@ -163,6 +163,7 @@ public class GridInfoPingyinServiceImpl extends BaseServiceImpl 10) { entity.setLat(new BigDecimal(ag.getLatitude().substring(0, 10))); } else { From 46137f924eb61b1146b22e28c3d1c5caa9124d81 Mon Sep 17 00:00:00 2001 From: jianjun Date: Fri, 29 Jul 2022 09:56:03 +0800 Subject: [PATCH 100/155] =?UTF-8?q?=E5=88=A0=E9=99=A4=E7=8A=B6=E6=80=81?= =?UTF-8?q?=E9=BB=98=E8=AE=A4=E4=B8=BAN?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java | 1 + 1 file changed, 1 insertion(+) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java index 4a997b1f6d..48cdf626bb 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridInfoPingyinServiceImpl.java @@ -71,6 +71,7 @@ public class GridInfoPingyinServiceImpl extends BaseServiceImpl Date: Fri, 29 Jul 2022 10:01:04 +0800 Subject: [PATCH 101/155] =?UTF-8?q?=E7=9F=AD=E4=BF=A1OK?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/epmet/service/impl/IcServiceRecordV2ServiceImpl.java | 3 ++- .../com/epmet/service/impl/IcUserDemandRecServiceImpl.java | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcServiceRecordV2ServiceImpl.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcServiceRecordV2ServiceImpl.java index cf208a032e..8eca6b07e9 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcServiceRecordV2ServiceImpl.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcServiceRecordV2ServiceImpl.java @@ -178,7 +178,8 @@ public class IcServiceRecordV2ServiceImpl extends BaseServiceImpl paramMap = new HashMap<>(); - paramMap.put("name",staffInfoCacheResult.getAgencyName()); + //${nane}发起一个${serviceName}服务,请服务完成后尽快反馈,谢谢合作。 + paramMap.put("nane",staffInfoCacheResult.getAgencyName()); paramMap.put("serviceName",serviceName); sms.setParamMap(paramMap); smsList.add(sms); diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java index e7863747c5..ca7b3c3f58 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java @@ -458,7 +458,7 @@ public class IcUserDemandRecServiceImpl extends BaseServiceImpl Date: Fri, 29 Jul 2022 10:21:30 +0800 Subject: [PATCH 102/155] =?UTF-8?q?=E5=88=A0=E9=99=A4=E7=8A=B6=E6=80=81?= =?UTF-8?q?=E9=BB=98=E8=AE=A4=E4=B8=BAN=20=E4=BB=A5=E5=8F=8A=E6=9B=B4?= =?UTF-8?q?=E6=96=B0=E6=97=B6=E9=97=B4=20=E6=9B=B4=E6=96=B0=E6=97=B6=20?= =?UTF-8?q?=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/EventreportPingyinServiceImpl.java | 6 ++++-- .../opendata/service/impl/GridInfoPingyinServiceImpl.java | 2 ++ .../service/impl/GridstaffInfoPingyinServiceImpl.java | 2 ++ .../service/impl/GridstaffWorkInfoPingyinServiceImpl.java | 2 +- 4 files changed, 9 insertions(+), 3 deletions(-) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java index fbf68fc8c5..380df961e4 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/EventreportPingyinServiceImpl.java @@ -21,6 +21,7 @@ import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; import javax.annotation.Resource; +import java.util.Date; import java.util.List; import java.util.stream.Collectors; @@ -129,9 +130,10 @@ public class EventreportPingyinServiceImpl extends BaseServiceImpl 10) { entity.setLat(new BigDecimal(ag.getLatitude().substring(0, 10))); } else { diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java index 060a9ec449..fc42fd2dda 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffInfoPingyinServiceImpl.java @@ -25,6 +25,7 @@ import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; import java.util.ArrayList; +import java.util.Date; import java.util.List; import java.util.Map; import java.util.stream.Collectors; @@ -129,6 +130,7 @@ public class GridstaffInfoPingyinServiceImpl extends BaseServiceImpl Date: Fri, 29 Jul 2022 10:23:34 +0800 Subject: [PATCH 103/155] =?UTF-8?q?=E7=A8=8B=E5=BA=8F=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/com/epmet/dto/form/AddDepartmentFormDTO.java | 5 +++++ .../java/com/epmet/service/impl/DepartmentServiceImpl.java | 4 ++++ 2 files changed, 9 insertions(+) diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/AddDepartmentFormDTO.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/AddDepartmentFormDTO.java index ab18e62e57..786980aa47 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/AddDepartmentFormDTO.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/AddDepartmentFormDTO.java @@ -71,6 +71,11 @@ public class AddDepartmentFormDTO implements Serializable { * 总人数 */ private Integer totalUser; + /** + * 联建单位: party_unit + * 社会自组织: community_org + */ + private String deptType; } \ No newline at end of file diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java index 8f71eb4716..a8123798b6 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java @@ -107,6 +107,9 @@ public class DepartmentServiceImpl implements DepartmentService { Result result = new Result(); AddDepartmentResultDTO addDepartmentResultDTO = new AddDepartmentResultDTO(); CustomerDepartmentEntity entity = ConvertUtils.sourceToTarget(formDTO, CustomerDepartmentEntity.class); + if (formDTO.getTotalUser() > NumConstant.ZERO) { + entity.setTotalUser(formDTO.getTotalUser()); + } entity.setTotalUser(NumConstant.ZERO); //1:查询当前组织机构信息,获取客户Id CustomerAgencyEntity parentEntity = customerAgencyDao.selectById(formDTO.getAgencyId()); @@ -403,6 +406,7 @@ public class DepartmentServiceImpl implements DepartmentService { deptDTO.setAgencyId(staffInfo.getAgencyId()); deptDTO.setDepartmentDuty(""); deptDTO.setDepartmentName(formDTO.getDeptName()); + deptDTO.setDeptType(formDTO.getDeptType()); deptDTO.setTotalUser(1); Result deptResult = addDepartment(deptDTO); //三、新增组织人员关系数据 From d37a56cbbf73b01b6f0ae7b6c67e8706b9f0b2fb Mon Sep 17 00:00:00 2001 From: sunyuchao Date: Fri, 29 Jul 2022 10:24:34 +0800 Subject: [PATCH 104/155] =?UTF-8?q?=E7=A8=8B=E5=BA=8F=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/com/epmet/service/impl/DepartmentServiceImpl.java | 1 + 1 file changed, 1 insertion(+) diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java index a8123798b6..0793688b22 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java @@ -468,6 +468,7 @@ public class DepartmentServiceImpl implements DepartmentService { deptDTO.setAgencyId(staffInfo.getAgencyId()); deptDTO.setDepartmentDuty(""); deptDTO.setDepartmentName(formDTO.getDeptName()); + deptDTO.setDeptType(formDTO.getDeptType()); deptDTO.setTotalUser(1); Result deptResult = addDepartment(deptDTO); //三、部门下新增人员关系数据 From 622b585bb5e282f0d148a5c1eac6b7cd896f92a4 Mon Sep 17 00:00:00 2001 From: jianjun Date: Fri, 29 Jul 2022 10:28:43 +0800 Subject: [PATCH 105/155] =?UTF-8?q?=E5=88=A0=E9=99=A4=E7=8A=B6=E6=80=81?= =?UTF-8?q?=E9=BB=98=E8=AE=A4=E4=B8=BAN=20=E4=BB=A5=E5=8F=8A=E6=9B=B4?= =?UTF-8?q?=E6=96=B0=E6=97=B6=E9=97=B4=20=E6=9B=B4=E6=96=B0=E6=97=B6=20?= =?UTF-8?q?=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../resources/mapper/GridInfoPingyinDao.xml | 28 ++++--------------- 1 file changed, 5 insertions(+), 23 deletions(-) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridInfoPingyinDao.xml b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridInfoPingyinDao.xml index c79ef11f2a..c2eeb0baa9 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridInfoPingyinDao.xml +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/GridInfoPingyinDao.xml @@ -3,32 +3,13 @@ - - - - - - - - - - - - - - - - - - - - delete from grid_info_pingyin where grid_level !='7' + delete from grid_info_pingyin where grid_level !='07' - delete from grid_info_pingyin where grid_level ='7' + delete from grid_info_pingyin where grid_level ='07' SELECT id AS "gridId", - grid_name AS "gridName" + grid_name AS "gridName", + LATITUDE as latitude, + LONGITUDE as longitude, FROM customer_grid WHERE From 1c9237e0def8a1baf6367a2e8915012a8e8f45fc Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Fri, 29 Jul 2022 12:52:51 +0800 Subject: [PATCH 112/155] shishi --- .../govorg/IcEnterprisePatrolRecordDao.java | 3 +- .../service/epmetuser/IcResiService.java | 2 +- .../epmetuser/impl/IcResiServiceImpl.java | 9 ++--- .../service/govorg/GovOrgCoverageService.java | 2 +- .../impl/GovOrgCoverageServiceImpl.java | 4 +-- .../service/govproject/GovProjectService.java | 3 +- .../impl/GovProjectServiceImpl.java | 12 +++---- .../service/impl/CoverageServiceImpl.java | 34 +++++++++++++------ .../govorg/IcEnterprisePatrolRecordDao.xml | 3 ++ 9 files changed, 45 insertions(+), 27 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcEnterprisePatrolRecordDao.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcEnterprisePatrolRecordDao.java index 1019bb6f69..5c109fe0a6 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcEnterprisePatrolRecordDao.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcEnterprisePatrolRecordDao.java @@ -26,7 +26,8 @@ public interface IcEnterprisePatrolRecordDao extends BaseDao listResisByCategories4Coverage(String customerId, String agencyId, String queryPids, String categoryKey, String search, Integer pageNo, Integer pageSize, Boolean isPage); - Integer countResisByCategories4Coverage(String customerId, String agencyId, String queryPids, String categoryKey, String search); + Integer countResisByCategories4Coverage(String customerId, String agencyId, String queryPids, String categoryKey, String search,String gridId); /** * 使用特殊人群类别查询居民列表 diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/IcResiServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/IcResiServiceImpl.java index 300a79cc82..1a3d919a65 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/IcResiServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/IcResiServiceImpl.java @@ -40,7 +40,7 @@ public class IcResiServiceImpl implements IcResiService { PageHelper.startPage(pageNo, pageSize); } - LambdaQueryWrapper query = constructQueryWrapper4Coverage(customerId, agencyId, queryPids, categoryKey, search); + LambdaQueryWrapper query = constructQueryWrapper4Coverage(customerId, agencyId, queryPids, categoryKey, search, null); query.orderByAsc(IcResiUserEntity::getCreatedTime); return resiUserDao.selectList(query); } @@ -55,8 +55,8 @@ public class IcResiServiceImpl implements IcResiService { * @return */ @Override - public Integer countResisByCategories4Coverage(String customerId, String agencyId, String queryPids, String categoryKey, String search) { - LambdaQueryWrapper query = constructQueryWrapper4Coverage(customerId, agencyId, queryPids, categoryKey, search); + public Integer countResisByCategories4Coverage(String customerId, String agencyId, String queryPids, String categoryKey, String search, String gridId) { + LambdaQueryWrapper query = constructQueryWrapper4Coverage(customerId, agencyId, queryPids, categoryKey, search,gridId); return resiUserDao.selectCount(query); } @@ -69,11 +69,12 @@ public class IcResiServiceImpl implements IcResiService { * @param search * @return */ - LambdaQueryWrapper constructQueryWrapper4Coverage(String customerId, String agencyId, String queryPids, String categoryKey, String search) { + LambdaQueryWrapper constructQueryWrapper4Coverage(String customerId, String agencyId, String queryPids, String categoryKey, String search,String gridId) { LambdaQueryWrapper query = new LambdaQueryWrapper<>(); query.eq(IcResiUserEntity::getCustomerId, customerId); query.eq(IcResiUserEntity::getStatus, "0"); // 只查询0 正常的居民。 query.and(q -> q.eq(IcResiUserEntity::getAgencyId, agencyId).or().likeRight(IcResiUserEntity::getPids, queryPids)); + query.eq(StringUtils.isNotBlank(gridId), IcResiUserEntity::getGridId, gridId); if ("resi_xfry".equals(categoryKey)) { // 信访人员 query.eq(IcResiUserEntity::getIsXfry, true); diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java index 26faa47e81..442166f157 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/GovOrgCoverageService.java @@ -112,7 +112,7 @@ public interface GovOrgCoverageService { Integer countSuporiorResourceEntities(String customerId, String staffOrgIds, String search, String categoryKey); - Integer countEnterprisePatrol(String customerId, String agencyId, String staffOrgIds, String search, String categoryKey,String latestResult); + Integer countEnterprisePatrol(String customerId, String agencyId, String staffOrgIds, String search, String categoryKey,String latestResult,String gridId); List listEnterprisePatrol(String customerId, String agencyId, String staffOrgIds, String search, String categoryKey, Boolean isPage, Integer pageNo, diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java index 56b32dad29..4e0382068a 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java @@ -293,8 +293,8 @@ public class GovOrgCoverageServiceImpl implements GovOrgCoverageService { } @Override - public Integer countEnterprisePatrol(String customerId, String agencyId, String staffOrgIds, String search, String categoryKey,String latestResult) { - return enterprisePatrolRecordDao.countEnterprisePatrol(customerId, agencyId, staffOrgIds, search, categoryKey,latestResult); + public Integer countEnterprisePatrol(String customerId, String agencyId, String staffOrgIds, String search, String categoryKey,String latestResult,String gridId) { + return enterprisePatrolRecordDao.countEnterprisePatrol(customerId, agencyId, staffOrgIds, search, categoryKey,latestResult,gridId); } @Override diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/GovProjectService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/GovProjectService.java index e64525a1fc..ce23a1ed02 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/GovProjectService.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/GovProjectService.java @@ -4,7 +4,6 @@ import com.epmet.commons.tools.security.dto.TokenDto; import com.epmet.dataaggre.dto.govissue.result.IssueListResultDTO; import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; import com.epmet.dataaggre.dto.govorg.result.EventInfoResultDTO; -import com.epmet.dataaggre.dto.govorg.result.ResourceInfoResultDTO; import com.epmet.dataaggre.dto.govproject.form.*; import com.epmet.dataaggre.dto.govproject.result.*; import com.epmet.dataaggre.entity.govproject.IcEventEntity; @@ -111,7 +110,7 @@ public interface GovProjectService { * @param isDifficultPoint 是否是难点堵点 * @return */ - Integer countIcEventEntities(String customerId, String staffOrgIds, String search, Boolean isDifficultPoint); + Integer countIcEventEntities(String customerId, String staffOrgIds, String search, Boolean isDifficultPoint,String gridId); /** * 搜索事件 diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/impl/GovProjectServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/impl/GovProjectServiceImpl.java index 0a400fe927..8cd50eb6eb 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/impl/GovProjectServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/impl/GovProjectServiceImpl.java @@ -28,7 +28,6 @@ import com.epmet.dataaggre.dto.govissue.result.IssueInfoDTO; import com.epmet.dataaggre.dto.govissue.result.IssueListResultDTO; import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; import com.epmet.dataaggre.dto.govorg.result.EventInfoResultDTO; -import com.epmet.dataaggre.dto.govorg.result.ResourceInfoResultDTO; import com.epmet.dataaggre.dto.govproject.ProjectDTO; import com.epmet.dataaggre.dto.govproject.ProjectRelatedPersonnelDTO; import com.epmet.dataaggre.dto.govproject.ResiEventDTO; @@ -653,15 +652,15 @@ public class GovProjectServiceImpl implements GovProjectService { } @Override - public Integer countIcEventEntities(String customerId, String staffOrgIds, String search, Boolean isDifficultPoint) { - LambdaQueryWrapper query = constructIcEventQueryWrapper(customerId, staffOrgIds, search, isDifficultPoint); + public Integer countIcEventEntities(String customerId, String staffOrgIds, String search, Boolean isDifficultPoint, String gridId) { + LambdaQueryWrapper query = constructIcEventQueryWrapper(customerId, staffOrgIds, search, isDifficultPoint,gridId); return icEventDao.selectCount(query); } @Override public List searchIcEventEntities(String customerId, String staffOrgIds, String search, Boolean isDifficultPoint, Boolean isPage, Integer pageNo, Integer pageSize) { - LambdaQueryWrapper query = constructIcEventQueryWrapper(customerId, staffOrgIds, search, isDifficultPoint); + LambdaQueryWrapper query = constructIcEventQueryWrapper(customerId, staffOrgIds, search, isDifficultPoint,null); if (isPage) { PageHelper.startPage(pageNo, pageSize); } @@ -682,9 +681,10 @@ public class GovProjectServiceImpl implements GovProjectService { * @return */ private LambdaQueryWrapper constructIcEventQueryWrapper(String customerId, String staffOrgIds, - String search, Boolean difficultPoint) { + String search, Boolean difficultPoint, String gridId) { LambdaQueryWrapper query = new LambdaQueryWrapper<>(); - query.eq(IcEventEntity::getCustomerId, customerId); + query.eq(IcEventEntity::getCustomerId, customerId) + .eq(StringUtils.isNotBlank(gridId), IcEventEntity::getGridId, gridId); query.likeRight(IcEventEntity::getGridPids, staffOrgIds); if (StringUtils.isNotBlank(search)) { query.like(IcEventEntity::getName, search); diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index 230b70de37..f19f599b4e 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -157,7 +157,7 @@ public class CoverageServiceImpl implements CoverageService { for (GovOrgCoverageService.CategoryCoverageMapping e : ccm) { Integer tempCount = doDataListCount(EpmetRequestHolder.getLoginUserCustomerId(), agencyId, agencyPath, e.getPlaceType(), - e.getCategoryKey(), search); + e.getCategoryKey(), search,null); lastTotalCount = totalCount; totalCount += tempCount; @@ -560,18 +560,18 @@ public class CoverageServiceImpl implements CoverageService { * @return */ public Integer doDataListCount(String customerId, String agencyId, String staffOrgIds, String placeType, - String categoryKey, String search) { + String categoryKey, String search,String gridId) { if (CoveragePlaceTypeEnum.RESI.getCode().equals(placeType)) { // 使用分类查询居民信息 return icResiService.countResisByCategories4Coverage(customerId, agencyId, - staffOrgIds, categoryKey, search); + staffOrgIds, categoryKey, search,gridId); } else if (CoveragePlaceTypeEnum.SPECIAL_RESI.getCode().equals(placeType)) { // 特殊人群 return icResiService.countSpecialResisBySpecialType(customerId, agencyId, staffOrgIds, categoryKey, search); } else if (CoveragePlaceTypeEnum.EVENT.getCode().equals(placeType)) { // 难点痛点 - return govProjectService.countIcEventEntities(customerId, staffOrgIds, search, true); + return govProjectService.countIcEventEntities(customerId, staffOrgIds, search, true,gridId); } else if (CoveragePlaceTypeEnum.CITY_MANAGEMENT.getCode().equals(placeType)) { // 城市资源管理 return orgCoverageService.countCityResourceEntities(customerId, staffOrgIds, search, categoryKey); @@ -589,7 +589,7 @@ public class CoverageServiceImpl implements CoverageService { return orgCoverageService.countDangerousChemicalEntities(customerId, staffOrgIds, search, categoryKey); } else if (CoveragePlaceTypeEnum.ENTERPRISE_PATROL.getCode().equals(placeType)) { // 企事业单位巡查 - return orgCoverageService.countEnterprisePatrol(customerId, agencyId, staffOrgIds, search, categoryKey,null); + return orgCoverageService.countEnterprisePatrol(customerId, agencyId, staffOrgIds, search, categoryKey,null,null); } else if (CoveragePlaceTypeEnum.GROUP_RENT.getCode().equals(placeType)) { // 群租房。出租的房屋,住的人口超过5人属于群租房(是个规定 return orgCoverageService.countByResiNumber(customerId, staffOrgIds, search, 5, HOUSE_RENT_FLAG_RENT); @@ -602,7 +602,7 @@ public class CoverageServiceImpl implements CoverageService { } else if(CoveragePlaceTypeEnum.ENTERPRISE_PATROL_UNQUALIFIED.getCode().equals(placeType)){ // 企事业单位巡查 // 最新巡查结果【0:合格 1:不合格】 - return orgCoverageService.countEnterprisePatrol(customerId, agencyId, staffOrgIds, search, categoryKey,NumConstant.ONE_STR ); + return orgCoverageService.countEnterprisePatrol(customerId, agencyId, staffOrgIds, search, categoryKey,NumConstant.ONE_STR,gridId); } return 0; @@ -1068,10 +1068,24 @@ public class CoverageServiceImpl implements CoverageService { if(CollectionUtils.isNotEmpty(list)){ resultList=ConvertUtils.sourceToTarget(list,DataListLeftSubTotalResDTO.class); for(DataListLeftSubTotalResDTO orgRes:resultList){ - - - - + String gridId=StrConstant.EPMETY_STR; + String agencyId=StrConstant.EPMETY_STR; + String orgIdPath=StrConstant.EPMETY_STR; + if(OrgConstant.AGENCY.equals(orgRes.getOrgType())){ + agencyId=orgRes.getOrgId(); + AgencyInfoCache agencyInfoCache=CustomerOrgRedis.getAgencyInfo(orgRes.getOrgId()); + if (StringUtils.isNotBlank(agencyInfoCache.getPids()) && !"0".equals(agencyInfoCache.getPids()) && !"0".equals(agencyInfoCache)) { + orgIdPath = agencyInfoCache.getPids().concat(":").concat(agencyId); + } else { + orgIdPath = agencyId; + } + }else{ + gridId=orgRes.getOrgId(); + GridInfoCache gridInfoCache=CustomerOrgRedis.getGridInfo(orgRes.getOrgId()); + orgIdPath=gridInfoCache.getPids().concat(":").concat(gridId); + } + int count = doDataListCount(formDTO.getCustomerId(), agencyId, orgIdPath, formDTO.getPlaceType(), formDTO.getCategoryKey(), null, gridId); + orgRes.setTotal(count); } } return resultList; diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcEnterprisePatrolRecordDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcEnterprisePatrolRecordDao.xml index c682c31548..523d80abb3 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcEnterprisePatrolRecordDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcEnterprisePatrolRecordDao.xml @@ -17,6 +17,9 @@ and e.LATEST_RESULT = #{latestResult} + + and e.GRID_ID = #{gridId} + From b4a04e73d9779e45f9b992c962e442c11e17ab53 Mon Sep 17 00:00:00 2001 From: wangxianzhang Date: Fri, 29 Jul 2022 12:53:50 +0800 Subject: [PATCH 113/155] =?UTF-8?q?=E3=80=90=E5=9B=BE=E5=B1=82=E3=80=91?= =?UTF-8?q?=E5=8F=AF=E8=A7=86=E5=8C=96-=201.=E5=B0=86=E5=8F=B3=E4=BE=A7?= =?UTF-8?q?=E8=B5=84=E6=BA=90=E7=9A=84quantity=E6=9F=A5=E8=AF=A2=E6=94=B9?= =?UTF-8?q?=E4=B8=BA=E5=A4=9A=E7=BA=BF=E7=A8=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../AnalysisResourceCategoriesResult.java | 5 +- .../controller/CoverageController.java | 5 +- .../govorg/IcCoverageCategoryDictEntity.java | 5 - .../dataaggre/service/CoverageService.java | 2 +- .../service/impl/CoverageServiceImpl.java | 133 +++++++++++++----- .../entity/IcCoverageCategoryDictEntity.java | 4 - 6 files changed, 102 insertions(+), 52 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/coverage/AnalysisResourceCategoriesResult.java b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/coverage/AnalysisResourceCategoriesResult.java index a6ab7996ab..4bfd7e83c1 100644 --- a/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/coverage/AnalysisResourceCategoriesResult.java +++ b/epmet-module/data-aggregator/data-aggregator-client/src/main/java/com/epmet/dataaggre/dto/coverage/AnalysisResourceCategoriesResult.java @@ -6,6 +6,7 @@ import lombok.NoArgsConstructor; import java.util.ArrayList; import java.util.List; +import java.util.concurrent.atomic.AtomicInteger; /** * 五大图层-可视化-右侧分类树列表 @@ -26,7 +27,7 @@ public class AnalysisResourceCategoriesResult { /** * 个数 */ - private Integer quantity; + private AtomicInteger quantity = new AtomicInteger(0); /** * 没有placeTypeInAnalysis,直接属于图层的 @@ -61,7 +62,7 @@ public class AnalysisResourceCategoriesResult { public static class PlaceType { private String placeType; private String placeTypeName; - private Integer quantity = 0; + private AtomicInteger quantity = new AtomicInteger(0); private List categories; } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java index d64f0866a5..44be5f6dc9 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/controller/CoverageController.java @@ -89,8 +89,9 @@ public class CoverageController { * @return */ @PostMapping("analysis/resourceCategories") - public Result> listAnalysisResourceCategories() { - List r = coverageService.listAnalysisResourceCategories(); + public Result> listAnalysisResourceCategories(@RequestBody Map input) { + String agencyId = input.get("agencyId"); + List r = coverageService.listAnalysisResourceCategories(agencyId); return new Result>().ok(r); } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCoverageCategoryDictEntity.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCoverageCategoryDictEntity.java index 1ea7222208..bc0ae5c9e2 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCoverageCategoryDictEntity.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCoverageCategoryDictEntity.java @@ -60,11 +60,6 @@ public class IcCoverageCategoryDictEntity extends BaseEpmetEntity { private String dataType; - /** - * 数量 - */ - private Integer quantity; - /** * 排序 */ diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java index 1dcb2907a4..8bd6fd9bd9 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/CoverageService.java @@ -40,7 +40,7 @@ public interface CoverageService { * 五大图层-可视化-右侧分类树列表 * @return */ - List listAnalysisResourceCategories(); + List listAnalysisResourceCategories(String agencyId); List listGovernedTargetCategories(String agencyId); diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index 0bc9878dc4..40595b8d39 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -7,6 +7,7 @@ import com.epmet.commons.tools.enums.CoverageEnums; import com.epmet.commons.tools.enums.CoveragePlaceTypeEnum; import com.epmet.commons.tools.exception.EpmetErrorCode; import com.epmet.commons.tools.exception.EpmetException; +import com.epmet.commons.tools.exception.ExceptionUtils; import com.epmet.commons.tools.page.PageData; import com.epmet.commons.tools.redis.common.CustomerOrgRedis; import com.epmet.commons.tools.redis.common.CustomerStaffRedis; @@ -458,10 +459,11 @@ public class CoverageServiceImpl implements CoverageService { return heartService.countCommunityOrgEntities(customerId, agencyId, staffOrgIds, search, categoryKey); } else if (CoveragePlaceTypeEnum.PARTY_UNIT.getCode().equals(placeType)) { // 机关直属部门(联建单位) 楼宇党建 0;两新组织 1;区域单位党建 2;机关直属部门 3;社会团体 4;民办非企业单位 5;基金会 6;其他 7 - if (categoryKey.equals("pu_jgzsbm")) { - String partyUnitType = "3"; - return heartService.countPartyUnitEntities(customerId, agencyId, staffOrgIds, partyUnitType, search); - } +// if (categoryKey.equals("pu_jgzsbm")) { +// String partyUnitType = "3"; +// } + String[] parts = categoryKey.split("_"); + return heartService.countPartyUnitEntities(customerId, agencyId, staffOrgIds, parts[1], search); } else if (CoveragePlaceTypeEnum.DANGEROUS_CHEMICALS.getCode().equals(placeType)) { // 危化企业 return orgCoverageService.countDangerousChemicalEntities(customerId, staffOrgIds, search, categoryKey); @@ -568,17 +570,16 @@ public class CoverageServiceImpl implements CoverageService { } else if (CoveragePlaceTypeEnum.PARTY_UNIT.getCode().equals(placeType)) { // 机关直属部门(联建单位) 楼宇党建 0;两新组织 1;区域单位党建 2;机关直属部门 3;社会团体 4;民办非企业单位 5;基金会 6;其他 7 - if (categoryKey.equals("pu_jgzsbm")) { - String partyUnitType = "3"; - List l = heartService.searchPartyUnitEntities( - customerId, agencyId, staffOrgIds, partyUnitType, search, isPage, pageNo, pageSize); - - return l.stream() - .map(dc -> new CoverageAnalisisDataListResultDTO(dc.getId(), categoryKey, - isPage ? categoryDict.getCategoryName() : null, placeType, isPage ? dc.getUnitName() : null, dc.getLatitude(), dc.getLongitude())) - .collect(Collectors.toList()); - } - return new ArrayList<>(); +// if (categoryKey.equals("pu_jgzsbm")) { +// String partyUnitType = "3"; +// } + String[] parts = categoryKey.split("_"); + List l = heartService.searchPartyUnitEntities( + customerId, agencyId, staffOrgIds, parts[1], search, isPage, pageNo, pageSize); + return l.stream() + .map(dc -> new CoverageAnalisisDataListResultDTO(dc.getId(), categoryKey, + isPage ? categoryDict.getCategoryName() : null, placeType, isPage ? dc.getUnitName() : null, dc.getLatitude(), dc.getLongitude())) + .collect(Collectors.toList()); } else if (CoveragePlaceTypeEnum.DANGEROUS_CHEMICALS.getCode().equals(placeType)) { // 危化企业 List l = orgCoverageService.searchDangerousChemicalEntities( @@ -680,7 +681,7 @@ public class CoverageServiceImpl implements CoverageService { * @return */ @Override - public List listAnalysisResourceCategories() { + public List listAnalysisResourceCategories(String agencyId) { // 获取所有菜单的url List menuUrls = new ArrayList<>(128); @@ -700,7 +701,7 @@ public class CoverageServiceImpl implements CoverageService { continue; } - AnalysisResourceCategoriesResult categoriesOfThisCoverage = new AnalysisResourceCategoriesResult(); + AnalysisResourceCategoriesResult coverageResult = new AnalysisResourceCategoriesResult(); HashMap placeTypeMap = new HashMap<>(); List categoryDictEntities = govOrgCoverageService.listResourceCategoryEntities(coverage.getKey()); @@ -714,9 +715,9 @@ public class CoverageServiceImpl implements CoverageService { if (StringUtils.isBlank(category.getPlaceTypeInAnalysis())) { // 没有placetype的 if ("all".equals(category.getMenuUrl()) || menuUrls.contains(category.getMenuUrl())) { - categoriesOfThisCoverage.getCategories() + coverageResult.getCategories() .add(new AnalysisResourceCategoriesResult.Category(category.getCategoryKey(), category.getCategoryName(), - category.getCoverageType(), category.getPlaceType(), category.getQuantity())); + category.getCoverageType(), category.getPlaceType(), 0)); } } else { // 有placetype的 @@ -725,33 +726,94 @@ public class CoverageServiceImpl implements CoverageService { if (placeType == null) { placeType = new AnalysisResourceCategoriesResult.PlaceType( - category.getPlaceTypeInAnalysis(), CoveragePlaceTypeEnum.getEnum(category.getPlaceTypeInAnalysis()).getName(), category.getQuantity(), new ArrayList<>()); + category.getPlaceTypeInAnalysis(), CoveragePlaceTypeEnum.getEnum(category.getPlaceTypeInAnalysis()).getName(), new AtomicInteger(0), new ArrayList<>()); placeTypeMap.put(category.getPlaceTypeInAnalysis(), placeType); } placeType.getCategories().add(new AnalysisResourceCategoriesResult.Category(category.getCategoryKey(), - category.getCategoryName(), category.getCoverageType(), category.getPlaceType(), category.getQuantity())); - placeType.setQuantity(placeType.getQuantity() + category.getQuantity()); // todo 0改为category的count + category.getCategoryName(), category.getCoverageType(), category.getPlaceType(), 0)); } } }); - AtomicReference total = new AtomicReference<>(0); placeTypeMap.forEach((placeTypeKey, placeType) -> { - categoriesOfThisCoverage.getPlaceTypesInAnalysis().add(placeType); - total.updateAndGet(v -> v + placeType.getQuantity()); + coverageResult.getPlaceTypesInAnalysis().add(placeType); }); - categoriesOfThisCoverage.setCoverageType(coverage.getKey()); - categoriesOfThisCoverage.setCoverageName(CoverageEnums.getEnum(coverage.getKey()).getCoverageName()); - categoriesOfThisCoverage.setQuantity(total.get()); - results.add(categoriesOfThisCoverage); + coverageResult.setCoverageType(coverage.getKey()); + coverageResult.setCoverageName(CoverageEnums.getEnum(coverage.getKey()).getCoverageName()); + results.add(coverageResult); } + String customerId = EpmetRequestHolder.getLoginUserCustomerId(); + String userId = EpmetRequestHolder.getLoginUserId(); + + Map stafInfoMap=getStaffPidsFromStaffInfo(customerId, userId, agencyId,OrgConstant.AGENCY); + String staffOrgPath = stafInfoMap.get(OrgConstant.AGENC_PATH); + + // 填充数量quantity字段 + fillQuantities4ResourcesCoverages(results, customerId, agencyId, staffOrgPath); + return results; } + private void fillQuantities4ResourcesCoverages(ArrayList coverages, String customerId, String agencyId, String staffOrgIds) { + + ArrayList> futures = new ArrayList<>(); + + coverages.forEach(coverage -> { + List categoriesInCoverage = coverage.getCategories(); + List placeTypesInCoverage = coverage.getPlaceTypesInAnalysis(); + + if (CollectionUtils.isNotEmpty(categoriesInCoverage)) { + // 直属于图层的category。异步提交计算任务 + CompletableFuture future = CompletableFuture.runAsync(() -> fillQuantities4ResourcesCategories(coverage, null, categoriesInCoverage, customerId, agencyId, staffOrgIds)); + futures.add(future); + } + if (CollectionUtils.isNotEmpty(placeTypesInCoverage)) { + // placeType,需要拆开来算, 异步提交计算任务 + placeTypesInCoverage.forEach(placeType -> { + List categoriesInPlaceType = placeType.getCategories(); + CompletableFuture future = CompletableFuture.runAsync(() -> fillQuantities4ResourcesCategories(coverage, placeType, categoriesInPlaceType, customerId, agencyId, staffOrgIds)); + futures.add(future); + }); + } + }); + + // 等待异步任务计算完成 + futures.forEach(f -> { + try { + f.get(); + } catch (InterruptedException e) { + log.error("【五大图层】可视化-右侧资源列表异步计算数量quantity失败,计算被中止,错误信息:{}", ExceptionUtils.getErrorStackTrace(e)); + } catch (ExecutionException e) { + log.error("【五大图层】可视化-右侧资源列表异步计算数量quantity失败,错误信息:{}", ExceptionUtils.getErrorStackTrace(e)); + } + }); + } + + private void fillQuantities4ResourcesCategories(AnalysisResourceCategoriesResult coverage, + AnalysisResourceCategoriesResult.PlaceType placeType, + List categories, + String customerId, String agencyId, String staffOrgIds) { + + AtomicInteger total = new AtomicInteger(); + + categories.forEach(cat -> { + Integer quantity = doDataListCount(customerId, agencyId, staffOrgIds, cat.getPlaceType(), cat.getCategoryKey(), null); + cat.setQuantity(quantity); + total.getAndAdd(quantity); + }); + + // 分别给所属的coverage和placeType的quantity增加quantity + coverage.getQuantity().getAndAdd(total.get()); + + if (placeType != null) { + placeType.getQuantity().getAndAdd(total.get()); + } + } + @Override public List listGovernedTargetCategories(String agencyId) { @@ -776,7 +838,6 @@ public class CoverageServiceImpl implements CoverageService { List results = new ArrayList<>(); HashMap> placeTypeTargetMap = new HashMap<>(); - HashMap placeTypeQuantityMap = new HashMap<>(); targetCategories.forEach(rc -> { String placeTypeInAnalysis = rc.getPlaceTypeInAnalysis(); @@ -790,7 +851,7 @@ public class CoverageServiceImpl implements CoverageService { // 只有一层,没有子级 if (menuUrls.contains(rc.getMenuUrl()) || "all".equals(rc.getMenuUrl())) { results.add(new AnalysisGovernedTargetsResult(rc.getCategoryKey(), rc.getCategoryName(), rc.getCoverageType(), - rc.getPlaceType(), CoveragePlaceTypeEnum.getEnum(rc.getPlaceType()).getName(), rc.getQuantity(), new ArrayList<>())); + rc.getPlaceType(), CoveragePlaceTypeEnum.getEnum(rc.getPlaceType()).getName(), 0, new ArrayList<>())); } } else { // 有子级,需要使用placeTypeInAnalysis分组 @@ -799,12 +860,9 @@ public class CoverageServiceImpl implements CoverageService { if (CollectionUtils.isEmpty(targets)) { targets = new ArrayList<>(); placeTypeTargetMap.put(placeTypeInAnalysis, targets); - placeTypeQuantityMap.put(placeTypeInAnalysis, 0); } targets.add(new AnalysisGovernedTargetsResult(rc.getCategoryKey(), rc.getCategoryName(), rc.getCoverageType(), - rc.getPlaceType(), CoveragePlaceTypeEnum.getEnum(rc.getPlaceType()).getName(), rc.getQuantity(), new ArrayList<>())); - - placeTypeQuantityMap.put(placeTypeInAnalysis, placeTypeQuantityMap.get(placeTypeInAnalysis) + rc.getQuantity()); + rc.getPlaceType(), CoveragePlaceTypeEnum.getEnum(rc.getPlaceType()).getName(), 0, new ArrayList<>())); } } }); @@ -814,7 +872,6 @@ public class CoverageServiceImpl implements CoverageService { placeTypeTargetMap.forEach((placeTypeInAnalysis, targetObjects) -> { AnalysisGovernedTargetsResult tr = new AnalysisGovernedTargetsResult(); tr.setPlaceType(placeTypeInAnalysis); - tr.setQuantity(placeTypeQuantityMap.get(placeTypeInAnalysis)); tr.setPlaceTypeName(CoveragePlaceTypeEnum.getEnum(placeTypeInAnalysis).getName()); tr.setChildren(targetObjects); results.add(tr); @@ -854,9 +911,9 @@ public class CoverageServiceImpl implements CoverageService { try { future.get(); } catch (InterruptedException e) { - e.printStackTrace(); + log.error("【五大图层】可视化-左侧异步计算数量quantity失败,计算被中止,错误信息:{}", ExceptionUtils.getErrorStackTrace(e)); } catch (ExecutionException e) { - e.printStackTrace(); + log.error("【五大图层】可视化-左侧异步计算数量quantity失败,错误信息:{}", ExceptionUtils.getErrorStackTrace(e)); } }); } diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcCoverageCategoryDictEntity.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcCoverageCategoryDictEntity.java index 57fbe777e1..7fd612e013 100755 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcCoverageCategoryDictEntity.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcCoverageCategoryDictEntity.java @@ -62,10 +62,6 @@ public class IcCoverageCategoryDictEntity extends BaseEpmetEntity { private String coverageType; private String dataType; - /** - * 数量 - */ - private Integer quantity; /** * 排序 */ From 1fbdc3df6530e33c62c9b90f9ce9f8a28852601a Mon Sep 17 00:00:00 2001 From: wangxianzhang Date: Fri, 29 Jul 2022 13:01:44 +0800 Subject: [PATCH 114/155] =?UTF-8?q?=E3=80=90=E5=9B=BE=E5=B1=82=E3=80=91?= =?UTF-8?q?=E5=8F=AF=E8=A7=86=E5=8C=96-=E8=A1=A5=E5=85=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../epmet/dataaggre/service/impl/CoverageServiceImpl.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index 2a5ccfb5cb..523b1f1fbe 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -929,7 +929,7 @@ public class CoverageServiceImpl implements CoverageService { AtomicInteger total = new AtomicInteger(); categories.forEach(cat -> { - Integer quantity = doDataListCount(customerId, agencyId, staffOrgIds, cat.getPlaceType(), cat.getCategoryKey(), null); + Integer quantity = doDataListCount(customerId, agencyId, staffOrgIds, cat.getPlaceType(), cat.getCategoryKey(), null, null); cat.setQuantity(quantity); total.getAndAdd(quantity); }); @@ -1058,7 +1058,7 @@ public class CoverageServiceImpl implements CoverageService { if (CollectionUtils.isEmpty(children)) { // 城市管理时间 || 安全生产隐患等只有一层的 Integer quantity = doDataListCount(customerId, agencyId, staffOrgIds, targetsOfOnePlaceType.getPlaceType(), - targetsOfOnePlaceType.getCategoryKey(), null); + targetsOfOnePlaceType.getCategoryKey(), null, null); targetsOfOnePlaceType.setQuantity(quantity); } else { // 综合治理人群 || 公共服务人群等有子级的 @@ -1066,7 +1066,7 @@ public class CoverageServiceImpl implements CoverageService { AtomicInteger totalOfPlaceType = new AtomicInteger(); children.forEach(governedTarget -> { Integer quantity = doDataListCount(customerId, agencyId, staffOrgIds, governedTarget.getPlaceType(), - governedTarget.getCategoryKey(), null); + governedTarget.getCategoryKey(), null, null); governedTarget.setQuantity(quantity); totalOfPlaceType.addAndGet(quantity); }); From 9d39b0116342e524f71eafa91143e87b7007965e Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Fri, 29 Jul 2022 13:28:46 +0800 Subject: [PATCH 115/155] duole , --- .../src/main/resources/mapper/govorg/CustomerGridDao.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/CustomerGridDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/CustomerGridDao.xml index 356819c9e5..7f68c5d787 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/CustomerGridDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/CustomerGridDao.xml @@ -49,7 +49,7 @@ id AS "gridId", grid_name AS "gridName", LATITUDE as latitude, - LONGITUDE as longitude, + LONGITUDE as longitude FROM customer_grid WHERE From 0e078901e9d0cf83ef27e604452dc5dc1a7b3050 Mon Sep 17 00:00:00 2001 From: wangxianzhang Date: Fri, 29 Jul 2022 13:35:37 +0800 Subject: [PATCH 116/155] =?UTF-8?q?=E3=80=90=E5=9B=BE=E5=B1=82=E3=80=91sql?= =?UTF-8?q?=E8=A1=A8=E7=BB=93=E6=9E=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../resources/db/migration/V0.0.38__coverage_update.sql | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 epmet-module/gov-org/gov-org-server/src/main/resources/db/migration/V0.0.38__coverage_update.sql diff --git a/epmet-module/gov-org/gov-org-server/src/main/resources/db/migration/V0.0.38__coverage_update.sql b/epmet-module/gov-org/gov-org-server/src/main/resources/db/migration/V0.0.38__coverage_update.sql new file mode 100644 index 0000000000..4dffe25831 --- /dev/null +++ b/epmet-module/gov-org/gov-org-server/src/main/resources/db/migration/V0.0.38__coverage_update.sql @@ -0,0 +1,6 @@ +alter table ic_coverage_category_dict + add column PLACE_TYPE_IN_ANALYSIS varchar(32) comment '在可视化系统中所属的plact_type,跟COVERAGE_TYPE可能不同,COVERAGE_TYPE是给管理平台用的' after PLACE_TYPE; +alter table ic_coverage_category_dict + add column MENU_URL varchar(200) comment '要跟菜单绑定(客户配置了这个菜单,这里才显示)' after PLACE_TYPE_IN_ANALYSIS; +alter table ic_coverage_category_dict + add column DATA_TYPE varchar(32) comment '数据类别(governedTarget:被管理对象;resources:资源列表)' after MENU_URL; \ No newline at end of file From 7069a3c978e70fa686757f1ff5c46107e25ec8ef Mon Sep 17 00:00:00 2001 From: zxc <1272811460@qq.com> Date: Fri, 29 Jul 2022 13:45:09 +0800 Subject: [PATCH 117/155] =?UTF-8?q?=E4=BA=94=E5=A4=A7=E5=9B=BE=E5=B1=82?= =?UTF-8?q?=E9=A6=96=E9=A1=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/CoverageServiceImpl.java | 15 ++++++--------- .../resources/mapper/epmetuser/IcResiUserDao.xml | 11 +++++++++-- .../resources/mapper/govproject/IcEventDao.xml | 13 ++++++++++--- 3 files changed, 25 insertions(+), 14 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index 523b1f1fbe..943680915d 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -60,9 +60,6 @@ import java.util.concurrent.CompletableFuture; import java.util.concurrent.ExecutionException; import java.util.concurrent.ExecutorService; import java.util.concurrent.atomic.AtomicInteger; -import java.util.concurrent.CompletableFuture; -import java.util.concurrent.ExecutionException; -import java.util.concurrent.atomic.AtomicReference; import java.util.stream.Collectors; @Slf4j @@ -269,22 +266,22 @@ public class CoverageServiceImpl implements CoverageService { List>> futures = new ArrayList<>(); for (String resource : resources) { if (MenusEnums.IC_SUPERIOR_RESOURCE.getUrl().equals(resource)){ - CompletableFuture> c = CompletableFuture.supplyAsync(() -> govOrgService.getSuperiorResourceInfos(formDTO)); + CompletableFuture> c = CompletableFuture.supplyAsync(() -> govOrgService.getSuperiorResourceInfos(formDTO),executorService); futures.add(c); }else if (MenusEnums.IC_CITY_MANAGEMENT.getUrl().equals(resource)){ - CompletableFuture> c = CompletableFuture.supplyAsync(() -> govOrgService.getCityManageInfos(formDTO)); + CompletableFuture> c = CompletableFuture.supplyAsync(() -> govOrgService.getCityManageInfos(formDTO),executorService); futures.add(c); }else if (MenusEnums.IC_COMMUNITY_SELF_ORGANIZATION.getUrl().equals(resource)){ - CompletableFuture> c = CompletableFuture.supplyAsync(() -> heartService.getCommunitySelOrgInfos(formDTO)); + CompletableFuture> c = CompletableFuture.supplyAsync(() -> heartService.getCommunitySelOrgInfos(formDTO),executorService); futures.add(c); }else if (MenusEnums.IC_DANGEROUS_CHEMICALS.getUrl().equals(resource)){ - CompletableFuture> c = CompletableFuture.supplyAsync(() -> govOrgService.getDangerousChemicalsInfos(formDTO)); + CompletableFuture> c = CompletableFuture.supplyAsync(() -> govOrgService.getDangerousChemicalsInfos(formDTO),executorService); futures.add(c); }else if (MenusEnums.IC_ENTERPRISE.getUrl().equals(resource)){ - CompletableFuture> c = CompletableFuture.supplyAsync(() -> govOrgService.getEnterpriseInfos(formDTO)); + CompletableFuture> c = CompletableFuture.supplyAsync(() -> govOrgService.getEnterpriseInfos(formDTO),executorService); futures.add(c); }else if (MenusEnums.IC_PUBLIC_SERVICE.getUrl().equals(resource)){ - CompletableFuture> c = CompletableFuture.supplyAsync(() -> govOrgService.getPublicServiceInfos(formDTO)); + CompletableFuture> c = CompletableFuture.supplyAsync(() -> govOrgService.getPublicServiceInfos(formDTO),executorService); futures.add(c); } } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml index dfcd87920f..f883a695f9 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml @@ -164,11 +164,18 @@ ifnull(u.RHZK,'') as rhzk FROM ic_resi_user u WHERE u.DEL_FLAG = '0' - AND u.CUSTOMER_ID = #{customerId} + + AND u.CUSTOMER_ID = #{customerId} + + + AND u.id = #{icUserId} + AND u.`NAME` LIKE CONCAT('%',#{name},'%') - AND u.PIDS LIKE CONCAT('%',#{orgId},'%') + + AND u.PIDS LIKE CONCAT('%',#{orgId},'%') + diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govproject/IcEventDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govproject/IcEventDao.xml index 547ff69899..c037d97239 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govproject/IcEventDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govproject/IcEventDao.xml @@ -13,9 +13,16 @@ LATITUDE FROM ic_event WHERE del_flag = '0' - AND customer_id = #{customerId} - AND DIFFICULT_POINT = '1' - AND GRID_PIDS LIKE CONCAT('%',#{orgId},'%') + AND DIFFICULT_POINT = '1' + + AND customer_id = #{customerId} + + + AND GRID_PIDS LIKE CONCAT('%',#{orgId},'%') + + + AND id = #{icEventId} + AND EVENT_CONTENT LIKE CONCAT('%',#{name},'%') From 186bdcd448c41e8400cd2ff7bc6d9f15d9f72eb9 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Fri, 29 Jul 2022 14:01:18 +0800 Subject: [PATCH 118/155] =?UTF-8?q?=E4=B8=8B=E7=BA=A7=E7=BB=84=E7=BB=87.?= =?UTF-8?q?=E7=BD=91=E6=A0=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../epmet/dataaggre/service/impl/CoverageServiceImpl.java | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index 523b1f1fbe..f32f7bc6a1 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -60,9 +60,6 @@ import java.util.concurrent.CompletableFuture; import java.util.concurrent.ExecutionException; import java.util.concurrent.ExecutorService; import java.util.concurrent.atomic.AtomicInteger; -import java.util.concurrent.CompletableFuture; -import java.util.concurrent.ExecutionException; -import java.util.concurrent.atomic.AtomicReference; import java.util.stream.Collectors; @Slf4j @@ -1196,7 +1193,7 @@ public class CoverageServiceImpl implements CoverageService { @Override public List dataListLeftSubTotal(DataListLeftSubTotalFormDTO formDTO) { List resultList=new ArrayList<>(); - List list = SpringContextUtils.getBean(GovOrgService.class).queryNextOrgInfoDTO(formDTO.getCoverageType(), formDTO.getOrgId()); + List list = SpringContextUtils.getBean(GovOrgService.class).queryNextOrgInfoDTO(formDTO.getCustomerId(), formDTO.getOrgId()); if(CollectionUtils.isNotEmpty(list)){ resultList=ConvertUtils.sourceToTarget(list,DataListLeftSubTotalResDTO.class); for(DataListLeftSubTotalResDTO orgRes:resultList){ From 064e2d489c39cde4c76279099eda190dd617c48a Mon Sep 17 00:00:00 2001 From: wangxianzhang Date: Fri, 29 Jul 2022 14:23:40 +0800 Subject: [PATCH 119/155] =?UTF-8?q?=E3=80=90=E5=9B=BE=E5=B1=82=E3=80=91?= =?UTF-8?q?=E5=AE=8C=E5=96=84=EF=BC=9A=E9=92=88=E5=AF=B9=E6=96=B0=E5=A2=9E?= =?UTF-8?q?=E7=9A=84volunteer=E8=BF=99=E4=B8=AAplacetype=E9=80=82=E9=85=8D?= =?UTF-8?q?=E6=9F=A5=E8=AF=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dao/epmetuser/IcResiUserDao.java | 11 ++++ .../govorg/IcCoverageCategoryStatsDao.java | 16 ----- .../govorg/IcCoverageCategoryStatsEntity.java | 64 ------------------- .../service/epmetuser/EpmetUserService.java | 6 ++ .../epmetuser/impl/EpmetUserServiceImpl.java | 15 +++-- .../service/impl/CoverageServiceImpl.java | 23 +++++++ .../mapper/epmetuser/IcResiUserDao.xml | 38 +++++++++++ .../govorg/IcCoverageCategoryStatsDao.xml | 25 -------- 8 files changed, 89 insertions(+), 109 deletions(-) delete mode 100755 epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcCoverageCategoryStatsDao.java delete mode 100755 epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCoverageCategoryStatsEntity.java delete mode 100755 epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryStatsDao.xml diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/epmetuser/IcResiUserDao.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/epmetuser/IcResiUserDao.java index 9aaf933745..5e282e7145 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/epmetuser/IcResiUserDao.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/epmetuser/IcResiUserDao.java @@ -108,4 +108,15 @@ public interface IcResiUserDao extends BaseDao { */ List getAllIcUser(CoverageHomeSearchFormDTO formDTO); + Integer countVolunteersByCategory(@Param("customerId")String customerId, + @Param("agencyId")String agencyId, + @Param("staffOrgIds")String staffOrgIds, + @Param("search")String search, + @Param("resiCategory")String resiCategory); + + List listVolunteersByCategory(@Param("customerId")String customerId, + @Param("agencyId")String agencyId, + @Param("staffOrgIds")String staffOrgIds, + @Param("search")String search, + @Param("resiCategory")String resiCategory); } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcCoverageCategoryStatsDao.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcCoverageCategoryStatsDao.java deleted file mode 100755 index 2d179ee974..0000000000 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/govorg/IcCoverageCategoryStatsDao.java +++ /dev/null @@ -1,16 +0,0 @@ -package com.epmet.dataaggre.dao.govorg; - -import com.epmet.commons.mybatis.dao.BaseDao; -import com.epmet.dataaggre.entity.govorg.IcCoverageCategoryStatsEntity; -import org.apache.ibatis.annotations.Mapper; - -/** - * - * - * @author generator generator@elink-cn.com - * @since v1.0.0 2022-07-29 - */ -@Mapper -public interface IcCoverageCategoryStatsDao extends BaseDao { - -} \ No newline at end of file diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCoverageCategoryStatsEntity.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCoverageCategoryStatsEntity.java deleted file mode 100755 index 7947b31564..0000000000 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/entity/govorg/IcCoverageCategoryStatsEntity.java +++ /dev/null @@ -1,64 +0,0 @@ -package com.epmet.dataaggre.entity.govorg; - -import com.baomidou.mybatisplus.annotation.TableName; - -import com.epmet.commons.mybatis.entity.BaseEpmetEntity; -import lombok.Data; -import lombok.EqualsAndHashCode; - -import java.util.Date; - -/** - * - * - * @author generator generator@elink-cn.com - * @since v1.0.0 2022-07-29 - */ -@Data -@EqualsAndHashCode(callSuper=false) -@TableName("ic_coverage_category_stats") -public class IcCoverageCategoryStatsEntity extends BaseEpmetEntity { - - private static final long serialVersionUID = 1L; - - /** - * default;或者customerId - */ - private String customerId; - - /** - * agency,grid的id - */ - private String orgId; - - /** - * agency,grid的id - */ - private String orgType; - - /** - * agency,grid ID路径path,包含自身 - */ - private String orgIdPath; - - /** - * 类别key - */ - private String categoryKey; - - /** - * 所属场所类型。社区自组织:community_org;优势资源:superior_resource;城市管理:city_management;重点危化企业:dangerous_chemicals;公共服务:public_service;特殊人群:special_resi;居民:resi;联建单位:party_unit;群租房:group_rent;事件(包括难点堵点):event;企事业单位巡查:enterprise_patrol; - */ - private String placeType; - - /** - * 所属五大图层:zhzl:综合治理图层;yjcl:应急处置图层;aqsc:安全生产图层;csgl:城市管理图层;ggfw:公共服务图层 - */ - private String coverageType; - - /** - * - */ - private Integer quantity; - -} diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/EpmetUserService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/EpmetUserService.java index 01b9dae907..018e5ae902 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/EpmetUserService.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/EpmetUserService.java @@ -5,10 +5,12 @@ import com.epmet.dataaggre.dto.epmetuser.result.*; import com.epmet.dataaggre.dto.govorg.form.GridLivelyFormDTO; import com.epmet.dataaggre.dto.govorg.form.OrgStaffListFormDTO; import com.epmet.dataaggre.dto.govorg.form.StaffDetailV2FormDTO; +import com.epmet.dataaggre.dto.govorg.result.CoverageAnalisisDataListResultDTO; import com.epmet.dataaggre.dto.govorg.result.GridDateIdResultDTO; import com.epmet.dataaggre.dto.govorg.result.GridStaffResultDTO; import com.epmet.dataaggre.dto.govproject.result.ProjectAnalysisResultDTO; import com.epmet.dataaggre.entity.epmetuser.CustomerStaffEntity; +import com.epmet.dataaggre.entity.epmetuser.IcResiUserEntity; import com.epmet.dto.IcResiUserDTO; import com.epmet.dto.UserBaseInfoDTO; @@ -208,4 +210,8 @@ public interface EpmetUserService { Integer getTotalByPolicyRules(String customerId, String orgIdPath, String orgId, String orgType, String neighborHoodId, String buildingId, String unitId, String houseId, String idCard, String name, List resiRule, List houseIds); + + Integer countVolunteers(String customerId, String agencyId, String staffOrgIds, String search, String resiCategory); + + List listVolunteers(String customerId, String agencyId, String staffOrgIds, String search, String resiCategory); } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/EpmetUserServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/EpmetUserServiceImpl.java index 000affa6ff..b42e78b256 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/EpmetUserServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/EpmetUserServiceImpl.java @@ -31,10 +31,7 @@ import com.epmet.dataaggre.dto.govorg.result.GridStaffResultDTO; import com.epmet.dataaggre.dto.govorg.result.StaffOrgNameResultDTO; import com.epmet.dataaggre.dto.govorg.result.StaffOrgRelationResultDTO; import com.epmet.dataaggre.dto.govproject.result.ProjectAnalysisResultDTO; -import com.epmet.dataaggre.entity.epmetuser.CustomerStaffEntity; -import com.epmet.dataaggre.entity.epmetuser.GovStaffRoleEntity; -import com.epmet.dataaggre.entity.epmetuser.ResiUserBadgeEntity; -import com.epmet.dataaggre.entity.epmetuser.StaffRoleEntity; +import com.epmet.dataaggre.entity.epmetuser.*; import com.epmet.dataaggre.service.datastats.DataStatsService; import com.epmet.dataaggre.service.epmetuser.EpmetUserService; import com.epmet.dataaggre.service.epmetuser.StaffPatrolDetailService; @@ -857,4 +854,14 @@ public class EpmetUserServiceImpl implements EpmetUserService { public Integer getTotalByPolicyRules(String customerId, String orgIdPath, String orgId, String orgType, String neighborHoodId, String buildingId, String unitId, String houseId, String idCard, String name, List resiRule, List houseIds) { return icResiUserDao.getTotalByPolicyRules(customerId, orgIdPath, orgId, orgType, neighborHoodId, buildingId, unitId, houseId, idCard, name, resiRule, houseIds); } + + @Override + public Integer countVolunteers(String customerId, String agencyId, String staffOrgIds, String search, String resiCategory) { + return icResiUserDao.countVolunteersByCategory(customerId, agencyId, staffOrgIds, search, resiCategory); + } + + @Override + public List listVolunteers(String customerId, String agencyId, String staffOrgIds, String search, String resiCategory) { + return icResiUserDao.listVolunteersByCategory(customerId, agencyId, staffOrgIds, search, resiCategory); + } } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index 523b1f1fbe..b950371ffa 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -39,6 +39,7 @@ import com.epmet.dataaggre.entity.opercustomize.IcResiCategoryWarnConfigEntity; import com.epmet.dataaggre.enums.MenusEnums; import com.epmet.dataaggre.redis.GovCustomerMenuRedis; import com.epmet.dataaggre.service.CoverageService; +import com.epmet.dataaggre.service.epmetuser.EpmetUserService; import com.epmet.dataaggre.service.epmetuser.IcResiService; import com.epmet.dataaggre.service.govorg.GovOrgCoverageService; import com.epmet.dataaggre.service.govorg.GovOrgService; @@ -96,6 +97,9 @@ public class CoverageServiceImpl implements CoverageService { @Autowired private ExecutorService executorService; + @Autowired + private EpmetUserService epmetUserService; + // 1:出租 0:自住 2:闲置 3:未售出 public static final Integer HOUSE_RENT_FLAG_RENT = 1; @@ -611,6 +615,10 @@ public class CoverageServiceImpl implements CoverageService { // 企事业单位巡查 // 最新巡查结果【0:合格 1:不合格】 return orgCoverageService.countEnterprisePatrol(customerId, agencyId, staffOrgIds, search, categoryKey,NumConstant.ONE_STR,gridId); + } else if (CoveragePlaceTypeEnum.VOLUNTEER.getCode().equals(placeType)) { + // 志愿者 + String[] parts = categoryKey.split("_"); + return epmetUserService.countVolunteers(customerId, agencyId, staffOrgIds, search, parts[1]); } return 0; @@ -773,6 +781,21 @@ public class CoverageServiceImpl implements CoverageService { StringUtils.isNotBlank(dc.getLatitude()) ? dc.getLatitude() : rootAgency.getLatitude(), StringUtils.isNotBlank(dc.getLongitude()) ? dc.getLongitude() : rootAgency.getLongitude())) .collect(Collectors.toList()); + } else if (CoveragePlaceTypeEnum.VOLUNTEER.getCode().equals(placeType)) { + // 志愿者 + String[] parts = categoryKey.split("_"); + List resiEntities = epmetUserService.listVolunteers(customerId, agencyId, staffOrgIds, search, parts[1]); + + return resiEntities.parallelStream().map(re -> { + // 使用楼栋的坐标补充居民的坐标信息 + String[] coordinates = getUserCoordinates(re.getId(), re.getBuildId(), rootAgency); + + return new CoverageAnalisisDataListResultDTO( + re.getId(), categoryKey, isPage ? categoryDict.getCategoryName() : null, placeType, + re.getName().concat(StrConstant.BRACKET_LEFT).concat(re.getIdCard()).concat(StrConstant.BRACKET_RIGNT), + coordinates[1], coordinates[0]); + + }).collect(Collectors.toList()); } return new ArrayList<>(); } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml index dfcd87920f..23e2d967d6 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml @@ -171,4 +171,42 @@ AND u.PIDS LIKE CONCAT('%',#{orgId},'%') + + + + diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryStatsDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryStatsDao.xml deleted file mode 100755 index 2954d89db3..0000000000 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryStatsDao.xml +++ /dev/null @@ -1,25 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file From 03a952b4698735626aec7557afea4f5e7080dcc2 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Fri, 29 Jul 2022 14:24:23 +0800 Subject: [PATCH 120/155] =?UTF-8?q?=E5=AE=89=E5=85=A8=E7=94=9F=E4=BA=A7?= =?UTF-8?q?=E9=9A=90=E6=82=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../epmet/dataaggre/service/impl/CoverageServiceImpl.java | 2 +- .../mapper/govorg/IcEnterprisePatrolRecordDao.xml | 8 ++++++-- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index 1720dffbfc..282b336398 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -1211,7 +1211,7 @@ public class CoverageServiceImpl implements CoverageService { }else{ gridId=orgRes.getOrgId(); GridInfoCache gridInfoCache=CustomerOrgRedis.getGridInfo(orgRes.getOrgId()); - orgIdPath=gridInfoCache.getPids().concat(":").concat(gridId); + orgIdPath=gridInfoCache.getPids(); } int count = doDataListCount(formDTO.getCustomerId(), agencyId, orgIdPath, formDTO.getPlaceType(), formDTO.getCategoryKey(), null, gridId); orgRes.setTotal(count); diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcEnterprisePatrolRecordDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcEnterprisePatrolRecordDao.xml index 523d80abb3..1c7d0dd16e 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcEnterprisePatrolRecordDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcEnterprisePatrolRecordDao.xml @@ -8,8 +8,12 @@ select count(1) from ic_enterprise e where e.CUSTOMER_ID = #{customerId} - and e.PLACE_ORG_NAME like CONCAT('%',#{search},'%') - and (e.AGENCY_ID = #{agencyId} or e.AGENCY_PIDS like CONCAT(#{staffOrgIds}, '%')) + + and e.PLACE_ORG_NAME like CONCAT('%',#{search},'%') + + + and (e.AGENCY_ID = #{agencyId} or e.AGENCY_PIDS like CONCAT(#{staffOrgIds}, '%')) + and e.PLACE_TYPE = #{categoryKey} From 1f293b7709bca661c7efd78eb11bbbce0a9cd176 Mon Sep 17 00:00:00 2001 From: zxc <1272811460@qq.com> Date: Fri, 29 Jul 2022 14:25:44 +0800 Subject: [PATCH 121/155] =?UTF-8?q?=E6=9F=A5=E8=AF=A2ic=5Fcoverage=5Fcateg?= =?UTF-8?q?ory=5Fdict=E6=97=B6=EF=BC=8C=E6=96=B0=E5=A2=9Eevent?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../resources/mapper/govorg/IcCoverageCategoryDictDao.xml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryDictDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryDictDao.xml index c756992558..22a95a5720 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryDictDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govorg/IcCoverageCategoryDictDao.xml @@ -11,6 +11,14 @@ WHERE DEL_FLAG = '0' AND CUSTOMER_ID = #{customerId} AND data_type = #{dataType} + UNION ALL + SELECT + DISTINCT MENU_URL + FROM ic_coverage_category_dict + WHERE DEL_FLAG = '0' + AND CUSTOMER_ID = #{customerId} + AND data_type = 'governedTarget' + AND category_key = 'event_tdnd' From 2f98fb06e1975800b46653c7405f37f137e20c8f Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Fri, 29 Jul 2022 14:30:50 +0800 Subject: [PATCH 122/155] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E4=B8=8B=E5=A4=87?= =?UTF-8?q?=E6=B3=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../impl/GovOrgCoverageServiceImpl.java | 2 ++ .../impl/GovProjectServiceImpl.java | 3 +++ .../service/impl/CoverageServiceImpl.java | 24 +------------------ 3 files changed, 6 insertions(+), 23 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java index 4e0382068a..e5688434bc 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govorg/impl/GovOrgCoverageServiceImpl.java @@ -294,6 +294,8 @@ public class GovOrgCoverageServiceImpl implements GovOrgCoverageService { @Override public Integer countEnterprisePatrol(String customerId, String agencyId, String staffOrgIds, String search, String categoryKey,String latestResult,String gridId) { + // ic_enterprise.AGENCY_PIDS:agency_id的所有上级 + // 网格不为空时按网格查询, 网格为空时,根据agency_id或者AGENCY_PIDS查看 return enterprisePatrolRecordDao.countEnterprisePatrol(customerId, agencyId, staffOrgIds, search, categoryKey,latestResult,gridId); } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/impl/GovProjectServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/impl/GovProjectServiceImpl.java index 8cd50eb6eb..cfcef68cd5 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/impl/GovProjectServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/impl/GovProjectServiceImpl.java @@ -682,6 +682,9 @@ public class GovProjectServiceImpl implements GovProjectService { */ private LambdaQueryWrapper constructIcEventQueryWrapper(String customerId, String staffOrgIds, String search, Boolean difficultPoint, String gridId) { + //ic_event.grid_pids是网格所有的上级,不包括网格自己 + //ic_event.agency_id网格的所属组织 + //所以这staffOrgIds是组织的全路径 LambdaQueryWrapper query = new LambdaQueryWrapper<>(); query.eq(IcEventEntity::getCustomerId, customerId) .eq(StringUtils.isNotBlank(gridId), IcEventEntity::getGridId, gridId); diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index 2be9efef33..e0cbd88226 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -39,7 +39,6 @@ import com.epmet.dataaggre.entity.opercustomize.IcResiCategoryWarnConfigEntity; import com.epmet.dataaggre.enums.MenusEnums; import com.epmet.dataaggre.redis.GovCustomerMenuRedis; import com.epmet.dataaggre.service.CoverageService; -import com.epmet.dataaggre.service.epmetuser.EpmetUserService; import com.epmet.dataaggre.service.epmetuser.IcResiService; import com.epmet.dataaggre.service.govorg.GovOrgCoverageService; import com.epmet.dataaggre.service.govorg.GovOrgService; @@ -94,9 +93,6 @@ public class CoverageServiceImpl implements CoverageService { @Autowired private ExecutorService executorService; - @Autowired - private EpmetUserService epmetUserService; - // 1:出租 0:自住 2:闲置 3:未售出 public static final Integer HOUSE_RENT_FLAG_RENT = 1; @@ -611,11 +607,8 @@ public class CoverageServiceImpl implements CoverageService { } else if(CoveragePlaceTypeEnum.ENTERPRISE_PATROL_UNQUALIFIED.getCode().equals(placeType)){ // 企事业单位巡查 // 最新巡查结果【0:合格 1:不合格】 + // 左侧用,可以到网格, return orgCoverageService.countEnterprisePatrol(customerId, agencyId, staffOrgIds, search, categoryKey,NumConstant.ONE_STR,gridId); - } else if (CoveragePlaceTypeEnum.VOLUNTEER.getCode().equals(placeType)) { - // 志愿者 - String[] parts = categoryKey.split("_"); - return epmetUserService.countVolunteers(customerId, agencyId, staffOrgIds, search, parts[1]); } return 0; @@ -778,21 +771,6 @@ public class CoverageServiceImpl implements CoverageService { StringUtils.isNotBlank(dc.getLatitude()) ? dc.getLatitude() : rootAgency.getLatitude(), StringUtils.isNotBlank(dc.getLongitude()) ? dc.getLongitude() : rootAgency.getLongitude())) .collect(Collectors.toList()); - } else if (CoveragePlaceTypeEnum.VOLUNTEER.getCode().equals(placeType)) { - // 志愿者 - String[] parts = categoryKey.split("_"); - List resiEntities = epmetUserService.listVolunteers(customerId, agencyId, staffOrgIds, search, parts[1]); - - return resiEntities.parallelStream().map(re -> { - // 使用楼栋的坐标补充居民的坐标信息 - String[] coordinates = getUserCoordinates(re.getId(), re.getBuildId(), rootAgency); - - return new CoverageAnalisisDataListResultDTO( - re.getId(), categoryKey, isPage ? categoryDict.getCategoryName() : null, placeType, - re.getName().concat(StrConstant.BRACKET_LEFT).concat(re.getIdCard()).concat(StrConstant.BRACKET_RIGNT), - coordinates[1], coordinates[0]); - - }).collect(Collectors.toList()); } return new ArrayList<>(); } From 562c0469fe0a4ff66a333ad32712975ee4f17ebe Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Fri, 29 Jul 2022 14:44:10 +0800 Subject: [PATCH 123/155] =?UTF-8?q?=E7=89=B9=E6=AE=8A=E4=BA=BA=E7=BE=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/epmet/dataaggre/dao/epmetuser/IcResiUserDao.java | 3 ++- .../com/epmet/dataaggre/service/epmetuser/IcResiService.java | 2 +- .../dataaggre/service/epmetuser/impl/IcResiServiceImpl.java | 4 ++-- .../com/epmet/dataaggre/service/impl/CoverageServiceImpl.java | 2 +- .../src/main/resources/mapper/epmetuser/IcResiUserDao.xml | 3 +++ 5 files changed, 9 insertions(+), 5 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/epmetuser/IcResiUserDao.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/epmetuser/IcResiUserDao.java index 5e282e7145..610d90c62d 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/epmetuser/IcResiUserDao.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/epmetuser/IcResiUserDao.java @@ -62,7 +62,8 @@ public interface IcResiUserDao extends BaseDao { @Param("agencyId") String agencyId, @Param("queryPids") String queryPids, @Param("categoryKey") String categoryKey, - @Param("search") String search); + @Param("search") String search, + @Param("gridId")String gridId); /** * 政策查找居民 diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/IcResiService.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/IcResiService.java index aa9462d777..cf9f5f563d 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/IcResiService.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/IcResiService.java @@ -40,7 +40,7 @@ public interface IcResiService { List listSpecialResisBySpecialType(String customerId, String agencyId, String queryPids, String categoryKey, String search, Integer pageNo, Integer pageSize, Boolean isPage); - Integer countSpecialResisBySpecialType(String customerId, String agencyId, String staffOrgIds, String categoryKey, String search); + Integer countSpecialResisBySpecialType(String customerId, String agencyId, String staffOrgIds, String categoryKey, String search,String gridId); /** * Desc: 获取icUser diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/IcResiServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/IcResiServiceImpl.java index 1a3d919a65..10293c2a8f 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/IcResiServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/IcResiServiceImpl.java @@ -137,8 +137,8 @@ public class IcResiServiceImpl implements IcResiService { } @Override - public Integer countSpecialResisBySpecialType(String customerId, String agencyId, String staffOrgIds, String categoryKey, String search) { - return resiUserDao.countSpecialResisBySpecialType(customerId, agencyId, staffOrgIds, categoryKey, search); + public Integer countSpecialResisBySpecialType(String customerId, String agencyId, String staffOrgIds, String categoryKey, String search, String gridId) { + return resiUserDao.countSpecialResisBySpecialType(customerId, agencyId, staffOrgIds, categoryKey, search,gridId); } /** diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index e0cbd88226..b29ffcb853 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -572,7 +572,7 @@ public class CoverageServiceImpl implements CoverageService { staffOrgIds, categoryKey, search,gridId); } else if (CoveragePlaceTypeEnum.SPECIAL_RESI.getCode().equals(placeType)) { // 特殊人群 - return icResiService.countSpecialResisBySpecialType(customerId, agencyId, staffOrgIds, categoryKey, search); + return icResiService.countSpecialResisBySpecialType(customerId, agencyId, staffOrgIds, categoryKey, search,gridId); } else if (CoveragePlaceTypeEnum.EVENT.getCode().equals(placeType)) { // 难点痛点 return govProjectService.countIcEventEntities(customerId, staffOrgIds, search, true,gridId); diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml index fe6b98c3a8..92c000175c 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml @@ -63,6 +63,9 @@ and resi.NAME like CONCAT('%', #{search},'%') + + and resi.GRID_ID =#{gridId} + and s.SPECIAL_RQLB like CONCAT('%', #{categoryKey},'%') and resi.DEL_FLAG = '0' and s.DEL_FLAG = '0' From 63924cb4a0ff5900b7355da3a5a95c44461aecd8 Mon Sep 17 00:00:00 2001 From: sunyuchao Date: Fri, 29 Jul 2022 15:00:07 +0800 Subject: [PATCH 124/155] =?UTF-8?q?=E6=95=B0=E5=AD=97=E5=B9=B3=E5=8F=B0?= =?UTF-8?q?=E5=88=9D=E5=A7=8B=E5=8C=96=E6=96=B0=E5=A2=9E=E9=BB=98=E8=AE=A4?= =?UTF-8?q?=E8=A7=92=E8=89=B2=E4=BF=A1=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/epmet/feign/GovAccessFeignClient.java | 4 ++++ .../fallback/GovAccessFeignClientFallBack.java | 5 +++++ .../com/epmet/controller/GovRoleController.java | 10 ++++++++++ .../java/com/epmet/service/GovRoleService.java | 2 ++ .../epmet/service/impl/GovRoleServiceImpl.java | 17 +++++++++++++++++ .../oper-customize-server/pom.xml | 6 ++++++ .../epmet/service/impl/IcFormServiceImpl.java | 9 +++++++++ 7 files changed, 53 insertions(+) diff --git a/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/GovAccessFeignClient.java b/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/GovAccessFeignClient.java index aa56275f68..074b6f0504 100644 --- a/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/GovAccessFeignClient.java +++ b/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/GovAccessFeignClient.java @@ -9,6 +9,7 @@ import com.epmet.dto.form.*; import com.epmet.dto.result.NewUserRoleResultDTO; import com.epmet.feign.fallback.GovAccessFeignClientFallBackFactory; import org.springframework.cloud.openfeign.FeignClient; +import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestBody; @@ -64,4 +65,7 @@ public interface GovAccessFeignClient { @PostMapping("/gov/access/govrole/getgovrole") Result getGovRole(@RequestBody GovRoleListDTO formDTO); + @PostMapping("/gov/access/govrole/initgovrole/{customerId}") + Result initGovRole(@PathVariable(value = "customerId") String customerId); + } diff --git a/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/fallback/GovAccessFeignClientFallBack.java b/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/fallback/GovAccessFeignClientFallBack.java index 2a2d88498d..74ea29dbfe 100644 --- a/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/fallback/GovAccessFeignClientFallBack.java +++ b/epmet-module/gov-access/gov-access-client/src/main/java/com/epmet/feign/fallback/GovAccessFeignClientFallBack.java @@ -50,4 +50,9 @@ public class GovAccessFeignClientFallBack implements GovAccessFeignClient { public Result getGovRole(GovRoleListDTO formDTO) { return ModuleUtils.feignConError(ServiceConstant.GOV_ACCESS_SERVER, "getGovRole", formDTO); } + + @Override + public Result initGovRole(String customerId) { + return ModuleUtils.feignConError(ServiceConstant.GOV_ACCESS_SERVER, "initGovRole", customerId); + } } diff --git a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/controller/GovRoleController.java b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/controller/GovRoleController.java index 0159a8d891..d56c78229c 100644 --- a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/controller/GovRoleController.java +++ b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/controller/GovRoleController.java @@ -108,4 +108,14 @@ public class GovRoleController { return new Result().ok(govRoleService.getGovRole(fromDTO)); } + /** + * 数字平台客户初始化化设置默认角色数据 + * @Author sun + */ + @PostMapping("initgovrole/{customerId}") + public Result initGovRole(@PathVariable(value = "customerId") String customerId){ + govRoleService.initGovRole(customerId); + return new Result(); + } + } diff --git a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/GovRoleService.java b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/GovRoleService.java index b7ca62a420..60b22b27b1 100644 --- a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/GovRoleService.java +++ b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/GovRoleService.java @@ -95,4 +95,6 @@ public interface GovRoleService extends BaseService { void delete(String[] ids); GovRoleDTO getGovRole(GovRoleListDTO fromDTO); + + void initGovRole(String customerId); } \ No newline at end of file diff --git a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovRoleServiceImpl.java b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovRoleServiceImpl.java index be20a94427..a72f8dd1f2 100644 --- a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovRoleServiceImpl.java +++ b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovRoleServiceImpl.java @@ -41,6 +41,7 @@ import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; +import java.util.ArrayList; import java.util.Arrays; import java.util.List; import java.util.Map; @@ -135,4 +136,20 @@ public class GovRoleServiceImpl extends BaseServiceImpl list = new ArrayList<>(); + GovRoleEntity entity = new GovRoleEntity(); + entity.setCustomerId(customerId); + entity.setName("联建单位负责人"); + entity.setRemark("默认角色"); + entity.setDefaultRole("1"); + list.add(entity); + GovRoleEntity entity1 = entity; + entity1.setName("社区自组织负责人"); + list.add(entity1); + insertBatch(list); + } + } \ No newline at end of file diff --git a/epmet-module/oper-customize/oper-customize-server/pom.xml b/epmet-module/oper-customize/oper-customize-server/pom.xml index 55fd617ca9..b6694d1abb 100644 --- a/epmet-module/oper-customize/oper-customize-server/pom.xml +++ b/epmet-module/oper-customize/oper-customize-server/pom.xml @@ -95,6 +95,12 @@ 2.0.0 compile + + com.epmet + gov-access-client + 2.0.0 + compile + diff --git a/epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/service/impl/IcFormServiceImpl.java b/epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/service/impl/IcFormServiceImpl.java index 0583188d71..bb75b51fc4 100644 --- a/epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/service/impl/IcFormServiceImpl.java +++ b/epmet-module/oper-customize/oper-customize-server/src/main/java/com/epmet/service/impl/IcFormServiceImpl.java @@ -37,6 +37,7 @@ import com.epmet.dto.result.FormGroupDTO; import com.epmet.dto.result.FormItemResult; import com.epmet.entity.*; import com.epmet.feign.EpmetHeartOpenFeignClient; +import com.epmet.feign.GovAccessFeignClient; import com.epmet.feign.GovOrgOpenFeignClient; import com.epmet.redis.CustomerFootBarRedis; import com.epmet.service.IcFormService; @@ -83,6 +84,8 @@ public class IcFormServiceImpl extends BaseServiceImpl private EpmetHeartOpenFeignClient epmetHeartOpenFeignClient; @Resource private GovOrgOpenFeignClient govOrgOpenFeignClient; + @Resource + private GovAccessFeignClient govAccessFeignClient; /** * 获取居民信息表单 @@ -329,6 +332,12 @@ public class IcFormServiceImpl extends BaseServiceImpl throw new EpmetException(dictResult.getCode(), dictResult.getMsg()); } + //7-29 初始化为客户设置(联建单位负责人、社区自组织负责人)两个默认角色数据 + Result accessResult = govAccessFeignClient.initGovRole(customerId); + if (!accessResult.success()) { + throw new EpmetException(accessResult.getCode(), accessResult.getMsg()); + } + return "初始化成功!客户ID:" + customerId + " formCode:" + formCode; } } From 4b0e70d7375d0b10257aceb9680f99d4f12db689 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Fri, 29 Jul 2022 15:18:44 +0800 Subject: [PATCH 125/155] url --- .../com/epmet/service/impl/IcUserDemandRecServiceImpl.java | 2 +- .../java/com/epmet/feign/EpmetMessageOpenFeignClient.java | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java index ca7b3c3f58..951b7b2e79 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcUserDemandRecServiceImpl.java @@ -444,7 +444,7 @@ public class IcUserDemandRecServiceImpl extends BaseServiceImpl Date: Fri, 29 Jul 2022 15:23:35 +0800 Subject: [PATCH 126/155] message --- epmet-gateway/pom.xml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/epmet-gateway/pom.xml b/epmet-gateway/pom.xml index 6b7db20347..9f82bf017f 100644 --- a/epmet-gateway/pom.xml +++ b/epmet-gateway/pom.xml @@ -278,6 +278,7 @@ lb://epmet-message-server + lb://epmet-activiti-server @@ -357,7 +358,7 @@ lb://epmet-heart-server - + lb://epmet-point-server @@ -366,8 +367,8 @@ http://127.0.0.1:8113 - lb://data-aggregator-server - + + http://127.0.0.1:8114 lb://open-data-worker-server From d904d1e9712df9d39fe0f9865ccad9a4f24b5935 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Fri, 29 Jul 2022 15:24:44 +0800 Subject: [PATCH 127/155] dataagg --- epmet-gateway/pom.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/epmet-gateway/pom.xml b/epmet-gateway/pom.xml index 9f82bf017f..301fb79a81 100644 --- a/epmet-gateway/pom.xml +++ b/epmet-gateway/pom.xml @@ -367,8 +367,8 @@ http://127.0.0.1:8113 - - http://127.0.0.1:8114 + lb://data-aggregator-server + lb://open-data-worker-server From 41338ef04996eaabcc948a974b6ad3666ce1463d Mon Sep 17 00:00:00 2001 From: sunyuchao Date: Fri, 29 Jul 2022 16:13:48 +0800 Subject: [PATCH 128/155] =?UTF-8?q?=E8=84=9A=E6=9C=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../db/migration/V0.0.27__alter_party_communit.sql | 11 +++++++++++ .../resources/db/migration/V0.0.8__alter_gov_role.sql | 4 ++++ .../resources/db/migration/V0.0.39__alter_dept.sql | 5 +++++ 3 files changed, 20 insertions(+) create mode 100644 epmet-module/epmet-heart/epmet-heart-server/src/main/resources/db/migration/V0.0.27__alter_party_communit.sql create mode 100644 epmet-module/gov-access/gov-access-server/src/main/resources/db/migration/V0.0.8__alter_gov_role.sql create mode 100644 epmet-module/gov-org/gov-org-server/src/main/resources/db/migration/V0.0.39__alter_dept.sql diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/resources/db/migration/V0.0.27__alter_party_communit.sql b/epmet-module/epmet-heart/epmet-heart-server/src/main/resources/db/migration/V0.0.27__alter_party_communit.sql new file mode 100644 index 0000000000..e7aca4b8aa --- /dev/null +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/resources/db/migration/V0.0.27__alter_party_communit.sql @@ -0,0 +1,11 @@ + +ALTER TABLE `ic_community_self_organization` +ADD COLUMN `SYNC_TYPE` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT 'not_sync' COMMENT '同步状态【已同步:sync 未同步:not_sync】' AFTER `ADDRESS`, +ADD COLUMN `DEPT_ID` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '部门ID customer_department.id' AFTER `SYNC_TYPE`, +ADD COLUMN `DEPT_STAFF_ID` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '部门下工作人员Id' AFTER `DEPT_ID`; + +ALTER TABLE `ic_party_unit` +ADD COLUMN `SYNC_TYPE` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT 'not_sync' COMMENT '同步状态【已同步:sync 未同步:not_sync】' AFTER `REMARK`, +ADD COLUMN `DEPT_ID` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '部门ID customer_department.id' AFTER `SYNC_TYPE`, +ADD COLUMN `DEPT_STAFF_ID` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '部门下工作人员Id' AFTER `DEPT_ID`; + diff --git a/epmet-module/gov-access/gov-access-server/src/main/resources/db/migration/V0.0.8__alter_gov_role.sql b/epmet-module/gov-access/gov-access-server/src/main/resources/db/migration/V0.0.8__alter_gov_role.sql new file mode 100644 index 0000000000..3372836974 --- /dev/null +++ b/epmet-module/gov-access/gov-access-server/src/main/resources/db/migration/V0.0.8__alter_gov_role.sql @@ -0,0 +1,4 @@ + + +ALTER TABLE `gov_role` +ADD COLUMN `default_role` char(1) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT '0' COMMENT '是否默认角色【0:否 1:是】' AFTER `remark`; diff --git a/epmet-module/gov-org/gov-org-server/src/main/resources/db/migration/V0.0.39__alter_dept.sql b/epmet-module/gov-org/gov-org-server/src/main/resources/db/migration/V0.0.39__alter_dept.sql new file mode 100644 index 0000000000..9dc87f0bd2 --- /dev/null +++ b/epmet-module/gov-org/gov-org-server/src/main/resources/db/migration/V0.0.39__alter_dept.sql @@ -0,0 +1,5 @@ + +ALTER TABLE `customer_department` +ADD COLUMN `DEPT_TYPE` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT 'duty' COMMENT '部门类型【职能部门: duty \r\n联建单位: party_unit \r\n社会自组织: community_org】' AFTER `MOBILE`; + + From edd5538d55e5f15244fc649f576fae0cd78aa670 Mon Sep 17 00:00:00 2001 From: zxc <1272811460@qq.com> Date: Fri, 29 Jul 2022 17:10:53 +0800 Subject: [PATCH 129/155] =?UTF-8?q?=E7=A4=BE=E5=8C=BA=E8=87=AA=E7=BB=84?= =?UTF-8?q?=E7=BB=87category?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../resources/mapper/heart/IcCommunitySelfOrganizationDao.xml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/heart/IcCommunitySelfOrganizationDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/heart/IcCommunitySelfOrganizationDao.xml index b374071590..57b7dc3449 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/heart/IcCommunitySelfOrganizationDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/heart/IcCommunitySelfOrganizationDao.xml @@ -13,7 +13,8 @@ ifnull(PRINCIPAL_PHONE,'') AS mobile, ifnull(ADDRESS,'') as address, ifnull(LONGITUDE,'') as longitude, - ifnull(LATITUDE,'') as latitude + ifnull(LATITUDE,'') as latitude, + IFNULL(CATEGORY_CODE,'') as category FROM ic_community_self_organization WHERE DEL_FLAG = 0 AND CUSTOMER_ID = #{customerId} From 6135774ea255370161aa93e78e29c19b766c35f5 Mon Sep 17 00:00:00 2001 From: sunyuchao Date: Fri, 29 Jul 2022 17:34:51 +0800 Subject: [PATCH 130/155] =?UTF-8?q?=E7=A8=8B=E5=BA=8F=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/epmet/service/impl/DepartmentServiceImpl.java | 4 ++++ .../com/epmet/service/impl/CustomerStaffServiceImpl.java | 8 ++++++++ 2 files changed, 12 insertions(+) diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java index 0793688b22..dbc9be392b 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java @@ -408,6 +408,8 @@ public class DepartmentServiceImpl implements DepartmentService { deptDTO.setDepartmentName(formDTO.getDeptName()); deptDTO.setDeptType(formDTO.getDeptType()); deptDTO.setTotalUser(1); + deptDTO.setContacts(formDTO.getPersonName()); + deptDTO.setMobile(formDTO.getMobile()); Result deptResult = addDepartment(deptDTO); //三、新增组织人员关系数据 //人员机关关系表 @@ -470,6 +472,8 @@ public class DepartmentServiceImpl implements DepartmentService { deptDTO.setDepartmentName(formDTO.getDeptName()); deptDTO.setDeptType(formDTO.getDeptType()); deptDTO.setTotalUser(1); + deptDTO.setContacts(formDTO.getPersonName()); + deptDTO.setMobile(formDTO.getMobile()); Result deptResult = addDepartment(deptDTO); //三、部门下新增人员关系数据 CustomerStaffDepartmentEntity dept = new CustomerStaffDepartmentEntity(); diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java index 8fcc9b5338..3a10aa1b26 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java @@ -894,9 +894,17 @@ public class CustomerStaffServiceImpl extends BaseServiceImpl newRoles = new ArrayList<>(); newRoles.add(resultRole.getData().getId()); + fromDTO.setNewRoles(newRoles); //3.新增工作人员 Result result = addStaff(fromDTO); + + //4.新增数字平台角色信息 + Result roleUserAccess = govAccessFeignClient.roleUser(new RoleUserFormDTO(fromDTO.getNewRoles(), fromDTO.getStaffId(), fromDTO.getCustomerId())); + if (!roleUserAccess.success()) { + throw new RenException("工作人员新增数字平台角色信息失败" + resultRole.getMsg()); + } + return result; } From 3cd902ca44d72dea5fc2b71a4d400b978ac8a772 Mon Sep 17 00:00:00 2001 From: wangxianzhang Date: Fri, 29 Jul 2022 17:45:20 +0800 Subject: [PATCH 131/155] =?UTF-8?q?=E3=80=90=E5=9B=BE=E5=B1=82=E3=80=91?= =?UTF-8?q?=E8=B0=83=E6=95=B4=EF=BC=9A=E5=B7=A6=E4=BE=A7=E8=8F=9C=E5=8D=95?= =?UTF-8?q?"=E5=9F=8E=E5=B8=82=E7=AE=A1=E7=90=86=E4=BA=8B=E4=BB=B6"?= =?UTF-8?q?=E5=90=8D=E7=A7=B0=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/epmet/commons/tools/enums/CoveragePlaceTypeEnum.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoveragePlaceTypeEnum.java b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoveragePlaceTypeEnum.java index 6078970cb2..6f71e122b0 100644 --- a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoveragePlaceTypeEnum.java +++ b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/CoveragePlaceTypeEnum.java @@ -17,7 +17,7 @@ public enum CoveragePlaceTypeEnum { PARTY_UNIT("party_unit", "联建单位"), VOLUNTEER("volunteer", "志愿者"), GROUP_RENT("group_rent", "群租房"), - EVENT("event", "事件(包括难点堵点)"), + EVENT("event", "城市管理事件"), ZHZL_RQ("zhzl_rq", "综合治理人群"); private final String code; From 6605605033ebd3ac68a5a7eab8293fb8894fad52 Mon Sep 17 00:00:00 2001 From: wangxianzhang Date: Fri, 29 Jul 2022 23:14:33 +0800 Subject: [PATCH 132/155] =?UTF-8?q?=E3=80=90=E5=9B=BE=E5=B1=82=E3=80=91?= =?UTF-8?q?=E6=89=BE=E5=9B=9E=E5=90=88=E4=B8=A2=E7=9A=84=E5=BF=97=E6=84=BF?= =?UTF-8?q?=E8=80=85=E6=95=B0=E9=87=8F=E5=92=8C=E6=90=9C=E7=B4=A2=E7=9A=84?= =?UTF-8?q?=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/CoverageServiceImpl.java | 23 +++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index b29ffcb853..2a2cdb1474 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -39,6 +39,7 @@ import com.epmet.dataaggre.entity.opercustomize.IcResiCategoryWarnConfigEntity; import com.epmet.dataaggre.enums.MenusEnums; import com.epmet.dataaggre.redis.GovCustomerMenuRedis; import com.epmet.dataaggre.service.CoverageService; +import com.epmet.dataaggre.service.epmetuser.EpmetUserService; import com.epmet.dataaggre.service.epmetuser.IcResiService; import com.epmet.dataaggre.service.govorg.GovOrgCoverageService; import com.epmet.dataaggre.service.govorg.GovOrgService; @@ -93,6 +94,9 @@ public class CoverageServiceImpl implements CoverageService { @Autowired private ExecutorService executorService; + @Autowired + private EpmetUserService epmetUserService; + // 1:出租 0:自住 2:闲置 3:未售出 public static final Integer HOUSE_RENT_FLAG_RENT = 1; @@ -609,6 +613,10 @@ public class CoverageServiceImpl implements CoverageService { // 最新巡查结果【0:合格 1:不合格】 // 左侧用,可以到网格, return orgCoverageService.countEnterprisePatrol(customerId, agencyId, staffOrgIds, search, categoryKey,NumConstant.ONE_STR,gridId); + } else if (CoveragePlaceTypeEnum.VOLUNTEER.getCode().equals(placeType)) { + // 志愿者 + String[] parts = categoryKey.split("_"); + return epmetUserService.countVolunteers(customerId, agencyId, staffOrgIds, search, parts[1]); } return 0; @@ -771,6 +779,21 @@ public class CoverageServiceImpl implements CoverageService { StringUtils.isNotBlank(dc.getLatitude()) ? dc.getLatitude() : rootAgency.getLatitude(), StringUtils.isNotBlank(dc.getLongitude()) ? dc.getLongitude() : rootAgency.getLongitude())) .collect(Collectors.toList()); + } else if (CoveragePlaceTypeEnum.VOLUNTEER.getCode().equals(placeType)) { + // 志愿者 + String[] parts = categoryKey.split("_"); + List resiEntities = epmetUserService.listVolunteers(customerId, agencyId, staffOrgIds, search, parts[1]); + + return resiEntities.parallelStream().map(re -> { + // 使用楼栋的坐标补充居民的坐标信息 + String[] coordinates = getUserCoordinates(re.getId(), re.getBuildId(), rootAgency); + + return new CoverageAnalisisDataListResultDTO( + re.getId(), categoryKey, isPage ? categoryDict.getCategoryName() : null, placeType, + re.getName().concat(StrConstant.BRACKET_LEFT).concat(re.getIdCard()).concat(StrConstant.BRACKET_RIGNT), + coordinates[1], coordinates[0]); + + }).collect(Collectors.toList()); } return new ArrayList<>(); } From 22ecd92922e9dba8d9ea1c3a060ec92d1c31d523 Mon Sep 17 00:00:00 2001 From: syc Date: Mon, 1 Aug 2022 11:19:04 +0800 Subject: [PATCH 133/155] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E6=96=87=E6=A1=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/com/epmet/service/impl/DepartmentServiceImpl.java | 1 + 1 file changed, 1 insertion(+) diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java index dbc9be392b..f55fcaf70e 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java @@ -370,6 +370,7 @@ public class DepartmentServiceImpl implements DepartmentService { //姓名不一样的给反馈 if (!formDTO.getPersonName().equals(userResult.getData().getRealName())) { resultDTO.setPersonName(userResult.getData().getRealName()); + resultDTO.setMsg("联系电话已存在工作账号,姓名已更新"); } resultDTO.setType(true); From 883d88a847dd2daa8c65a5f1fed7a68e64f09f6d Mon Sep 17 00:00:00 2001 From: zxc <1272811460@qq.com> Date: Mon, 1 Aug 2022 14:50:07 +0800 Subject: [PATCH 134/155] =?UTF-8?q?=E5=9F=8E=E5=B8=82=E7=AE=A1=E7=90=86=20?= =?UTF-8?q?=E5=92=8C=20=E5=85=AC=E5=85=B1=E6=9C=8D=E5=8A=A1=E5=AF=BC?= =?UTF-8?q?=E5=85=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/resources/mapper/IcCityManagementDao.xml | 4 ++++ .../src/main/resources/mapper/IcPublicServiceDao.xml | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcCityManagementDao.xml b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcCityManagementDao.xml index 051d742db4..2b83594d09 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcCityManagementDao.xml +++ b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcCityManagementDao.xml @@ -17,6 +17,8 @@ address, longitude, latitude, + principal, + mobile, del_flag, revision, created_by, @@ -39,6 +41,8 @@ #{i.address}, #{i.longitude}, #{i.latitude}, + #{i.principal}, + #{i.mobile}, 0, 0, #{i.createdBy}, diff --git a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcPublicServiceDao.xml b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcPublicServiceDao.xml index 3894594840..513a824d42 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcPublicServiceDao.xml +++ b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcPublicServiceDao.xml @@ -17,6 +17,8 @@ address, longitude, latitude, + principal, + mobile, del_flag, revision, created_by, @@ -39,6 +41,8 @@ #{i.address}, #{i.longitude}, #{i.latitude}, + #{i.principal}, + #{i.mobile}, 0, 0, #{i.createdBy}, From 2085de5c7d2668f0058a80191b40c64d65b7bbf9 Mon Sep 17 00:00:00 2001 From: zxc <1272811460@qq.com> Date: Mon, 1 Aug 2022 15:10:29 +0800 Subject: [PATCH 135/155] =?UTF-8?q?=E5=9F=8E=E5=B8=82=E7=AE=A1=E7=90=86=20?= =?UTF-8?q?=E5=92=8C=20=E5=85=AC=E5=85=B1=E6=9C=8D=E5=8A=A1=E5=AF=BC?= =?UTF-8?q?=E5=85=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/resources/mapper/IcCityManagementDao.xml | 2 ++ .../src/main/resources/mapper/IcPublicServiceDao.xml | 2 ++ 2 files changed, 4 insertions(+) diff --git a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcCityManagementDao.xml b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcCityManagementDao.xml index 2b83594d09..73a921331c 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcCityManagementDao.xml +++ b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcCityManagementDao.xml @@ -61,6 +61,8 @@ address = values(address), longitude = null, latitude = null, + principal = values(principal), + mobile = values(mobile), updated_by = values(updated_by), updated_time = NOW() diff --git a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcPublicServiceDao.xml b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcPublicServiceDao.xml index 513a824d42..ef81d4c77a 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcPublicServiceDao.xml +++ b/epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcPublicServiceDao.xml @@ -61,6 +61,8 @@ address = values(address), longitude = null, latitude = null, + principal = values(principal), + mobile = values(mobile), updated_by = values(updated_by), updated_time = NOW() From 98e1d76bc14e65c63a10ea808a6987200633f81e Mon Sep 17 00:00:00 2001 From: syc Date: Mon, 1 Aug 2022 16:00:14 +0800 Subject: [PATCH 136/155] =?UTF-8?q?=E8=A7=92=E8=89=B2=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/epmet/service/impl/CustomerStaffServiceImpl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java index 3a10aa1b26..ec1ac046fc 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java @@ -900,7 +900,7 @@ public class CustomerStaffServiceImpl extends BaseServiceImpl result = addStaff(fromDTO); //4.新增数字平台角色信息 - Result roleUserAccess = govAccessFeignClient.roleUser(new RoleUserFormDTO(fromDTO.getNewRoles(), fromDTO.getStaffId(), fromDTO.getCustomerId())); + Result roleUserAccess = govAccessFeignClient.roleUser(new RoleUserFormDTO(fromDTO.getNewRoles(), result.getData().getUserId(), fromDTO.getCustomerId())); if (!roleUserAccess.success()) { throw new RenException("工作人员新增数字平台角色信息失败" + resultRole.getMsg()); } From 6ff3803a003cb85fc8c57d96ac00df626be082a8 Mon Sep 17 00:00:00 2001 From: syc Date: Mon, 1 Aug 2022 16:20:10 +0800 Subject: [PATCH 137/155] =?UTF-8?q?=E9=BB=98=E8=AE=A4=E6=80=A7=E5=88=AB?= =?UTF-8?q?=E4=B8=BA=E7=94=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/com/epmet/service/impl/DepartmentServiceImpl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java index f55fcaf70e..e5cd12fdf8 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/DepartmentServiceImpl.java @@ -396,7 +396,7 @@ public class DepartmentServiceImpl implements DepartmentService { StaffSubmitFromDTO submitDTO = ConvertUtils.sourceToTarget(formDTO, StaffSubmitFromDTO.class); submitDTO.setName(formDTO.getPersonName()); submitDTO.setAgencyId(staffInfo.getAgencyId()); - submitDTO.setGender(0); + submitDTO.setGender(1); submitDTO.setWorkType("fulltime"); Result staffResult = epmetUserOpenFeignClient.deptToAddStaff(submitDTO); if (!staffResult.success()) { From 96ae97f70e4926fd9fdddb417b72b7a63577281a Mon Sep 17 00:00:00 2001 From: syc Date: Mon, 1 Aug 2022 17:30:16 +0800 Subject: [PATCH 138/155] =?UTF-8?q?=E8=81=94=E5=BB=BA=E5=8D=95=E4=BD=8D?= =?UTF-8?q?=E5=88=97=E8=A1=A8=E6=94=B9=E4=B8=BA=E6=8C=89=E5=88=9B=E5=BB=BA?= =?UTF-8?q?=E6=97=B6=E9=97=B4=E5=80=92=E5=BA=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/epmet/service/impl/IcPartyUnitServiceImpl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcPartyUnitServiceImpl.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcPartyUnitServiceImpl.java index 7c6ca5c81c..304705ac2d 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcPartyUnitServiceImpl.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcPartyUnitServiceImpl.java @@ -126,7 +126,7 @@ public class IcPartyUnitServiceImpl extends BaseServiceImpl list = baseDao.selectList(wrapper); PageInfo pageInfo = new PageInfo<>(list); List dtoList = ConvertUtils.sourceToTarget(list, IcPartyUnitDTO.class); From e816f0fcb38be8d54ca37edf5897e1d3edb0634c Mon Sep 17 00:00:00 2001 From: wangxianzhang Date: Mon, 1 Aug 2022 17:39:26 +0800 Subject: [PATCH 139/155] =?UTF-8?q?=E3=80=90=E4=BA=94=E5=A4=A7=E5=9B=BE?= =?UTF-8?q?=E5=B1=82=E3=80=91=E5=B1=85=E6=B0=91=E4=BF=A1=E6=81=AF=E6=8E=A5?= =?UTF-8?q?=E5=8F=A3=E6=96=B0=E5=A2=9E"=E5=B1=85=E6=B0=91=E7=B1=BB?= =?UTF-8?q?=E5=88=AB"=E5=88=97=E8=BF=94=E5=9B=9E=EF=BC=8C=E6=98=AF?= =?UTF-8?q?=E4=B8=AA=E5=AD=97=E5=85=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../commons/tools/enums/ResiCategoryEnum.java | 14 ++++++++++++++ .../com/epmet/dto/result/IcResiUserBriefDTO.java | 5 +++++ .../service/impl/IcResiUserServiceImpl.java | 16 ++++++++++++++++ 3 files changed, 35 insertions(+) diff --git a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/ResiCategoryEnum.java b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/ResiCategoryEnum.java index b7ab6cbddc..6416582380 100644 --- a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/ResiCategoryEnum.java +++ b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/enums/ResiCategoryEnum.java @@ -28,6 +28,20 @@ public enum ResiCategoryEnum { this.label = label; } + /** + * 取枚举对象 + * @param columnName + * @return + */ + public static ResiCategoryEnum getEnum(String columnName) { + for (ResiCategoryEnum enumObject : ResiCategoryEnum.values()) { + if (enumObject.getColName().equals(columnName)) { + return enumObject; + } + } + return null; + } + public String getColName() { return colName; } diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/result/IcResiUserBriefDTO.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/result/IcResiUserBriefDTO.java index c9a0160aed..12121a4245 100644 --- a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/result/IcResiUserBriefDTO.java +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/result/IcResiUserBriefDTO.java @@ -71,6 +71,11 @@ public class IcResiUserBriefDTO extends HouseUserDTO implements Serializable { */ private Map volunteerCategories = new HashMap<>(); + /** + * 居民类别 + */ + private Map resiCategories = new HashMap<>(); + /** * 同屋的其他人 */ diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java index 07aeab3f53..cf76bb0f2b 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java @@ -1508,6 +1508,22 @@ public class IcResiUserServiceImpl extends BaseServiceImpl resiCategoryColumns = Arrays.stream(ResiCategoryEnum.values()).map(c -> c.getColName()).collect(Collectors.toList()); + + Map resiCategories = new HashMap<>(); + + Map categories = icResiUserDao.getCategoryListMap(resiCategoryColumns, resiUserId); + categories.forEach((k, v) -> { + if (NumConstant.ONE_STR.equals(v)) { + ResiCategoryEnum enumObject = ResiCategoryEnum.getEnum(k); + resiCategories.put(k, enumObject.getLabel()); + } + }); + + + r.setResiCategories(resiCategories); + return r; } From 5e7c7a27f1acb8d6ab59a2e01863bce7c9ea4f7d Mon Sep 17 00:00:00 2001 From: jianjun Date: Tue, 2 Aug 2022 09:01:30 +0800 Subject: [PATCH 140/155] =?UTF-8?q?=E5=88=86=E9=A1=B5=E5=8F=82=E6=95=B0=20?= =?UTF-8?q?=E4=BD=8D=E7=BD=AE=E4=B8=8B=E7=A7=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/GridstaffWorkInfoPingyinServiceImpl.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffWorkInfoPingyinServiceImpl.java b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffWorkInfoPingyinServiceImpl.java index 2e3e600e04..a4e98d714f 100755 --- a/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffWorkInfoPingyinServiceImpl.java +++ b/epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/GridstaffWorkInfoPingyinServiceImpl.java @@ -60,7 +60,6 @@ public class GridstaffWorkInfoPingyinServiceImpl extends BaseServiceImpl data; do { Result> record = epmetUserOpenFeignClient.getPatrolRoutineWorkListV2(midPatrolFormDTO); - midPatrolFormDTO.setPageNo(midPatrolFormDTO.getPageNo() + 1); if (record == null || !record.success()) { log.error("获取例行工作记录V2失败,param:{}", JSON.toJSONString(midPatrolFormDTO)); throw new EpmetException(EpmetErrorCode.SERVER_ERROR.getCode()); @@ -86,7 +85,7 @@ public class GridstaffWorkInfoPingyinServiceImpl extends BaseServiceImpl Date: Tue, 2 Aug 2022 09:07:31 +0800 Subject: [PATCH 141/155] =?UTF-8?q?=E6=90=9C=E7=B4=A2=E5=BE=AE=E8=B0=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dataaggre/service/impl/CoverageServiceImpl.java | 10 ++++++++++ .../main/resources/mapper/epmetuser/IcResiUserDao.xml | 1 + 2 files changed, 11 insertions(+) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java index 2a2cdb1474..7639f6c561 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/CoverageServiceImpl.java @@ -486,6 +486,16 @@ public class CoverageServiceImpl implements CoverageService { result.setTotal(Long.valueOf(String.valueOf(allIcUser.size()))); result.setList(allIcUser); } + if (CollectionUtils.isNotEmpty(result.getList())){ + result.getList().forEach(r -> { + HouseInfoCache houseInfo = CustomerIcHouseRedis.getHouseInfo(formDTO.getCustomerId(), r.getHomeId()); + if (null == houseInfo){ + throw new EpmetException("获取房屋信息失败:"+r.getHomeId()); + } + r.setLongitude(houseInfo.getBuildingLongitude()); + r.setLatitude(houseInfo.getBuildingLatitude()); + }); + } return result; } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml index 92c000175c..9097a47098 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml @@ -167,6 +167,7 @@ ifnull(u.RHZK,'') as rhzk FROM ic_resi_user u WHERE u.DEL_FLAG = '0' + and u.status ='0' AND u.CUSTOMER_ID = #{customerId} From e196e82e5ddeb53a452ea878757e2d9a81200338 Mon Sep 17 00:00:00 2001 From: zhaoqifeng Date: Tue, 2 Aug 2022 09:19:32 +0800 Subject: [PATCH 142/155] =?UTF-8?q?=E6=A3=80=E7=B4=A2=E6=9D=A1=E4=BB=B6?= =?UTF-8?q?=E7=B2=BE=E7=A1=AE=E5=88=B0=E6=97=B6=E5=88=86=E7=A7=92?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../mapper/govproject/ProjectDao.xml | 24 +++++++++---------- 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govproject/ProjectDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govproject/ProjectDao.xml index 5771dfad79..1b159cb69d 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govproject/ProjectDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/govproject/ProjectDao.xml @@ -429,10 +429,10 @@ DEL_FLAG = '0' AND AGENCY_ID = #{agencyId} - AND DATE_FORMAT(CREATED_TIME,"%Y%m%d") = ]]> #{startDate} + AND DATE_FORMAT(CREATED_TIME,"%Y%m%d%H%i%s") = ]]> #{startDate} - AND DATE_FORMAT(CREATED_TIME,"%Y%m%d") #{endDate} + AND DATE_FORMAT(CREATED_TIME,"%Y%m%d%H%i%s") #{endDate} GROUP BY GRID_ID @@ -450,10 +450,10 @@ AND GRID_ID IS NOT NULL AND GRID_ID != '' - AND DATE_FORMAT(CREATED_TIME,"%Y%m%d") = ]]> #{startDate} + AND DATE_FORMAT(CREATED_TIME,"%Y%m%d%H%i%s") = ]]> #{startDate} - AND DATE_FORMAT(CREATED_TIME,"%Y%m%d") #{endDate} + AND DATE_FORMAT(CREATED_TIME,"%Y%m%d%H%i%s") #{endDate} GROUP BY GRID_ID @@ -471,10 +471,10 @@ AND GRID_ID = #{orgId} - AND DATE_FORMAT(CREATED_TIME,"%Y%m%d") = ]]> #{startDate} + AND DATE_FORMAT(CREATED_TIME,"%Y%m%d%H%i%s") = ]]> #{startDate} - AND DATE_FORMAT(CREATED_TIME,"%Y%m%d") #{endDate} + AND DATE_FORMAT(CREATED_TIME,"%Y%m%d%H%i%s") #{endDate} GROUP BY CREATED_BY @@ -493,10 +493,10 @@ AND GRID_ID = #{orgId} - AND DATE_FORMAT(CREATED_TIME,"%Y%m%d") = ]]> #{startDate} + AND DATE_FORMAT(CREATED_TIME,"%Y%m%d%H%i%s") = ]]> #{startDate} - AND DATE_FORMAT(CREATED_TIME,"%Y%m%d") #{endDate} + AND DATE_FORMAT(CREATED_TIME,"%Y%m%d%H%i%s") #{endDate} GROUP BY STAFF_ID @@ -511,10 +511,10 @@ DEL_FLAG = '0' AND (AGENCY_ID = #{agencyId} OR ORG_ID_PATH LIKE CONCAT('%', #{agencyId}, '%')) - AND DATE_FORMAT(CREATED_TIME,"%Y%m%d") = ]]> #{startDate} + AND DATE_FORMAT(CREATED_TIME,"%Y%m%d%H%i%s") = ]]> #{startDate} - AND DATE_FORMAT(CREATED_TIME,"%Y%m%d") #{endDate} + AND DATE_FORMAT(CREATED_TIME,"%Y%m%d%H%i%s") #{endDate} GROUP BY AGENCY_ID @@ -530,10 +530,10 @@ AND (AGENCY_ID = #{agencyId} OR ORG_ID_PATH LIKE CONCAT('%', #{agencyId}, '%')) AND OPERATION = 'close' - AND DATE_FORMAT(CREATED_TIME,"%Y%m%d") = ]]> #{startDate} + AND DATE_FORMAT(CREATED_TIME,"%Y%m%d%H%i%s") = ]]> #{startDate} - AND DATE_FORMAT(CREATED_TIME,"%Y%m%d") #{endDate} + AND DATE_FORMAT(CREATED_TIME,"%Y%m%d%H%i%s") #{endDate} GROUP BY AGENCY_ID From e1745f5f46c31cee76168e285de820cfc916beda Mon Sep 17 00:00:00 2001 From: wangxianzhang Date: Tue, 2 Aug 2022 09:40:41 +0800 Subject: [PATCH 143/155] =?UTF-8?q?=E3=80=90=E4=BA=94=E5=A4=A7=E5=9B=BE?= =?UTF-8?q?=E5=B1=82=E3=80=91=E5=B1=85=E6=B0=91=E4=BF=A1=E6=81=AF=E6=8E=A5?= =?UTF-8?q?=E5=8F=A3=E6=96=B0=E5=A2=9E"=E5=B1=85=E6=B0=91=E7=B1=BB?= =?UTF-8?q?=E5=88=AB=E5=90=8D=E7=A7=B0"=E5=88=97=E8=BF=94=E5=9B=9E?= =?UTF-8?q?=EF=BC=8C=E5=AD=97=E7=AC=A6=E4=B8=B2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/epmet/dto/result/IcResiUserBriefDTO.java | 2 +- .../epmet/service/impl/IcResiUserServiceImpl.java | 12 ++++++++---- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/result/IcResiUserBriefDTO.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/result/IcResiUserBriefDTO.java index 12121a4245..87393c2a17 100644 --- a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/result/IcResiUserBriefDTO.java +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/result/IcResiUserBriefDTO.java @@ -74,7 +74,7 @@ public class IcResiUserBriefDTO extends HouseUserDTO implements Serializable { /** * 居民类别 */ - private Map resiCategories = new HashMap<>(); + private String resiCategoryNames; /** * 同屋的其他人 diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java index cf76bb0f2b..b329bee2b8 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java @@ -1466,6 +1466,11 @@ public class IcResiUserServiceImpl extends BaseServiceImpl resiCategoryColumns = Arrays.stream(ResiCategoryEnum.values()).map(c -> c.getColName()).collect(Collectors.toList()); - Map resiCategories = new HashMap<>(); + ArrayList resiCategoryNames = new ArrayList<>(); Map categories = icResiUserDao.getCategoryListMap(resiCategoryColumns, resiUserId); categories.forEach((k, v) -> { if (NumConstant.ONE_STR.equals(v)) { ResiCategoryEnum enumObject = ResiCategoryEnum.getEnum(k); - resiCategories.put(k, enumObject.getLabel()); + resiCategoryNames.add(enumObject.getLabel()); } }); - - r.setResiCategories(resiCategories); + r.setResiCategoryNames(String.join("、", resiCategoryNames)); return r; } From f7ed152f01e0617d5497e6980c1fd08aca927839 Mon Sep 17 00:00:00 2001 From: zxc <1272811460@qq.com> Date: Tue, 2 Aug 2022 11:17:43 +0800 Subject: [PATCH 144/155] =?UTF-8?q?=E5=88=A0=E9=99=A4=E5=85=A8=E9=83=A8?= =?UTF-8?q?=E7=BC=93=E5=AD=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/java/com/epmet/redis/GovCustomerMenuRedis.java | 4 ++-- .../com/epmet/service/impl/GovCustomerMenuServiceImpl.java | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/redis/GovCustomerMenuRedis.java b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/redis/GovCustomerMenuRedis.java index 274ad0fed3..dd72c1f98c 100644 --- a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/redis/GovCustomerMenuRedis.java +++ b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/redis/GovCustomerMenuRedis.java @@ -78,8 +78,8 @@ public class GovCustomerMenuRedis { redisUtils.deleteByPattern(key); } - public void delAllCustomerMenuFiveCoverage(String customerId){ - String key = RedisKeys.getCustomerMenuListFiveCoverage().concat(customerId); + public void delAllCustomerMenuFiveCoverage(){ + String key = RedisKeys.getCustomerMenuListFiveCoverage().concat("*"); redisUtils.delete(key); } diff --git a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovCustomerMenuServiceImpl.java b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovCustomerMenuServiceImpl.java index 0a93c9a4d1..592713fdf5 100644 --- a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovCustomerMenuServiceImpl.java +++ b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovCustomerMenuServiceImpl.java @@ -115,10 +115,10 @@ public class GovCustomerMenuServiceImpl extends BaseServiceImpl Date: Tue, 2 Aug 2022 13:47:08 +0800 Subject: [PATCH 145/155] =?UTF-8?q?=E7=BC=93=E5=AD=98=E5=88=A0=E9=99=A4?= =?UTF-8?q?=E6=94=B9=E7=94=A8deleteByPattern?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/epmet/dataaggre/redis/GovCustomerMenuRedis.java | 2 +- .../src/main/java/com/epmet/redis/GovCustomerMenuRedis.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/redis/GovCustomerMenuRedis.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/redis/GovCustomerMenuRedis.java index fbeca4840e..5038e14a7c 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/redis/GovCustomerMenuRedis.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/redis/GovCustomerMenuRedis.java @@ -96,7 +96,7 @@ public class GovCustomerMenuRedis { */ public void delAllCustomerMenu(String customerId) { String key = RedisKeys.getCustomerMenuListFiveCoverage().concat(customerId); - redisUtils.delete(key); + redisUtils.deleteByPattern(key); } private boolean checkParam(String customerId, Integer type) { diff --git a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/redis/GovCustomerMenuRedis.java b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/redis/GovCustomerMenuRedis.java index dd72c1f98c..3dc0ecd6aa 100644 --- a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/redis/GovCustomerMenuRedis.java +++ b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/redis/GovCustomerMenuRedis.java @@ -80,7 +80,7 @@ public class GovCustomerMenuRedis { public void delAllCustomerMenuFiveCoverage(){ String key = RedisKeys.getCustomerMenuListFiveCoverage().concat("*"); - redisUtils.delete(key); + redisUtils.deleteByPattern(key); } private boolean checkParam(String customerId, Integer type) { From a9db5a17680dbc4269068741aa8aa9996cc8402a Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Tue, 2 Aug 2022 13:48:00 +0800 Subject: [PATCH 146/155] =?UTF-8?q?editStaffInit=E5=B0=91=E7=9A=84?= =?UTF-8?q?=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/CustomerStaffServiceImpl.java | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java index ef8f079c56..77af73c96d 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java @@ -25,6 +25,7 @@ import com.epmet.commons.mybatis.service.impl.BaseServiceImpl; import com.epmet.commons.tools.constant.*; import com.epmet.commons.tools.dto.result.CustomerStaffInfoCacheResult; import com.epmet.commons.tools.exception.EpmetErrorCode; +import com.epmet.commons.tools.exception.EpmetException; import com.epmet.commons.tools.exception.ExceptionUtils; import com.epmet.commons.tools.exception.RenException; import com.epmet.commons.tools.page.PageData; @@ -49,6 +50,7 @@ import com.epmet.entity.GovStaffRoleEntity; import com.epmet.entity.StaffRoleEntity; import com.epmet.entity.UserEntity; import com.epmet.feign.AuthFeignClient; +import com.epmet.feign.GovAccessFeignClient; import com.epmet.feign.GovOrgOpenFeignClient; import com.epmet.feign.OperCrmOpenFeignClient; import com.epmet.service.CustomerStaffService; @@ -94,6 +96,8 @@ public class CustomerStaffServiceImpl extends BaseServiceImpl page(Map params) { @@ -283,7 +287,16 @@ public class CustomerStaffServiceImpl extends BaseServiceImpl> staffExistRole = govAccessFeignClient.getStaffExistRole(getStaffExistRoleFormDTO); + if (!staffExistRole.success()){ + throw new EpmetException("getStaffExistRole method is failure"); + } + if (!CollectionUtils.isEmpty(staffExistRole.getData())){ + List staffRoleResultDTOS = ConvertUtils.sourceToTarget(staffExistRole.getData(), StaffRoleResultDTO.class); + resultDTO.setNewRoleList(staffRoleResultDTOS); + } return new Result().ok(resultDTO); } From c5de446d1d0f8c1668c99d16b582f9d7134e0cc5 Mon Sep 17 00:00:00 2001 From: wangxianzhang Date: Tue, 2 Aug 2022 15:08:52 +0800 Subject: [PATCH 147/155] =?UTF-8?q?=E3=80=90=E4=BA=94=E5=A4=A7=E5=9B=BE?= =?UTF-8?q?=E5=B1=82=E3=80=91=E6=94=AF=E6=8C=81"=E5=85=B6=E4=BB=96"?= =?UTF-8?q?=E7=B1=BB=E5=9E=8B=E5=BF=97=E6=84=BF=E8=80=85=E7=9A=84=E6=9F=A5?= =?UTF-8?q?=E8=AF=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dao/epmetuser/IcResiUserDao.java | 18 ++++++++ .../epmetuser/impl/EpmetUserServiceImpl.java | 14 +++++- .../mapper/epmetuser/IcResiUserDao.xml | 43 +++++++++++++++++++ 3 files changed, 73 insertions(+), 2 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/epmetuser/IcResiUserDao.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/epmetuser/IcResiUserDao.java index 610d90c62d..3b3a66dd50 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/epmetuser/IcResiUserDao.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/dao/epmetuser/IcResiUserDao.java @@ -115,9 +115,27 @@ public interface IcResiUserDao extends BaseDao { @Param("search")String search, @Param("resiCategory")String resiCategory); + Integer countVolunteersWithoutVolCategory(@Param("customerId")String customerId, + @Param("agencyId")String agencyId, + @Param("staffOrgIds")String staffOrgIds, + @Param("search")String search); + List listVolunteersByCategory(@Param("customerId")String customerId, @Param("agencyId")String agencyId, @Param("staffOrgIds")String staffOrgIds, @Param("search")String search, @Param("resiCategory")String resiCategory); + + /** + * 列出没有志愿者类别的志愿者 + * @param customerId + * @param agencyId + * @param staffOrgIds + * @param search + * @return + */ + List listVolunteersWithoutVolCategory(@Param("customerId")String customerId, + @Param("agencyId")String agencyId, + @Param("staffOrgIds")String staffOrgIds, + @Param("search")String search); } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/EpmetUserServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/EpmetUserServiceImpl.java index b42e78b256..2e4d184353 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/EpmetUserServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/epmetuser/impl/EpmetUserServiceImpl.java @@ -857,11 +857,21 @@ public class EpmetUserServiceImpl implements EpmetUserService { @Override public Integer countVolunteers(String customerId, String agencyId, String staffOrgIds, String search, String resiCategory) { - return icResiUserDao.countVolunteersByCategory(customerId, agencyId, staffOrgIds, search, resiCategory); + if ("others".equals(resiCategory)) { + //others需要特殊处理,它是指那些勾选了是志愿者,但是没有选择具体志愿者类型的居民,实际上志愿者类型里面没有others这个类别的 + return icResiUserDao.countVolunteersWithoutVolCategory(customerId, agencyId, staffOrgIds, search); + } else { + return icResiUserDao.countVolunteersByCategory(customerId, agencyId, staffOrgIds, search, resiCategory); + } } @Override public List listVolunteers(String customerId, String agencyId, String staffOrgIds, String search, String resiCategory) { - return icResiUserDao.listVolunteersByCategory(customerId, agencyId, staffOrgIds, search, resiCategory); + if ("others".equals(resiCategory)) { + //others需要特殊处理,它是指那些勾选了是志愿者,但是没有选择具体志愿者类型的居民,实际上志愿者类型里面没有others这个类别的 + return icResiUserDao.listVolunteersWithoutVolCategory(customerId, agencyId, staffOrgIds, search); + } else { + return icResiUserDao.listVolunteersByCategory(customerId, agencyId, staffOrgIds, search, resiCategory); + } } } diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml index 9097a47098..84c5386481 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml @@ -188,6 +188,7 @@ from ic_resi_user resi inner join ic_volunteer vol on (resi.ID = vol.IC_RESI_USER and vol.DEL_FLAG = '0') where resi.DEL_FLAG = '0' + and resi.IS_VOLUNTEER = '1' and resi.CUSTOMER_ID = #{customerId} and resi.AGENCY_ID = #{agencyId} @@ -202,11 +203,32 @@ + + + + + From 01e3dc01abce9e7bba876181632c5e0c198533cb Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Tue, 2 Aug 2022 15:59:28 +0800 Subject: [PATCH 148/155] =?UTF-8?q?colVal=E5=8F=AF=E7=A9=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/epmet/dto/form/policy/IcPolicyRuleDetailDTO.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/form/policy/IcPolicyRuleDetailDTO.java b/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/form/policy/IcPolicyRuleDetailDTO.java index d9f15f9637..910a5b2e38 100644 --- a/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/form/policy/IcPolicyRuleDetailDTO.java +++ b/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/form/policy/IcPolicyRuleDetailDTO.java @@ -64,7 +64,7 @@ public class IcPolicyRuleDetailDTO { /** * 参数值 */ - @NotBlank(message = "参数值不能为空", groups = {ResiRulerShowGroup.class,HouseRulerShowGroup.class,StatRulerShowGroup.class}) + // @NotBlank(message = "参数值不能为空", groups = {ResiRulerShowGroup.class,HouseRulerShowGroup.class,StatRulerShowGroup.class}) private String colVal; /** From fa1a116aa454e8c329b20e98b8d9d328632f7d4f Mon Sep 17 00:00:00 2001 From: wangxianzhang Date: Tue, 2 Aug 2022 16:11:04 +0800 Subject: [PATCH 149/155] =?UTF-8?q?=E3=80=90=E6=94=BF=E7=AD=96=E6=89=BE?= =?UTF-8?q?=E4=BA=BA=E3=80=91=E6=9F=A5=E8=AF=A2=E5=88=97=E8=A1=A8=E5=8A=A8?= =?UTF-8?q?=E4=BD=9C=EF=BC=8C=E6=94=AF=E6=8C=81=E4=BC=A0=E5=85=A5is=5Fnull?= =?UTF-8?q?/is=5Fnot=5Fnull?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../mapper/epmetuser/IcResiUserDao.xml | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml index adcb55f269..cc7cf00738 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/resources/mapper/epmetuser/IcResiUserDao.xml @@ -116,13 +116,24 @@ and - ${rule.colTable}.${rule.colKey} ${rule.queryType} - - CONCAT('%',#{rule.colVal} ,'%') + + + (${rule.colTable}.${rule.colKey} is null or ${rule.colTable}.${rule.colKey} = '') + + + (${rule.colTable}.${rule.colKey} is not null and ${rule.colTable}.${rule.colKey} != '') - #{rule.colVal} + ${rule.colTable}.${rule.colKey} ${rule.queryType} + + + CONCAT('%',#{rule.colVal} ,'%') + + + #{rule.colVal} + + ${rule.nextLogicalRel} From d230318120e44550a3e698b51d6812bf360b29e4 Mon Sep 17 00:00:00 2001 From: zxc <1272811460@qq.com> Date: Tue, 2 Aug 2022 16:49:26 +0800 Subject: [PATCH 150/155] emm --- .../java/com/epmet/service/impl/CustomerStaffServiceImpl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java index 77af73c96d..5f3169e154 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/CustomerStaffServiceImpl.java @@ -515,7 +515,7 @@ public class CustomerStaffServiceImpl extends BaseServiceImpl staffIdList) { //1:批量查询人员基本信息 - List staffList = baseDao.selectStaffByIds(staffIdList, null); + List staffList = baseDao.selectStaffByIds(staffIdList, Constant.ENABLE); //2:批量查询人员拥有的所有角色信息 List roleList = staffRoleDao.selectStaffRoleList(staffIdList); CustomerStaffListResultDTO list = new CustomerStaffListResultDTO(); From 615f8a8a6b12067fd790b564b0cd6dd9875f942d Mon Sep 17 00:00:00 2001 From: wangxianzhang Date: Tue, 2 Aug 2022 17:03:59 +0800 Subject: [PATCH 151/155] =?UTF-8?q?=E3=80=90=E6=94=BF=E7=AD=96=E6=89=BE?= =?UTF-8?q?=E4=BA=BA=E3=80=91=E4=BF=AE=E5=A4=8D=EF=BC=9A=E5=B9=B4=E9=BE=84?= =?UTF-8?q?-=E4=B8=8D=E4=B8=BA=E7=A9=BA=EF=BC=8C=E6=8A=A5NumberFormatExcep?= =?UTF-8?q?tion?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dataaggre/service/impl/ResiServiceImpl.java | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/ResiServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/ResiServiceImpl.java index 8ea7d871d5..6c35d40b73 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/ResiServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/ResiServiceImpl.java @@ -149,7 +149,8 @@ public class ResiServiceImpl implements ResiService, ResultDataResolver { // 使用年龄计算出生日期 if (resiRule != null) { resiRule.stream().forEach((r) -> { - if ("BIRTHDAY".equals(r.getColKey())) { + // 对生日列计算,并且内容是数字,才计算 + if ("BIRTHDAY".equals(r.getColKey()) && StringUtils.isNumeric(r.getColVal())) { LocalDate birthday = LocalDate.now().minus(Long.valueOf(r.getColVal()), ChronoUnit.YEARS); r.setQueryType(revertQueryType(r.getQueryType())); r.setColVal(birthday.format(DateTimeFormatter.ofPattern("yyyy-MM-dd"))); @@ -209,7 +210,16 @@ public class ResiServiceImpl implements ResiService, ResultDataResolver { resultResis.stream().forEach((r) -> { // 小区名称 - r.setNeighborHoodName(gridIdAndName.get(r.getGridId()).concat("-").concat(neighborhoodIdAndName.get(r.getNeighborhoodId()))); + String gridName = gridIdAndName.get(r.getGridId()); + String neighborhoodName = neighborhoodIdAndName.get(r.getNeighborhoodId()); + + if (StringUtils.isNoneBlank(gridName, neighborhoodName)) { + // 网格或者小区都能找到,给填充数据 + r.setNeighborHoodName(gridIdAndName.get(r.getGridId()).concat("-").concat(neighborhoodIdAndName.get(r.getNeighborhoodId()))); + } else { + // 网格或者小区中任何一个找不到,给个空 + r.setNeighborHoodName(""); + } // 出生日期 & 年龄 if (r.getBirthday() != null) { From d3e93bfce4ee7ef99bf259b0f72193d689c17415 Mon Sep 17 00:00:00 2001 From: wangxianzhang Date: Tue, 2 Aug 2022 17:07:18 +0800 Subject: [PATCH 152/155] =?UTF-8?q?=E3=80=90=E6=94=BF=E7=AD=96=E6=89=BE?= =?UTF-8?q?=E4=BA=BA=E3=80=91=E4=BF=AE=E5=A4=8D=EF=BC=9A=E5=B9=B4=E9=BE=84?= =?UTF-8?q?-=E4=B8=8D=E4=B8=BA=E7=A9=BA=EF=BC=8C=E6=8A=A5NumberFormatExcep?= =?UTF-8?q?tion?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dataaggre/service/impl/ResiServiceImpl.java | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/ResiServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/ResiServiceImpl.java index 6c35d40b73..59810ea97b 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/ResiServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/impl/ResiServiceImpl.java @@ -149,11 +149,17 @@ public class ResiServiceImpl implements ResiService, ResultDataResolver { // 使用年龄计算出生日期 if (resiRule != null) { resiRule.stream().forEach((r) -> { - // 对生日列计算,并且内容是数字,才计算 - if ("BIRTHDAY".equals(r.getColKey()) && StringUtils.isNumeric(r.getColVal())) { - LocalDate birthday = LocalDate.now().minus(Long.valueOf(r.getColVal()), ChronoUnit.YEARS); - r.setQueryType(revertQueryType(r.getQueryType())); - r.setColVal(birthday.format(DateTimeFormatter.ofPattern("yyyy-MM-dd"))); + // 对生日列计算 + if ("BIRTHDAY".equals(r.getColKey())) { + if ("is_null".equals(r.getQueryType()) || "is_not_null".equals(r.getQueryType())) { + // 如果是is_null、is_not_null,那么直接用这个条件 + return; + } else { + //如果不是is_null、is_not_null,那么需要转换为出生日期 + LocalDate birthday = LocalDate.now().minus(Long.valueOf(r.getColVal()), ChronoUnit.YEARS); + r.setQueryType(revertQueryType(r.getQueryType())); + r.setColVal(birthday.format(DateTimeFormatter.ofPattern("yyyy-MM-dd"))); + } } }); } From 52120e177853b5bad285e3d169b87b6693f3d9a1 Mon Sep 17 00:00:00 2001 From: jianjun Date: Tue, 2 Aug 2022 17:40:48 +0800 Subject: [PATCH 153/155] 5 --- .../service/govproject/impl/GovProjectServiceImpl.java | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/impl/GovProjectServiceImpl.java b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/impl/GovProjectServiceImpl.java index 88793a90dd..82b58c2500 100644 --- a/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/impl/GovProjectServiceImpl.java +++ b/epmet-module/data-aggregator/data-aggregator-server/src/main/java/com/epmet/dataaggre/service/govproject/impl/GovProjectServiceImpl.java @@ -26,10 +26,10 @@ import com.epmet.dataaggre.dto.datastats.result.FactAgencyProjectResultDTO; import com.epmet.dataaggre.dto.govissue.IssueProjectCategoryDictDTO; import com.epmet.dataaggre.dto.govissue.result.IssueInfoDTO; import com.epmet.dataaggre.dto.govissue.result.IssueListResultDTO; -import com.epmet.dataaggre.dto.govorg.form.OrgStatisticsFormDTO; -import com.epmet.dataaggre.dto.govorg.result.OrgCountDTO; import com.epmet.dataaggre.dto.govorg.form.CoverageHomeSearchFormDTO; +import com.epmet.dataaggre.dto.govorg.form.OrgStatisticsFormDTO; import com.epmet.dataaggre.dto.govorg.result.EventInfoResultDTO; +import com.epmet.dataaggre.dto.govorg.result.OrgCountDTO; import com.epmet.dataaggre.dto.govproject.ProjectDTO; import com.epmet.dataaggre.dto.govproject.ProjectRelatedPersonnelDTO; import com.epmet.dataaggre.dto.govproject.ResiEventDTO; @@ -791,4 +791,10 @@ public class GovProjectServiceImpl implements GovProjectService { return query; } + + @Override + public List getEventInfos(CoverageHomeSearchFormDTO formDTO) { + return icEventDao.getEventInfos(formDTO); + } + } From a0bb593b487156ba2cc073ccddd39e8ef0d80dbd Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Tue, 2 Aug 2022 18:38:12 +0800 Subject: [PATCH 154/155] try --- .../main/java/com/epmet/service/impl/GovRoleServiceImpl.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovRoleServiceImpl.java b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovRoleServiceImpl.java index a72f8dd1f2..eb90de87c0 100644 --- a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovRoleServiceImpl.java +++ b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovRoleServiceImpl.java @@ -21,10 +21,8 @@ import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; import com.epmet.commons.mybatis.service.impl.BaseServiceImpl; import com.epmet.commons.tools.constant.FieldConstant; -import com.epmet.commons.tools.constant.NumConstant; import com.epmet.commons.tools.exception.EpmetErrorCode; import com.epmet.commons.tools.exception.EpmetException; -import com.epmet.commons.tools.exception.RenException; import com.epmet.commons.tools.page.PageData; import com.epmet.commons.tools.security.user.LoginUserUtil; import com.epmet.commons.tools.utils.ConvertUtils; @@ -147,6 +145,7 @@ public class GovRoleServiceImpl extends BaseServiceImpl Date: Tue, 2 Aug 2022 18:46:49 +0800 Subject: [PATCH 155/155] try --- .../main/java/com/epmet/service/impl/GovRoleServiceImpl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovRoleServiceImpl.java b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovRoleServiceImpl.java index eb90de87c0..3f7bae6b47 100644 --- a/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovRoleServiceImpl.java +++ b/epmet-module/gov-access/gov-access-server/src/main/java/com/epmet/service/impl/GovRoleServiceImpl.java @@ -144,7 +144,7 @@ public class GovRoleServiceImpl extends BaseServiceImpl