From 1cceb8cb0e6aca65b26b0c4dc6135e628983a872 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Mon, 22 Jun 2020 18:11:31 +0800 Subject: [PATCH] =?UTF-8?q?=E7=BB=84=E7=BB=87=E8=83=BD=E5=8A=9B-=E7=94=A8?= =?UTF-8?q?=E6=88=B7=E7=9B=B8=E5=85=B3=E6=9F=A5=E8=AF=A2=E6=8E=A5=E5=8F=A3?= =?UTF-8?q?=E5=88=9D=E5=A7=8B=E6=8F=90=E4=BA=A4v1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../constant/DataReportModuleConstant.java | 22 +++++++++ .../user/result/UserSummaryInfoResultDTO.java | 27 ++++++++++- .../{module/user => }/controller/.gitignore | 0 .../epmet/{module/user => }/dao/.gitignore | 0 .../com/epmet/dao/user/UserAnalysisDao.java | 32 +++++++++++++ .../{module/user => }/service/.gitignore | 0 .../resources/mapper/user/UserAnalysisDao.xml | 46 +++++++++++++++++++ 7 files changed, 125 insertions(+), 2 deletions(-) create mode 100644 epmet-module/data-report/data-report-client/src/main/java/com/epmet/constant/DataReportModuleConstant.java rename epmet-module/data-report/data-report-server/src/main/java/com/epmet/{module/user => }/controller/.gitignore (100%) rename epmet-module/data-report/data-report-server/src/main/java/com/epmet/{module/user => }/dao/.gitignore (100%) create mode 100644 epmet-module/data-report/data-report-server/src/main/java/com/epmet/dao/user/UserAnalysisDao.java rename epmet-module/data-report/data-report-server/src/main/java/com/epmet/{module/user => }/service/.gitignore (100%) create mode 100644 epmet-module/data-report/data-report-server/src/main/resources/mapper/user/UserAnalysisDao.xml diff --git a/epmet-module/data-report/data-report-client/src/main/java/com/epmet/constant/DataReportModuleConstant.java b/epmet-module/data-report/data-report-client/src/main/java/com/epmet/constant/DataReportModuleConstant.java new file mode 100644 index 0000000000..09a81ccbb4 --- /dev/null +++ b/epmet-module/data-report/data-report-client/src/main/java/com/epmet/constant/DataReportModuleConstant.java @@ -0,0 +1,22 @@ +package com.epmet.constant; + +/** + * 描述一下 + * + * @author yinzuomei@elink-cn.com + * @date 2020/6/22 16:35 + */ +public interface DataReportModuleConstant { + + /** + * reg:注册居民 parti:参与用户,如果值为null,默认为reg + */ + String REG_FLAG="reg"; + + /** + * reg:注册居民 parti:参与用户,如果值为null,默认为reg + */ + String PARTI_FLAG="parti"; + + String QUERY_USER_AGENCY_FAILED="查询用户所属机关信息失败"; +} diff --git a/epmet-module/data-report/data-report-client/src/main/java/com/epmet/user/result/UserSummaryInfoResultDTO.java b/epmet-module/data-report/data-report-client/src/main/java/com/epmet/user/result/UserSummaryInfoResultDTO.java index f745321971..f44d5ec054 100644 --- a/epmet-module/data-report/data-report-client/src/main/java/com/epmet/user/result/UserSummaryInfoResultDTO.java +++ b/epmet-module/data-report/data-report-client/src/main/java/com/epmet/user/result/UserSummaryInfoResultDTO.java @@ -4,6 +4,7 @@ import com.fasterxml.jackson.annotation.JsonIgnore; import lombok.Data; import java.io.Serializable; +import java.math.BigDecimal; /** * 用户汇总信息 返参DTO @@ -38,17 +39,39 @@ public class UserSummaryInfoResultDTO implements Serializable { * 党员占比 */ private String partymemberProportion; - /** * 热心居民数 */ - private String warmHeartedTotal; + private Integer warmHeartedTotal; /** * 热心居民占比 */ private String warmHeartedProportion; + @JsonIgnore + private BigDecimal partymemberProportionValue; + + @JsonIgnore + private BigDecimal warmHeartedProportionValue; + @JsonIgnore private String id; + + public UserSummaryInfoResultDTO(){ + this.currentDate=""; + this.regTotal=0; + this.partiTotal=0; + this.partymemberTotal=0; + this.partymemberProportion="0%"; + this.warmHeartedTotal=0; + this.warmHeartedProportion="0%"; + this.id=""; + } + + public static void main(String[] args) { + StringBuffer s=new StringBuffer("20190305").insert(4,".").insert(7,"."); + System.out.println(s); + + } } diff --git a/epmet-module/data-report/data-report-server/src/main/java/com/epmet/module/user/controller/.gitignore b/epmet-module/data-report/data-report-server/src/main/java/com/epmet/controller/.gitignore similarity index 100% rename from epmet-module/data-report/data-report-server/src/main/java/com/epmet/module/user/controller/.gitignore rename to epmet-module/data-report/data-report-server/src/main/java/com/epmet/controller/.gitignore diff --git a/epmet-module/data-report/data-report-server/src/main/java/com/epmet/module/user/dao/.gitignore b/epmet-module/data-report/data-report-server/src/main/java/com/epmet/dao/.gitignore similarity index 100% rename from epmet-module/data-report/data-report-server/src/main/java/com/epmet/module/user/dao/.gitignore rename to epmet-module/data-report/data-report-server/src/main/java/com/epmet/dao/.gitignore diff --git a/epmet-module/data-report/data-report-server/src/main/java/com/epmet/dao/user/UserAnalysisDao.java b/epmet-module/data-report/data-report-server/src/main/java/com/epmet/dao/user/UserAnalysisDao.java new file mode 100644 index 0000000000..e42caca3b9 --- /dev/null +++ b/epmet-module/data-report/data-report-server/src/main/java/com/epmet/dao/user/UserAnalysisDao.java @@ -0,0 +1,32 @@ +package com.epmet.dao.user; + + +import com.epmet.user.result.UserSummaryInfoResultDTO; +import org.apache.ibatis.annotations.Mapper; + +/** + * 描述一下 + * + * @author yinzuomei@elink-cn.com + * @date 2020/6/22 16:33 + */ +@Mapper +public interface UserAnalysisDao { + /** + * @param myAgencyId + * @return com.epmet.user.result.UserSummaryInfoResultDTO + * @author yinzuomei + * @description 查询注册用户汇总信息 + * @Date 2020/6/22 16:52 + **/ + UserSummaryInfoResultDTO selectRegUserSummaryInfo(String myAgencyId); + + /** + * @param myAgencyId + * @return com.epmet.user.result.UserSummaryInfoResultDTO + * @author yinzuomei + * @description 查询注册用户的汇总信息 + * @Date 2020/6/22 16:52 + **/ + UserSummaryInfoResultDTO selectParticipationUserSummaryInfo(String myAgencyId); +} diff --git a/epmet-module/data-report/data-report-server/src/main/java/com/epmet/module/user/service/.gitignore b/epmet-module/data-report/data-report-server/src/main/java/com/epmet/service/.gitignore similarity index 100% rename from epmet-module/data-report/data-report-server/src/main/java/com/epmet/module/user/service/.gitignore rename to epmet-module/data-report/data-report-server/src/main/java/com/epmet/service/.gitignore diff --git a/epmet-module/data-report/data-report-server/src/main/resources/mapper/user/UserAnalysisDao.xml b/epmet-module/data-report/data-report-server/src/main/resources/mapper/user/UserAnalysisDao.xml new file mode 100644 index 0000000000..a1bc581a7c --- /dev/null +++ b/epmet-module/data-report/data-report-server/src/main/resources/mapper/user/UserAnalysisDao.xml @@ -0,0 +1,46 @@ + + + + + + + + + + \ No newline at end of file