From 5fe95c558d92e36f9a42f8523440319ae2015798 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Fri, 17 Feb 2023 12:55:12 +0800 Subject: [PATCH 1/7] =?UTF-8?q?=E7=A6=8F=E5=88=A9=E4=BA=BA=E5=91=98?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E5=8F=91=E6=94=BE=E6=A0=87=E8=AF=86=E3=80=81?= =?UTF-8?q?=E7=A6=8F=E5=88=A9=E7=B1=BB=E5=88=AB=E5=90=8D=E7=A7=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/epmet/dto/ChangeWelfareDTO.java | 14 ++++++- .../com/epmet/entity/ChangeWelfareEntity.java | 8 ++++ .../com/epmet/excel/ChangeWelfareExcel.java | 18 +++++++-- .../epmet/excel/ChangeWelfareImportExcel.java | 10 +++++ .../epmet/service/ChangeWelfareService.java | 2 +- .../impl/ChangeWelfareServiceImpl.java | 35 +++++++++++++----- .../migration/V0.0.94__pli_change_welfare.sql | 4 ++ .../resources/excel/pli_change_welfare.xlsx | Bin 11358 -> 11461 bytes .../resources/mapper/ChangeWelfareDao.xml | 16 ++++++-- 9 files changed, 89 insertions(+), 18 deletions(-) create mode 100644 epmet-user/epmet-user-server/src/main/resources/db/migration/V0.0.94__pli_change_welfare.sql diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/ChangeWelfareDTO.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/ChangeWelfareDTO.java index 02ce0b34c8..7ee639d7dc 100644 --- a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/ChangeWelfareDTO.java +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/ChangeWelfareDTO.java @@ -1,6 +1,8 @@ package com.epmet.dto; +import com.epmet.commons.tools.validator.group.CustomerClientShowGroup; import lombok.Data; +import org.hibernate.validator.constraints.Length; import java.io.Serializable; import java.util.Date; @@ -16,7 +18,7 @@ import java.util.Date; public class ChangeWelfareDTO implements Serializable { private static final long serialVersionUID = 1L; - + public interface AddUserShowGroup extends CustomerClientShowGroup {} /** * 主键 */ @@ -116,4 +118,14 @@ public class ChangeWelfareDTO implements Serializable { * 是否享受福利,1是 0否 空是 */ private String isWelfare; + + /** + * 福利发放标识:1:已发放;0:未发放 + */ + private Integer grantFlag; + /** + * 福利类别 + */ + @Length(max = 100,message = "福利类别最多输入100字",groups = AddUserShowGroup.class) + private String categoryName; } diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/entity/ChangeWelfareEntity.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/entity/ChangeWelfareEntity.java index 2ddb43582a..7f0ec9189d 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/entity/ChangeWelfareEntity.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/entity/ChangeWelfareEntity.java @@ -72,6 +72,14 @@ public class ChangeWelfareEntity extends BaseEpmetEntity { * 移除原因 */ private String removeReason; + /** + * 福利发放标识:1:已发放;0:未发放 + */ + private Integer grantFlag; + /** + * 福利类别 + */ + private String categoryName; /** * 客户ID diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/excel/ChangeWelfareExcel.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/excel/ChangeWelfareExcel.java index acb7705b2f..5a58288ba0 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/excel/ChangeWelfareExcel.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/excel/ChangeWelfareExcel.java @@ -21,13 +21,13 @@ public class ChangeWelfareExcel { // @Excel(name = "epmet网格ID") // private String gridId; - @Excel(name = "姓名") + @Excel(name = "姓名",width = 20) private String name; - @Excel(name = "证件号") + @Excel(name = "证件号",width = 20) private String idCard; - @Excel(name = "手机号") + @Excel(name = "手机号",width = 20) private String mobile; @Excel(name = "性别",replace = { "男_1", "女_0", "女_2", " _null"} ) @@ -36,8 +36,18 @@ public class ChangeWelfareExcel { // @Excel(name = "类型") // private String type; // - @Excel(name = "加入时间") + @Excel(name = "加入时间",width = 25) private String joinDate; + /** + * 福利发放标识:1:已发放;0:未发放 + */ + @Excel(name = "福利发放",replace = { "已发放_1", "未发放_0", "_null"},width = 20) + private Integer grantFlag; + /** + * 福利类别 + */ + @Excel(name = "福利类别",width = 120) + private String categoryName; // // @Excel(name = "加入原因") // private String joinReason; diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/excel/ChangeWelfareImportExcel.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/excel/ChangeWelfareImportExcel.java index 992be96b4a..07869bfb2f 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/excel/ChangeWelfareImportExcel.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/excel/ChangeWelfareImportExcel.java @@ -33,6 +33,16 @@ public class ChangeWelfareImportExcel { // @Excel(name = "客户ID") // private String customerId; + /** + * 福利发放标识:1:已发放;0:未发放 + */ + @Excel(name = "福利发放",replace = { "已发放_1", "未发放_0", "_null"}) + private Integer grantFlag; + /** + * 福利类别 + */ + @Excel(name = "福利类别") + private String categoryName; @ExcelIgnore private Boolean addStatus = false; diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/ChangeWelfareService.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/ChangeWelfareService.java index 184cfd9c9a..099c7ae432 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/ChangeWelfareService.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/ChangeWelfareService.java @@ -21,7 +21,7 @@ import java.util.Map; public interface ChangeWelfareService extends BaseService { /** - * 默认分页 + * 福利人员管理-分页查询 * * @param params * @return PageData diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/ChangeWelfareServiceImpl.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/ChangeWelfareServiceImpl.java index f5808bdf3b..9fd94f7a7f 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/ChangeWelfareServiceImpl.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/ChangeWelfareServiceImpl.java @@ -16,10 +16,7 @@ import com.epmet.commons.tools.redis.common.CustomerStaffRedis; import com.epmet.commons.tools.redis.common.bean.AgencyInfoCache; import com.epmet.commons.tools.security.dto.TokenDto; import com.epmet.commons.tools.security.user.LoginUserUtil; -import com.epmet.commons.tools.utils.ConvertUtils; -import com.epmet.commons.tools.utils.DateUtils; -import com.epmet.commons.tools.utils.ExcelPoiUtils; -import com.epmet.commons.tools.utils.Result; +import com.epmet.commons.tools.utils.*; import com.epmet.commons.tools.validator.ValidatorUtils; import com.epmet.commons.tools.validator.group.DefaultGroup; import com.epmet.commons.tools.validator.group.UpdateGroup; @@ -38,7 +35,6 @@ import com.epmet.entity.ChangeWelfareEntity; import com.epmet.excel.ChangeWelfareImportExcel; import com.epmet.excel.error.ChangeWelfareErrorExcel; import com.epmet.feign.EpmetCommonServiceOpenFeignClient; -import com.epmet.feign.GovOrgFeignClient; import com.epmet.feign.OssFeignClient; import com.epmet.redis.ChangeWelfareRedis; import com.epmet.service.ChangeWelfareService; @@ -88,12 +84,15 @@ public class ChangeWelfareServiceImpl extends BaseServiceImpl page(Map params) { params.put("customerId", loginUserUtil.getLoginUserCustomerId()); @@ -137,6 +136,12 @@ public class ChangeWelfareServiceImpl extends BaseServiceImplQ9BAW9GjnI%L;U1b)qt_)$5fjL@#QrO1R&ze0oGS(NEFS_&BfF) zinRCl_bwt#OIO6alcegf*`FU?ef@g5zwXi^=!+pt9@V1fT;}Y@8qiK0c>daR5&@56 z@<^iw1Vy;JU2qxVk!uAnO_NiJDviv;#pzx8k_wAj;wC!N;_S-Lv5ATlcM?ppQc7XH zHq%U|ukTmOu7o8}3b%`PkaUrbR|Ip+bKveLP8SSXhOON3I<%zu6n zv|PTti#V{UpM#CorO!K#iBmY2t@~ZIJbxa4;MKD_f6Po3Wq&j-e5Lo9bWCKDPz!tY zt<`;R%`}K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!e`>eOd84oH00_W_TUB3*L@Mr%}O- zW8r;e9#a(x3$n60qjSdZ=7!%qqRwYuvPz!cHz@>jcLAEOkbhwV-G6Dr42a?9+%0=x zxcx_i0q6w2J7`fB6tD!{#G=i}x^WWr9D@V+UqAuD51G+I3$QXFpY)1Qs+~n#zZ~m4 z=Frek`3|)e&!TqDsy23k#C}Xp+K|1vOmNu6t=rN3*$g>gs<&WaRO{@Kb@5ZiXlN2S zd!QyS!=JY+EerB`=eqQyVBupdUVhd#w(mmhDQpKIgrIr>=ly4G+SG%t&gog{cf>vT z?HM=UH(d5L+)4LBO1$tiN-o`T9~UX#fttqm z-{ZOyz)=TnhHp7Nse0glf-D%A?SBO7YBNp;5IiF5GQl-Jn$)ncPe}1u$|AXT} zEUWtalJFZk36~L5#TJhTy5L01@hAZW&`){9fO_Z}9yHN^2pw9BSCa8B9^$zz7Wpl& zqq!~IUjqVIZ%1ZyHZK$yfL`Ji0S2PU`6NNP>}WO)h#*`G2m;?$_x}mg|JMB0eQW=O zC}Y0u0B*+r{#F10vVZpfEdZlO`DB4_(8T;qjQ_zex0(D6{@4Bq(}jldD}z?a&=LF+ zKtgmIKR4uGO>>*J_N|!WAML-z7#8#uzZ}p4Eh8WY!g8Pk1fW11bd!K2 AND w.JOIN_DATE <= #{endTime} + + AND w.CATEGORY_NAME like concat('%',#{categoryName},'%') + + + AND w.GRANT_FLAG = #{grantFlag} + order by w.CREATED_TIME desc @@ -76,12 +84,14 @@ where ID_CARD=#{idCard} and del_flag='0' - + update pli_change_welfare set REMOVE_DATE=#{removeDate}, REMOVE_REASON=#{removeReason}, - del_flag='1' + del_flag='1', + UPDATED_BY = #{updatedBy}, + UPDATED_TIME = #{removeDate} where del_flag='0' AND ID = #{id} From 64a9eae8cdecf9290616db982d9bc53e5ed94e70 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Fri, 17 Feb 2023 14:26:06 +0800 Subject: [PATCH 2/7] =?UTF-8?q?=E8=81=94=E5=BB=BA=E6=B4=BB=E5=8A=A8?= =?UTF-8?q?=E3=80=81=E8=81=94=E5=BB=BA=E5=8D=95=E4=BD=8D=E4=B8=8B=E8=BD=BD?= =?UTF-8?q?=E6=A8=A1=E6=9D=BF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controller/IcPartyActivityController.java | 31 ++++++++++++++++++ .../controller/IcPartyUnitController.java | 28 ++++++++++++++++ .../templates/icpartyactivity_import_tem.xlsx | Bin 0 -> 9091 bytes .../templates/icpartyunit_impoort_tem.xlsx | Bin 0 -> 9316 bytes 4 files changed, 59 insertions(+) create mode 100644 epmet-module/epmet-heart/epmet-heart-server/src/main/resources/templates/icpartyactivity_import_tem.xlsx create mode 100644 epmet-module/epmet-heart/epmet-heart-server/src/main/resources/templates/icpartyunit_impoort_tem.xlsx diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/controller/IcPartyActivityController.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/controller/IcPartyActivityController.java index 38b63b836d..5fb1845333 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/controller/IcPartyActivityController.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/controller/IcPartyActivityController.java @@ -41,13 +41,18 @@ import com.epmet.service.IcPartyActivityService; import lombok.extern.slf4j.Slf4j; import org.apache.commons.collections4.CollectionUtils; import org.apache.commons.io.FilenameUtils; +import org.apache.commons.io.IOUtils; import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.http.HttpHeaders; import org.springframework.web.bind.annotation.*; import org.springframework.web.multipart.MultipartFile; import javax.annotation.Resource; +import javax.servlet.ServletOutputStream; import javax.servlet.http.HttpServletResponse; import java.io.IOException; +import java.io.InputStream; +import java.net.URLEncoder; import java.util.ArrayList; import java.util.List; import java.util.concurrent.CompletableFuture; @@ -214,4 +219,30 @@ public class IcPartyActivityController { PageData page = icPartyActivityService.getActivityList(tokenDto, formDTO); return new Result>().ok(page); } + + /** + * 下载联建活动导入模板 + * @param response + * @throws IOException + */ + @RequestMapping(value = "import-template-download", method = {RequestMethod.GET, RequestMethod.POST}) + public void downloadTemplate(HttpServletResponse response) throws IOException { + response.setCharacterEncoding("UTF-8"); + response.addHeader(HttpHeaders.ACCESS_CONTROL_EXPOSE_HEADERS, "Content-Disposition"); + //response.setHeader(HttpHeaders.CONTENT_TYPE, "application/vnd.ms-excel"); + response.setHeader(HttpHeaders.CONTENT_TYPE, "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"); + response.setHeader(HttpHeaders.CONTENT_DISPOSITION, "attachment;filename=" + URLEncoder.encode("联建活动导入模板", "UTF-8") + ".xlsx"); + + InputStream is = this.getClass().getClassLoader().getResourceAsStream("templates/icpartyactivity_import_tem.xlsx"); + try { + ServletOutputStream os = response.getOutputStream(); + IOUtils.copy(is, os); + } finally { + if (is != null) { + is.close(); + } + } + } + + } 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 4545cb226b..dfa0808fce 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 @@ -27,14 +27,19 @@ import com.epmet.service.IcPartyUnitService; import lombok.extern.slf4j.Slf4j; import org.apache.commons.collections4.CollectionUtils; import org.apache.commons.io.FilenameUtils; +import org.apache.commons.io.IOUtils; import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.http.HttpHeaders; import org.springframework.web.bind.annotation.*; import org.springframework.web.multipart.MultipartFile; import javax.annotation.Resource; +import javax.servlet.ServletOutputStream; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import java.io.IOException; +import java.io.InputStream; +import java.net.URLEncoder; import java.nio.file.Path; import java.util.ArrayList; import java.util.List; @@ -330,4 +335,27 @@ public class IcPartyUnitController { return new Result(); } + /** + * 下载联建单位导入模板 + * @param response + * @throws IOException + */ + @RequestMapping(value = "import-template-download", method = {RequestMethod.GET, RequestMethod.POST}) + public void downloadTemplate(HttpServletResponse response) throws IOException { + response.setCharacterEncoding("UTF-8"); + response.addHeader(HttpHeaders.ACCESS_CONTROL_EXPOSE_HEADERS, "Content-Disposition"); + //response.setHeader(HttpHeaders.CONTENT_TYPE, "application/vnd.ms-excel"); + response.setHeader(HttpHeaders.CONTENT_TYPE, "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"); + response.setHeader(HttpHeaders.CONTENT_DISPOSITION, "attachment;filename=" + URLEncoder.encode("联建单位导入模板", "UTF-8") + ".xlsx"); + + InputStream is = this.getClass().getClassLoader().getResourceAsStream("templates/icpartyunit_impoort_tem.xlsx"); + try { + ServletOutputStream os = response.getOutputStream(); + IOUtils.copy(is, os); + } finally { + if (is != null) { + is.close(); + } + } + } } diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/resources/templates/icpartyactivity_import_tem.xlsx b/epmet-module/epmet-heart/epmet-heart-server/src/main/resources/templates/icpartyactivity_import_tem.xlsx new file mode 100644 index 0000000000000000000000000000000000000000..1d04c7c15d9349ff3e64e60391b15e6d6dcc760a GIT binary patch literal 9091 zcma)i1yq|$*De~|p?Hzv?oM$HP~0g_@jwU;rMN@U7AacXibHX?7AP(Sin|uqAKLq! zp2L6cckir~yjjWKvuB=}*)w^bQ3k@oAwxZsV5KF|hv$C^()|ZBkf|~l!yx!3-N$7OT zsbhGu@^f)>`8Kd}QBVYSdd@(0*Z&9epsuo|Fw!N@%jY>Ox_}KLry2ROoVKa&T_eNW zGw{btHy4MyCoC+BOqZJ_?>aV=w_({gVO4ej4St-U^eK#r2)iIjxEeAsyfe__PGWR1c^X*N3IGl3>*SL~+hrgU@hdmaiWC_7(gzEvr=^7p}+}p5MAHOUKbG-cixr?nnO^Q3PWf zAn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QLAerCg9r)Y@Z{ zfpRtSQr7JO(@`v(Ot{PzKWCpapqp)?7Y1uxI#^IA$VC$~ut!$gE-&G%^lC8an2x)h z)8nHnSEvSJR}x}=Lc}=n$u}G7XbUMW>{m@!HtT;BhzpL@?Tnw+Inq;+_?ffQ5C&P< z8(G=wD7jc0*=aqm_tH-TvJgxdftM7`9XT4ziq?8zdb-O-g@6^v@rzcLv$!nz$L7q<$zQsw1)C z^Ry|^Nzw7q!V99`2w z*Ld1?YQS~}BPRt8f${T!_iKm1pPqSg4j4EX@zZx1;lKLnmx2E~rV@R))4=;kn}`6KU?^# zqWJ%R@5XRHRsX|Z{XRqfWU&73G2)+UfAd*?4*Ab)=5GTXPfvxXA^#J$|2F7nX8l)t w_OSgg5C6uq|330Rnf7PhUtY`jU%G$u?s8Jl&-uaAwiQ$`*e5x0;^$xg4^YGiCIA2c literal 0 HcmV?d00001 From c1d3bdee289e338dbb1fc4d3d27d425136923144 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Fri, 17 Feb 2023 17:05:41 +0800 Subject: [PATCH 3/7] =?UTF-8?q?=E8=81=94=E5=BB=BA=E5=8D=95=E4=BD=8D?= =?UTF-8?q?=E5=AF=BC=E5=87=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/epmet/dto/IcPartyUnitDTO.java | 5 ++ .../com/epmet/dto/form/PartyUnitFormDTO.java | 7 +- .../controller/IcPartyUnitController.java | 67 ++++++++++++------- .../com/epmet/excel/IcPartyUnitExcel.java | 41 ++++++++---- .../service/impl/IcPartyUnitServiceImpl.java | 6 ++ 5 files changed, 83 insertions(+), 43 deletions(-) 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 1aed3be19f..b269fa0d5b 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 @@ -86,6 +86,11 @@ public class IcPartyUnitDTO implements Serializable { */ private List serviceMatterNameList; + /** + * 服务事项名称多个按照中文顿号隔开 + */ + private String serviceMatterName; + /** * 联系人 */ diff --git a/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/form/PartyUnitFormDTO.java b/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/form/PartyUnitFormDTO.java index ec4a1751dd..f238e5dbe1 100644 --- a/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/form/PartyUnitFormDTO.java +++ b/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/form/PartyUnitFormDTO.java @@ -1,5 +1,6 @@ package com.epmet.dto.form; +import com.epmet.commons.tools.dto.form.PageFormDTO; import lombok.Data; import lombok.NoArgsConstructor; @@ -12,7 +13,7 @@ import java.io.Serializable; */ @NoArgsConstructor @Data -public class PartyUnitFormDTO implements Serializable { +public class PartyUnitFormDTO extends PageFormDTO implements Serializable { private static final long serialVersionUID = 1256798619648265622L; private String customerId; @@ -22,8 +23,8 @@ public class PartyUnitFormDTO implements Serializable { private String type; private String contact; private String contactMobile; - private Integer pageNo; - private Integer pageSize; + // private Integer pageNo; + // private Integer pageSize; /** * 工作端当前登录人员 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 dfa0808fce..2832d0009d 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 @@ -1,16 +1,24 @@ package com.epmet.controller; +import com.alibaba.excel.EasyExcel; +import com.alibaba.excel.ExcelWriter; +import com.alibaba.excel.write.metadata.WriteSheet; import com.epmet.commons.rocketmq.messages.ServerSatisfactionCalFormDTO; import com.epmet.commons.tools.annotation.LoginUser; import com.epmet.commons.tools.aop.NoRepeatSubmit; import com.epmet.commons.tools.constant.AppClientConstant; +import com.epmet.commons.tools.constant.NumConstant; +import com.epmet.commons.tools.constant.StrConstant; import com.epmet.commons.tools.dto.result.OptionDataResultDTO; import com.epmet.commons.tools.exception.ExceptionUtils; import com.epmet.commons.tools.exception.RenException; import com.epmet.commons.tools.page.PageData; import com.epmet.commons.tools.security.dto.TokenDto; +import com.epmet.commons.tools.utils.ConvertUtils; +import com.epmet.commons.tools.utils.DateUtils; import com.epmet.commons.tools.utils.ExcelUtils; import com.epmet.commons.tools.utils.Result; +import com.epmet.commons.tools.utils.poi.excel.handler.FreezeAndFilter; import com.epmet.commons.tools.validator.AssertUtils; import com.epmet.commons.tools.validator.ValidatorUtils; import com.epmet.commons.tools.validator.group.AddGroup; @@ -28,6 +36,7 @@ import lombok.extern.slf4j.Slf4j; import org.apache.commons.collections4.CollectionUtils; import org.apache.commons.io.FilenameUtils; import org.apache.commons.io.IOUtils; +import org.apache.commons.lang3.StringUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.http.HttpHeaders; import org.springframework.web.bind.annotation.*; @@ -40,11 +49,9 @@ import javax.servlet.http.HttpServletResponse; import java.io.IOException; import java.io.InputStream; import java.net.URLEncoder; -import java.nio.file.Path; -import java.util.ArrayList; +import java.util.Date; import java.util.List; import java.util.concurrent.CompletableFuture; -import java.util.concurrent.atomic.AtomicInteger; import java.util.stream.Collectors; @@ -64,11 +71,6 @@ public class IcPartyUnitController { @Resource private EpmetCommonServiceOpenFeignClient commonServiceOpenFeignClient; - /** - * 联建单位上传临时目录 - */ - private Path IC_PARTY_UNIT_UPLOAD_DIR; - /** * 联建单位-列表查询 @@ -122,25 +124,38 @@ public class IcPartyUnitController { @PostMapping("export") public void export(@LoginUser TokenDto tokenDto, @RequestBody PartyUnitFormDTO formDTO, HttpServletResponse response) throws Exception { formDTO.setCustomerId(tokenDto.getCustomerId()); - List list = icPartyUnitService.list(formDTO); - List excelList = new ArrayList<>(); - AtomicInteger i = new AtomicInteger(1); - if (CollectionUtils.isNotEmpty(list)) { - excelList = list.stream().map(item -> { - IcPartyUnitExcel excel = new IcPartyUnitExcel(); - excel.setIndex(i.getAndIncrement()); - excel.setUnitName(item.getUnitName()); - excel.setContact(item.getContact()); - excel.setContactMobile(item.getContactMobile()); - excel.setType(item.getType()); - excel.setMemberCount(item.getMemberCount()); - excel.setRemark(item.getRemark()); - excel.setSatisfaction(item.getSatisfaction()); - excel.setServiceMatter(String.join(String.valueOf((char) 10), item.getServiceMatterList())); - return excel; - }).collect(Collectors.toList()); + formDTO.setIsPage(false); + formDTO.setCurrentStaffId(tokenDto.getUserId()); + ExcelWriter excelWriter = null; + formDTO.setPageSize(NumConstant.TEN_THOUSAND); + int pageNo = formDTO.getPageNo(); + try { + // 这里 需要指定写用哪个class去写 + String today= DateUtils.format(new Date(),DateUtils.DATE_PATTERN_MMDD); + String fileName = "行程上报信息".concat(today); + excelWriter = EasyExcel.write(ExcelUtils.getOutputStreamForExcel(fileName, response), IcPartyUnitExcel.class).build(); + WriteSheet writeSheet = EasyExcel.writerSheet("Sheet1").registerWriteHandler(new FreezeAndFilter()).build(); + PageData data = null; + List list = null; + do { + data = icPartyUnitService.search(formDTO); + data.getList().stream().map(item -> { + item.setServiceMatterName(StringUtils.join(item.getServiceMatterList(), StrConstant.COMMA_ZH)); + return item; + }).collect(Collectors.toList()); + list = ConvertUtils.sourceToTarget(data.getList(), IcPartyUnitExcel.class); + formDTO.setPageNo(++pageNo); + excelWriter.write(list, writeSheet); + } while (CollectionUtils.isNotEmpty(data.getList()) && data.getList().size() == formDTO.getPageSize()); + + } catch (Exception e) { + log.error("export exception", e); + } finally { + // 千万别忘记finish 会帮忙关闭流 + if (excelWriter != null) { + excelWriter.finish(); + } } - ExcelUtils.exportExcelToTarget(response, null, excelList, IcPartyUnitExcel.class); } /** diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/excel/IcPartyUnitExcel.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/excel/IcPartyUnitExcel.java index 652542ef62..36e9484acc 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/excel/IcPartyUnitExcel.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/excel/IcPartyUnitExcel.java @@ -17,7 +17,8 @@ package com.epmet.excel; -import cn.afterturn.easypoi.excel.annotation.Excel; +import com.alibaba.excel.annotation.ExcelProperty; +import com.alibaba.excel.annotation.write.style.ColumnWidth; import lombok.Data; /** @@ -29,30 +30,42 @@ import lombok.Data; @Data public class IcPartyUnitExcel { - @Excel(name = "序号") - private Integer index; - - @Excel(name = "单位名称") + @ColumnWidth(30) + @ExcelProperty(value = "单位名称") private String unitName; - @Excel(name = "分类") - private String type; + @ColumnWidth(25) + @ExcelProperty(value = "所属组织") + private String agencyName; + + @ColumnWidth(25) + @ExcelProperty(value = "分类") + private String typeName; - @Excel(name = "服务事项") - private String serviceMatter; + /** + * 服务事项名称多个按照中文顿号隔开 + */ + @ColumnWidth(100) + @ExcelProperty(value = "服务事项") + private String serviceMatterName; - @Excel(name = "联系人") + @ColumnWidth(16) + @ExcelProperty(value = "联系人") private String contact; - @Excel(name = "联系电话") + @ColumnWidth(16) + @ExcelProperty(value = "联系电话") private String contactMobile; - @Excel(name = "在职党员") + @ColumnWidth(18) + @ExcelProperty(value = "在职党员数") private Integer memberCount; - @Excel(name = "群众满意度") + @ColumnWidth(18) + @ExcelProperty(value = "群众满意度") private String satisfaction; - @Excel(name = "备注") + @ColumnWidth(100) + @ExcelProperty(value = "备注") private String remark; } \ No newline at end of file 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 0f31a1287d..f430f2b711 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 @@ -145,6 +145,8 @@ public class IcPartyUnitServiceImpl extends BaseServiceImpl pointMap = icUserDemandRecService.getServicePoint(formDTO.getCustomerId(), UserDemandConstant.PARTY_UNIT); dtoList.forEach(item -> { + item.setTypeName(unitTypeMap.getData().get(item.getType())); + //这是错误的,应该是赋值type,遗留bug, 先不改了.... item.setType(unitTypeMap.getData().get(item.getType())); if (StringUtils.isNotBlank(item.getServiceMatter())) { List matters = Arrays.asList(item.getServiceMatter().split(StrConstant.COMMA)); @@ -183,6 +185,8 @@ public class IcPartyUnitServiceImpl extends BaseServiceImpl pointMap = icUserDemandRecService.getServicePoint(formDTO.getCustomerId(), UserDemandConstant.PARTY_UNIT); dtoList.forEach(item -> { + item.setTypeName(unitTypeMap.getData().get(item.getType())); + //这是错误的,应该是赋值type,遗留bug, 先不改了.... item.setType(unitTypeMap.getData().get(item.getType())); if (StringUtils.isNotBlank(item.getServiceMatter())) { List matters = Arrays.asList(item.getServiceMatter().split(StrConstant.COMMA)); @@ -217,6 +221,8 @@ public class IcPartyUnitServiceImpl extends BaseServiceImpl> typeDictMapRes=epmetAdminOpenFeignClient.dictMap(DictTypeEnum.PARTY_UNIT_TYPE.getCode()); Map typeDictMap = typeDictMapRes.success() && MapUtils.isNotEmpty(typeDictMapRes.getData()) ? typeDictMapRes.getData() : new HashMap<>(); + dto.setTypeName(MapUtils.isNotEmpty(typeDictMap) && typeDictMap.containsKey(dto.getType()) ? typeDictMap.get(dto.getType()) : StrConstant.EPMETY_STR); + //这是错误的,应该是赋值type,遗留bug, 先不改了.... dto.setType(MapUtils.isNotEmpty(typeDictMap) && typeDictMap.containsKey(dto.getType()) ? typeDictMap.get(dto.getType()) : StrConstant.EPMETY_STR); // 服务事项 if(CollectionUtils.isNotEmpty(dto.getServiceMatterList())){ From cc9a49883e11094bfcb204251d9561fa09ff42e6 Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Fri, 17 Feb 2023 17:30:50 +0800 Subject: [PATCH 4/7] =?UTF-8?q?=E8=81=94=E5=BB=BA=E6=B4=BB=E5=8A=A8?= =?UTF-8?q?=E5=AF=BC=E5=87=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/epmet/dto/IcPartyActivityDTO.java | 6 +- .../epmet/dto/form/PartyActivityFormDTO.java | 7 ++- .../controller/IcPartyActivityController.java | 55 ++++++++++++------- .../controller/IcPartyUnitController.java | 2 +- .../com/epmet/excel/IcPartyActivityExcel.java | 30 ++++++---- .../impl/IcPartyActivityServiceImpl.java | 5 ++ 6 files changed, 70 insertions(+), 35 deletions(-) diff --git a/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/IcPartyActivityDTO.java b/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/IcPartyActivityDTO.java index 0115706902..1217ea6875 100644 --- a/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/IcPartyActivityDTO.java +++ b/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/IcPartyActivityDTO.java @@ -179,5 +179,9 @@ public class IcPartyActivityDTO implements Serializable { */ @JsonIgnore private Date updatedTime; - + /** + * actId不为空小程序 + * 为空管理平台 + */ + private String originName; } \ No newline at end of file diff --git a/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/form/PartyActivityFormDTO.java b/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/form/PartyActivityFormDTO.java index fb67921cd8..76f6d485db 100644 --- a/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/form/PartyActivityFormDTO.java +++ b/epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/form/PartyActivityFormDTO.java @@ -1,5 +1,6 @@ package com.epmet.dto.form; +import com.epmet.commons.tools.dto.form.PageFormDTO; import lombok.Data; import lombok.NoArgsConstructor; import org.springframework.format.annotation.DateTimeFormat; @@ -15,7 +16,7 @@ import java.util.Date; */ @NoArgsConstructor @Data -public class PartyActivityFormDTO implements Serializable { +public class PartyActivityFormDTO extends PageFormDTO implements Serializable { private static final long serialVersionUID = -2510068555703677L; @NotBlank(message = "组织Id不能为空" ) private String agencyId; @@ -27,7 +28,7 @@ public class PartyActivityFormDTO implements Serializable { @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") private Date endTime; private String serviceMatter; - private Integer pageNo; - private Integer pageSize; + // private Integer pageNo; + // private Integer pageSize; private String customerId; } diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/controller/IcPartyActivityController.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/controller/IcPartyActivityController.java index 5fb1845333..2dce5600b5 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/controller/IcPartyActivityController.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/controller/IcPartyActivityController.java @@ -17,15 +17,21 @@ package com.epmet.controller; +import com.alibaba.excel.EasyExcel; +import com.alibaba.excel.ExcelWriter; +import com.alibaba.excel.write.metadata.WriteSheet; import com.epmet.commons.tools.annotation.LoginUser; import com.epmet.commons.tools.aop.NoRepeatSubmit; +import com.epmet.commons.tools.constant.NumConstant; import com.epmet.commons.tools.exception.ExceptionUtils; import com.epmet.commons.tools.exception.RenException; import com.epmet.commons.tools.page.PageData; import com.epmet.commons.tools.security.dto.TokenDto; +import com.epmet.commons.tools.utils.ConvertUtils; import com.epmet.commons.tools.utils.DateUtils; import com.epmet.commons.tools.utils.ExcelUtils; import com.epmet.commons.tools.utils.Result; +import com.epmet.commons.tools.utils.poi.excel.handler.FreezeAndFilter; import com.epmet.commons.tools.validator.ValidatorUtils; import com.epmet.commons.tools.validator.group.AddGroup; import com.epmet.commons.tools.validator.group.DefaultGroup; @@ -53,11 +59,9 @@ import javax.servlet.http.HttpServletResponse; import java.io.IOException; import java.io.InputStream; import java.net.URLEncoder; -import java.util.ArrayList; +import java.util.Date; import java.util.List; import java.util.concurrent.CompletableFuture; -import java.util.concurrent.atomic.AtomicInteger; -import java.util.stream.Collectors; /** @@ -116,23 +120,36 @@ public class IcPartyActivityController { } @PostMapping("export") - public void export(@RequestBody PartyActivityFormDTO formDTO, HttpServletResponse response) throws Exception { - List list = icPartyActivityService.list(formDTO); - List excelList = new ArrayList<>(); - AtomicInteger i = new AtomicInteger(1); - if (CollectionUtils.isNotEmpty(list)) { - excelList = list.stream().map(item -> { - IcPartyActivityExcel excel = new IcPartyActivityExcel(); - excel.setIndex(i.getAndIncrement()); - excel.setUnitName(item.getUnitName()); - excel.setTitle(item.getTitle()); - excel.setAddress(item.getAddress()); - excel.setPeopleCount(item.getPeopleCount()); - excel.setActivityTime(DateUtils.format(item.getActivityTime(), DateUtils.DATE_TIME_PATTERN)); - return excel; - }).collect(Collectors.toList()); + public void export(@LoginUser TokenDto tokenDto, @RequestBody PartyActivityFormDTO formDTO, HttpServletResponse response) throws Exception { + formDTO.setCustomerId(tokenDto.getCustomerId()); + formDTO.setIsPage(false); + ExcelWriter excelWriter = null; + formDTO.setPageSize(NumConstant.TEN_THOUSAND); + int pageNo = formDTO.getPageNo(); + try { + // 这里 需要指定写用哪个class去写 + String today= DateUtils.format(new Date(),DateUtils.DATE_PATTERN_MMDD); + String fileName = "联建活动".concat(today); + excelWriter = EasyExcel.write(ExcelUtils.getOutputStreamForExcel(fileName, response), IcPartyActivityExcel.class).build(); + WriteSheet writeSheet = EasyExcel.writerSheet("Sheet1").registerWriteHandler(new FreezeAndFilter()).build(); + PageData data = null; + List list = null; + do { + data = icPartyActivityService.search(formDTO); + list = ConvertUtils.sourceToTarget(data.getList(), IcPartyActivityExcel.class); + formDTO.setPageNo(++pageNo); + excelWriter.write(list, writeSheet); + } while (CollectionUtils.isNotEmpty(data.getList()) && data.getList().size() == formDTO.getPageSize()); + + } catch (Exception e) { + log.error("export exception", e); + } finally { + // 千万别忘记finish 会帮忙关闭流 + if (excelWriter != null) { + excelWriter.finish(); + } } - ExcelUtils.exportExcelToTarget(response, null, excelList, IcPartyActivityExcel.class); + } /** 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 2832d0009d..e1578a2d78 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 @@ -132,7 +132,7 @@ public class IcPartyUnitController { try { // 这里 需要指定写用哪个class去写 String today= DateUtils.format(new Date(),DateUtils.DATE_PATTERN_MMDD); - String fileName = "行程上报信息".concat(today); + String fileName = "联建单位".concat(today); excelWriter = EasyExcel.write(ExcelUtils.getOutputStreamForExcel(fileName, response), IcPartyUnitExcel.class).build(); WriteSheet writeSheet = EasyExcel.writerSheet("Sheet1").registerWriteHandler(new FreezeAndFilter()).build(); PageData data = null; diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/excel/IcPartyActivityExcel.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/excel/IcPartyActivityExcel.java index 9ea9544285..9f54fc3b8f 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/excel/IcPartyActivityExcel.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/excel/IcPartyActivityExcel.java @@ -17,7 +17,8 @@ package com.epmet.excel; -import cn.afterturn.easypoi.excel.annotation.Excel; +import com.alibaba.excel.annotation.ExcelProperty; +import com.alibaba.excel.annotation.write.style.ColumnWidth; import lombok.Data; /** @@ -28,23 +29,30 @@ import lombok.Data; */ @Data public class IcPartyActivityExcel { - - @Excel(name = "序号") - private Integer index; - - @Excel(name = "单位名称") + @ColumnWidth(20) + @ExcelProperty(value = "单位名称") private String unitName; - @Excel(name = "活动标题") + @ColumnWidth(25) + @ExcelProperty(value = "活动标题") private String title; - @Excel(name = "活动地址") + @ColumnWidth(35) + @ExcelProperty(value = "活动地址") private String address; - @Excel(name = "服务人数") + @ColumnWidth(15) + @ExcelProperty(value = "服务人数") private Integer peopleCount; - @Excel(name = "活动时间") + @ColumnWidth(20) + @ExcelProperty(value = "活动时间") private String activityTime; - + /** + * actId不为空小程序 + * 为空管理平台 + */ + @ColumnWidth(20) + @ExcelProperty(value = "来源") + private String originName; } diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcPartyActivityServiceImpl.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcPartyActivityServiceImpl.java index 4d89c1bef8..1e72ac9ae5 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcPartyActivityServiceImpl.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcPartyActivityServiceImpl.java @@ -151,6 +151,11 @@ public class IcPartyActivityServiceImpl extends BaseServiceImpl Date: Fri, 17 Feb 2023 17:39:35 +0800 Subject: [PATCH 5/7] =?UTF-8?q?=E6=97=B6=E9=97=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/java/com/epmet/excel/IcPartyActivityExcel.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/excel/IcPartyActivityExcel.java b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/excel/IcPartyActivityExcel.java index 9f54fc3b8f..4b52917350 100644 --- a/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/excel/IcPartyActivityExcel.java +++ b/epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/excel/IcPartyActivityExcel.java @@ -19,8 +19,11 @@ package com.epmet.excel; import com.alibaba.excel.annotation.ExcelProperty; import com.alibaba.excel.annotation.write.style.ColumnWidth; +import com.fasterxml.jackson.annotation.JsonFormat; import lombok.Data; +import java.util.Date; + /** * 联建活动 * @@ -47,7 +50,8 @@ public class IcPartyActivityExcel { @ColumnWidth(20) @ExcelProperty(value = "活动时间") - private String activityTime; + @JsonFormat(pattern="yyyy-MM-dd HH:mm:ss") + private Date activityTime; /** * actId不为空小程序 * 为空管理平台 From 7d31349b590538b2caac97f5532dddee7382ffca Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Mon, 20 Feb 2023 14:02:09 +0800 Subject: [PATCH 6/7] =?UTF-8?q?/icNat/add=E8=8E=B7=E5=8F=96=E5=B7=A5?= =?UTF-8?q?=E4=BD=9C=E4=BA=BA=E5=91=98=E4=BF=A1=E6=81=AF=E5=A4=B1=E8=B4=A5?= =?UTF-8?q?=E7=83=9F=E5=8F=B0=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../redis/common/CustomerStaffRedis.java | 3 ++- .../epmetuser/impl/EpmetUserServiceImpl.java | 4 ++-- .../com/epmet/dto/form/AddIcNatFormDTO.java | 6 ++++-- .../com/epmet/controller/IcNatController.java | 3 ++- .../epmet/service/impl/IcNatServiceImpl.java | 21 ++++++++++++------- 5 files changed, 24 insertions(+), 13 deletions(-) diff --git a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/redis/common/CustomerStaffRedis.java b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/redis/common/CustomerStaffRedis.java index 66abe790f3..61b5b6f250 100644 --- a/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/redis/common/CustomerStaffRedis.java +++ b/epmet-commons/epmet-commons-tools/src/main/java/com/epmet/commons/tools/redis/common/CustomerStaffRedis.java @@ -88,11 +88,12 @@ public class CustomerStaffRedis { private static CustomerStaffInfoCache reloadStaffCache(String staffId, String key) { Result staffResult = customerStaffRedis.commonAggFeignClient.getStaffInfo(staffId); if (staffResult == null || !staffResult.success()) { + log.error("/data/aggregator/epmetuser/getStaffInfo/{staffId} 异常 staffId: ",staffId); throw new RenException("获取工作人员信息失败"); } CustomerStaffInfoCache resultData = staffResult.getData(); if (resultData == null) { - log.warn("getStaffInfo staff is null,staffId:{}", staffId); + log.error("getStaffInfo staff is null,staffId:{}", staffId); return null; } 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 f6de7bd634..d81bb9b1e7 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 @@ -9,7 +9,6 @@ import com.epmet.commons.tools.constant.StrConstant; import com.epmet.commons.tools.dto.form.IdAndNameDTO; import com.epmet.commons.tools.dto.result.CustomerStaffInfoCacheResult; import com.epmet.commons.tools.enums.OrgTypeEnum; -import com.epmet.commons.tools.exception.EpmetException; import com.epmet.commons.tools.exception.EpmetErrorCode; import com.epmet.commons.tools.exception.EpmetException; import com.epmet.commons.tools.page.PageData; @@ -56,9 +55,9 @@ import com.epmet.dataaggre.service.opercustomize.CustomerFootBarService; import com.epmet.dto.IcResiUserDTO; import com.epmet.dto.UserBaseInfoDTO; import com.epmet.dto.form.DetailByTypeFormDTO; +import com.epmet.dto.form.GetStaffExistRoleFormDTO; import com.epmet.dto.form.SystemMsgFormDTO; import com.epmet.dto.result.DetailByTypeResultDTO; -import com.epmet.dto.form.GetStaffExistRoleFormDTO; import com.epmet.dto.result.NewUserRoleResultDTO; import com.epmet.dto.result.StaffRoleResultDTO; import com.epmet.feign.EpmetMessageOpenFeignClient; @@ -638,6 +637,7 @@ public class EpmetUserServiceImpl implements EpmetUserService { .eq(CustomerStaffEntity::getDelFlag,NumConstant.ZERO_STR); CustomerStaffEntity staffEntity = customerStaffDao.selectOne(queryWrapper); if (null == staffEntity) { + log.error(String.format("customer_staff is null staffId:%s",staffId)); return null; } CustomerStaffResultDTO result = ConvertUtils.sourceToTarget(staffEntity, CustomerStaffResultDTO.class); diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/AddIcNatFormDTO.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/AddIcNatFormDTO.java index b87f03d8d7..5fe8f73f31 100644 --- a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/AddIcNatFormDTO.java +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/AddIcNatFormDTO.java @@ -5,7 +5,6 @@ import com.fasterxml.jackson.annotation.JsonFormat; import lombok.Data; import javax.validation.constraints.NotBlank; -import javax.validation.constraints.NotNull; import java.io.Serializable; import java.util.ArrayList; import java.util.Date; @@ -110,6 +109,9 @@ public class AddIcNatFormDTO implements Serializable { private String customerId; private String staffId; private String client; - + /** + * 政府端:gov、居民端:resi、运营端:oper + */ + private String app; } diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/IcNatController.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/IcNatController.java index 512a43f7e9..b85f409d2b 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/IcNatController.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/IcNatController.java @@ -92,7 +92,8 @@ public class IcNatController implements ResultDataResolver { ValidatorUtils.validateEntity(formDTO, AddIcNatFormDTO.Nat.class); formDTO.setCustomerId(tokenDto.getCustomerId()); formDTO.setStaffId(tokenDto.getUserId()); - formDTO.setClient(tokenDto.getClient()); + // formDTO.setClient(tokenDto.getClient()); + formDTO.setApp(tokenDto.getApp()); icNucleinService.add(formDTO); return new Result(); } diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcNatServiceImpl.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcNatServiceImpl.java index b9cb1331f1..08fde1f5f9 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcNatServiceImpl.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcNatServiceImpl.java @@ -119,7 +119,7 @@ public class IcNatServiceImpl extends BaseServiceImpl imp if (null != icNatDTO && icNatDTO.getNatResult().equals(formDTO.getNatResult())) { throw new RenException(EpmetErrorCode.IC_NAT_IDCARD_NATTIME.getCode(), EpmetErrorCode.IC_NAT_IDCARD_NATTIME.getMsg()); } else if (null != icNatDTO && !icNatDTO.getNatResult().equals(formDTO.getNatResult())) { - if ("wxmp".equals(formDTO.getClient())) { + if (AppClientConstant.APP_RESI.equals(formDTO.getApp())) { throw new RenException(EpmetErrorCode.RESI_IC_NAT.getCode(), EpmetErrorCode.RESI_IC_NAT.getMsg()); } throw new RenException(EpmetErrorCode.IC_NAT.getCode(), EpmetErrorCode.IC_NAT.getMsg()); @@ -129,10 +129,6 @@ public class IcNatServiceImpl extends BaseServiceImpl imp if (null == agencyInfo) { throw new RenException(String.format("获取组织缓存信息失败%s", formDTO.getAgencyId())); } - CustomerStaffInfoCacheResult staffInfo = CustomerStaffRedis.getStaffInfo(formDTO.getCustomerId(), formDTO.getStaffId()); - if (null == staffInfo){ - throw new EpmetException(String.format("获取工作人员信息失败%s", formDTO.getStaffId())); - } ResiAndLocalResiResultDTO resiCount = icResiUserDao.getResiCount(formDTO.getAgencyId(), formDTO.getIdCard(), formDTO.getCustomerId()); //2.新增核酸基础信息数据 IcNatEntity entity = ConvertUtils.sourceToTarget(formDTO, IcNatEntity.class); @@ -146,8 +142,19 @@ public class IcNatServiceImpl extends BaseServiceImpl imp IcNatRelationEntity relationEntity = ConvertUtils.sourceToTarget(formDTO, IcNatRelationEntity.class); relationEntity.setIcNatId(entity.getId()); relationEntity.setIsLocalResiUser(resiCount.getIsLocal() == NumConstant.ZERO ? NumConstant.ZERO_STR : NumConstant.ONE_STR); - relationEntity.setAgencyId(staffInfo.getAgencyId()); - relationEntity.setPids(StringUtils.isNotBlank(staffInfo.getAgencyPIds()) ? staffInfo.getAgencyPIds() + ":" + staffInfo.getAgencyId() : staffInfo.getAgencyId()); + if(AppClientConstant.APP_GOV.equals(formDTO.getApp())){ + CustomerStaffInfoCacheResult staffInfo = CustomerStaffRedis.getStaffInfo(formDTO.getCustomerId(), formDTO.getStaffId()); + if (null == staffInfo){ + log.error(String.format("获取工作人员信息失败%s", formDTO.getStaffId())); + throw new EpmetException(String.format("获取工作人员信息失败%s", formDTO.getStaffId())); + } + relationEntity.setAgencyId(staffInfo.getAgencyId()); + relationEntity.setPids(StringUtils.isNotBlank(staffInfo.getAgencyPIds()) ? staffInfo.getAgencyPIds() + ":" + staffInfo.getAgencyId() : staffInfo.getAgencyId()); + }else{ + relationEntity.setAgencyId(formDTO.getAgencyId()); + AgencyInfoCache agencyInfoCache=CustomerOrgRedis.getAgencyInfo(formDTO.getAgencyId()); + relationEntity.setPids(StringUtils.isNotBlank(agencyInfoCache.getPids()) ? agencyInfoCache.getPids() + ":" + formDTO.getAgencyId() : formDTO.getAgencyId()); + } icNatRelationDao.insert(relationEntity); //3.新增通知表信息 From ebe86eb2ca68077900707fcf98998786d369a93d Mon Sep 17 00:00:00 2001 From: yinzuomei <576302893@qq.com> Date: Mon, 20 Feb 2023 14:07:39 +0800 Subject: [PATCH 7/7] =?UTF-8?q?epmetuser/tripreport/resi-save=E6=B3=A8?= =?UTF-8?q?=E9=87=8A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/java/com/epmet/dto/form/IcTripReportFormDTO.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/IcTripReportFormDTO.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/IcTripReportFormDTO.java index 65f289cd46..4ae7ae8b61 100644 --- a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/IcTripReportFormDTO.java +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/IcTripReportFormDTO.java @@ -183,7 +183,7 @@ public class IcTripReportFormDTO implements Serializable { /** * 交通方式,来源字典表(traffic_type) */ - @NotBlank(message = "返回方式不能为空", groups = {PcAddRequired.class, ResiUserRequired.class}) + // @NotBlank(message = "返回方式不能为空", groups = {PcAddRequired.class, ResiUserRequired.class}) private String trafficType; /** * 其他返回方式,交通方式为其他时此列需要有值 @@ -192,7 +192,7 @@ public class IcTripReportFormDTO implements Serializable { /** * 来源地详细信息 source_address字段的说明 */ - @NotBlank(message = "来自地区不能为空", groups = {PcAddRequired.class, ResiUserRequired.class}) + // @NotBlank(message = "来自地区不能为空", groups = {PcAddRequired.class, ResiUserRequired.class}) private String sourceDetailAddress; /** * 疫苗接种针次 (0针 1针 2针 3针)【小寨子】