Browse Source

Merge remote-tracking branch 'origin/dev_govgrid' into dev

dev_shibei_match
yinzuomei 5 years ago
parent
commit
2dc9d38aa2
  1. 3
      epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/controller/UserMessageController.java
  2. 2
      epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/service/UserMessageService.java
  3. 5
      epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/service/impl/UserMessageServiceImpl.java
  4. 34
      epmet-module/gov-grid/gov-grid-client/src/main/java/com/epmet/dto/form/CertifiedDetailFormDTO.java
  5. 72
      epmet-module/gov-grid/gov-grid-client/src/main/java/com/epmet/dto/result/CertifiedDetailResultDTO.java
  6. 14
      epmet-module/gov-grid/gov-grid-server/src/main/java/com/epmet/controller/ResiPartyMemberController.java
  7. 12
      epmet-module/gov-grid/gov-grid-server/src/main/java/com/epmet/feign/ResiPartymemberFeignClient.java
  8. 7
      epmet-module/gov-grid/gov-grid-server/src/main/java/com/epmet/feign/fallback/ResiPartymemberFeignClientFallBack.java
  9. 15
      epmet-module/gov-grid/gov-grid-server/src/main/java/com/epmet/service/ResiPartyMemberService.java
  10. 16
      epmet-module/gov-grid/gov-grid-server/src/main/java/com/epmet/service/impl/ResiPartyMemberServiceImpl.java
  11. 2
      epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerGridDao.xml
  12. 34
      epmet-module/resi-partymember/resi-partymember-client/src/main/java/com/epmet/resi/partymember/dto/partymember/form/CertifiedDetailFormDTO.java
  13. 77
      epmet-module/resi-partymember/resi-partymember-client/src/main/java/com/epmet/resi/partymember/dto/partymember/result/CertifiedDetailResultDTO.java
  14. 6
      epmet-module/resi-partymember/resi-partymember-server/pom.xml
  15. 3
      epmet-module/resi-partymember/resi-partymember-server/src/main/java/com/epmet/modules/feign/EpmetMessageFeignClient.java
  16. 12
      epmet-module/resi-partymember/resi-partymember-server/src/main/java/com/epmet/modules/feign/EpmetUserFeignClient.java
  17. 3
      epmet-module/resi-partymember/resi-partymember-server/src/main/java/com/epmet/modules/feign/fallback/EpmetMessageFeignClientFallback.java
  18. 7
      epmet-module/resi-partymember/resi-partymember-server/src/main/java/com/epmet/modules/feign/fallback/EpmetUserFeignClientFallBack.java
  19. 14
      epmet-module/resi-partymember/resi-partymember-server/src/main/java/com/epmet/modules/partymember/controller/PartymemberInfoController.java
  20. 11
      epmet-module/resi-partymember/resi-partymember-server/src/main/java/com/epmet/modules/partymember/dao/PartymemberInfoDao.java
  21. 13
      epmet-module/resi-partymember/resi-partymember-server/src/main/java/com/epmet/modules/partymember/service/PartymemberInfoService.java
  22. 31
      epmet-module/resi-partymember/resi-partymember-server/src/main/java/com/epmet/modules/partymember/service/impl/PartymemberInfoServiceImpl.java
  23. 2
      epmet-module/resi-partymember/resi-partymember-server/src/main/java/com/epmet/modules/warmhearted/constant/ResiWarmheartedConstant.java
  24. 21
      epmet-module/resi-partymember/resi-partymember-server/src/main/java/com/epmet/modules/warmhearted/service/impl/ResiWarmheartedApplyServiceImpl.java
  25. 23
      epmet-module/resi-partymember/resi-partymember-server/src/main/resources/mapper/partymember/PartymemberInfoDao.xml
  26. 21
      epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/CreatedTimeByUserIdFormDTO.java
  27. 21
      epmet-user/epmet-user-client/src/main/java/com/epmet/dto/result/CreatedTimeByUserIdResultDTO.java
  28. 13
      epmet-user/epmet-user-server/src/main/java/com/epmet/controller/UserController.java
  29. 12
      epmet-user/epmet-user-server/src/main/java/com/epmet/dao/UserDao.java
  30. 11
      epmet-user/epmet-user-server/src/main/java/com/epmet/service/UserService.java
  31. 16
      epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/UserServiceImpl.java
  32. 11
      epmet-user/epmet-user-server/src/main/resources/mapper/UserDao.xml

3
epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/controller/UserMessageController.java

@ -28,7 +28,6 @@ import com.epmet.commons.tools.validator.group.UpdateGroup;
import com.epmet.dto.UserMessageDTO;
import com.epmet.dto.form.MymessageFormDTO;
import com.epmet.dto.form.UserMessageFormDTO;
import com.epmet.entity.UserMessageEntity;
import com.epmet.excel.UserMessageExcel;
import com.epmet.service.UserMessageService;
import org.springframework.beans.factory.annotation.Autowired;
@ -141,7 +140,7 @@ public class UserMessageController {
* @Description 批量插入未读消息
**/
@PostMapping("saveusermessagelist")
public Result saveUserMessageList(@RequestBody List<UserMessageEntity> msgList) {
public Result saveUserMessageList(@RequestBody List<UserMessageFormDTO> msgList) {
return userMessageService.saveUserMessageList(msgList);
}
}

2
epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/service/UserMessageService.java

@ -134,5 +134,5 @@ public interface UserMessageService extends BaseService<UserMessageEntity> {
* @Author sun
* @Description 批量插入未读消息
**/
Result saveUserMessageList(List<UserMessageEntity> msgList);
Result saveUserMessageList(List<UserMessageFormDTO> msgList);
}

5
epmet-module/epmet-message/epmet-message-server/src/main/java/com/epmet/service/impl/UserMessageServiceImpl.java

@ -166,8 +166,9 @@ public class UserMessageServiceImpl extends BaseServiceImpl<UserMessageDao, User
}
@Override
public Result saveUserMessageList(List<UserMessageEntity> msgList) {
insertBatch(msgList);
public Result saveUserMessageList(List<UserMessageFormDTO> msgList) {
List<UserMessageEntity> entityList = ConvertUtils.sourceToTarget(msgList, UserMessageEntity.class);
insertBatch(entityList);
return new Result();
}
}

34
epmet-module/gov-grid/gov-grid-client/src/main/java/com/epmet/dto/form/CertifiedDetailFormDTO.java

@ -0,0 +1,34 @@
package com.epmet.dto.form;
import lombok.Data;
import javax.validation.constraints.NotBlank;
import java.io.Serializable;
/**
* @Auther zxc
* @Create 2020-04-27 13:33
* 已认证党员详情
*/
@Data
public class CertifiedDetailFormDTO implements Serializable {
private static final long serialVersionUID = 1L;
/**
* 党员认证信息表ID
*/
@NotBlank(message = "党员认证信息表ID不能为空")
private String partyMemberId;
/**
* 党员自动审核表ID
*/
private String autoId;
/**
* 党员人工审核表ID
*/
private String manualId;
}

72
epmet-module/gov-grid/gov-grid-client/src/main/java/com/epmet/dto/result/CertifiedDetailResultDTO.java

@ -0,0 +1,72 @@
package com.epmet.dto.result;
import lombok.Data;
import java.io.Serializable;
/**
* @Auther zxc
* @Create 2020-04-27 13:37
* 已认证党员详情
*/
@Data
public class CertifiedDetailResultDTO implements Serializable {
private static final long serialVersionUID = -1L;
/**
* 用户id
*/
private String userId;
/**
* 真实姓名
*/
private String realName;
/**
* 联系手机号
*/
private String mobile;
/**
* 身份证号
*/
private String idCard;
/**
* 认证网格XXX街道-XXX社区-XXX网格
*/
private String gridFullPath;
/**
* 认证方式自动认证auto人工认证manual
*/
private String certifyType;
/**
* 认证时间提交认证的时间
*/
private Long applyTime;
/**
* 注册时间进入本平台的时间
*/
private Long certifyTime;
/**
* 工作单位/所处街道
*/
private String extraOrganization;
/**
* 证明联系人
*/
private String contactPeople;
/**
* 证明联系人手机号
*/
private String contactMobile;
}

14
epmet-module/gov-grid/gov-grid-server/src/main/java/com/epmet/controller/ResiPartyMemberController.java

@ -5,7 +5,9 @@ import com.epmet.commons.tools.security.dto.TokenDto;
import com.epmet.commons.tools.utils.Result;
import com.epmet.dto.form.AuditedPartyMemberFormDTO;
import com.epmet.dto.form.AuditingPartyMemberFormDTO;
import com.epmet.dto.form.CertifiedDetailFormDTO;
import com.epmet.dto.form.CertifiedFormDTO;
import com.epmet.dto.result.CertifiedDetailResultDTO;
import com.epmet.dto.result.CertifiedResultDTO;
import com.epmet.dto.result.AuditedPartyMemberResultDTO;
import com.epmet.dto.result.AuditingPartyMemberResultDTO;
@ -73,6 +75,18 @@ public class ResiPartyMemberController {
return resiPartyMemberService.certifiedList(certifiedFormDTO);
}
/**
*
* @Description 已认证党员详情
* @param: formDTO
* @Author zxc
* @CreatedTime 2020/4/27 13:54
*/
@PostMapping(value = "/certifieddetail")
public Result<CertifiedDetailResultDTO> certifiedDetail(@RequestBody CertifiedDetailFormDTO formDTO){
return new Result<CertifiedDetailResultDTO>().ok(resiPartyMemberService.certifiedDetail(formDTO));
}
/**
* 审核党员
*

12
epmet-module/gov-grid/gov-grid-server/src/main/java/com/epmet/feign/ResiPartymemberFeignClient.java

@ -2,7 +2,9 @@ package com.epmet.feign;
import com.epmet.commons.tools.constant.ServiceConstant;
import com.epmet.commons.tools.utils.Result;
import com.epmet.dto.form.CertifiedDetailFormDTO;
import com.epmet.dto.form.CertifiedFormDTO;
import com.epmet.dto.result.CertifiedDetailResultDTO;
import com.epmet.dto.result.CertifiedResultDTO;
import com.epmet.feign.fallback.ResiPartymemberFeignClientFallBack;
import com.epmet.resi.partymember.dto.partymember.form.*;
@ -97,6 +99,16 @@ public interface ResiPartymemberFeignClient {
@PostMapping(value = "/resi/partymember/partymemberinfo/certified")
Result<List<CertifiedResultDTO>> certified(@RequestBody CertifiedFormDTO certifiedFormDTO);
/**
*
* @Description 已认证党员详情
* @param: formDTO
* @Author zxc
* @CreatedTime 2020/4/27 15:22
*/
@PostMapping(value = "/resi/partymember/partymemberinfo/certifieddetail")
Result<CertifiedDetailResultDTO> certifiedDetail(@RequestBody CertifiedDetailFormDTO formDTO);
/**
* 审核党员
*

7
epmet-module/gov-grid/gov-grid-server/src/main/java/com/epmet/feign/fallback/ResiPartymemberFeignClientFallBack.java

@ -3,7 +3,9 @@ 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.CertifiedDetailFormDTO;
import com.epmet.dto.form.CertifiedFormDTO;
import com.epmet.dto.result.CertifiedDetailResultDTO;
import com.epmet.dto.result.CertifiedResultDTO;
import com.epmet.feign.ResiPartymemberFeignClient;
import com.epmet.resi.partymember.dto.partymember.form.*;
@ -62,6 +64,11 @@ public class ResiPartymemberFeignClientFallBack implements ResiPartymemberFeignC
return ModuleUtils.feignConError(ServiceConstant.RESI_PARTYMEMBER_SERVER, "certified", certifiedFormDTO);
}
@Override
public Result<CertifiedDetailResultDTO> certifiedDetail(CertifiedDetailFormDTO formDTO) {
return ModuleUtils.feignConError(ServiceConstant.RESI_PARTYMEMBER_SERVER, "certifiedDetail", formDTO);
}
@Override
public Result manualConfirmResult(PartyMemberConfirmFromDTO fromDTO) {
return ModuleUtils.feignConError(ServiceConstant.RESI_PARTYMEMBER_SERVER, "manualConfirmResult", fromDTO);

15
epmet-module/gov-grid/gov-grid-server/src/main/java/com/epmet/service/ResiPartyMemberService.java

@ -1,14 +1,19 @@
package com.epmet.service;
import com.epmet.commons.tools.annotation.LoginUser;
import com.epmet.commons.tools.security.dto.TokenDto;
import com.epmet.commons.tools.utils.Result;
import com.epmet.dto.form.AuditedPartyMemberFormDTO;
import com.epmet.dto.form.AuditingPartyMemberFormDTO;
import com.epmet.dto.form.CertifiedDetailFormDTO;
import com.epmet.dto.form.CertifiedFormDTO;
import com.epmet.dto.result.CertifiedDetailResultDTO;
import com.epmet.dto.result.CertifiedResultDTO;
import java.util.List;
import com.epmet.dto.result.AuditedPartyMemberResultDTO;
import com.epmet.dto.result.AuditingPartyMemberResultDTO;
import org.springframework.web.bind.annotation.RequestBody;
import com.epmet.resi.partymember.dto.partymember.form.AuditingDetailFromDTO;
import com.epmet.resi.partymember.dto.partymember.form.AutoFailedDetailFromDTO;
import com.epmet.resi.partymember.dto.partymember.form.PartyMemberConfirmFromDTO;
@ -52,6 +57,16 @@ public interface ResiPartyMemberService {
*/
Result<List<CertifiedResultDTO>> certifiedList(CertifiedFormDTO certifiedFormDTO);
/**
*
* @Description 已认证党员详情
* @param: formDTO
* @Author zxc
* @CreatedTime 2020/4/27 14:23
*/
CertifiedDetailResultDTO certifiedDetail(CertifiedDetailFormDTO formDTO);
/**
* 人工审核结果
*

16
epmet-module/gov-grid/gov-grid-server/src/main/java/com/epmet/service/impl/ResiPartyMemberServiceImpl.java

@ -6,7 +6,9 @@ import com.epmet.commons.tools.utils.ConvertUtils;
import com.epmet.commons.tools.utils.Result;
import com.epmet.dto.form.AuditedPartyMemberFormDTO;
import com.epmet.dto.form.AuditingPartyMemberFormDTO;
import com.epmet.dto.form.CertifiedDetailFormDTO;
import com.epmet.dto.form.CertifiedFormDTO;
import com.epmet.dto.result.CertifiedDetailResultDTO;
import com.epmet.dto.result.CertifiedResultDTO;
import com.epmet.feign.ResiPartymemberFeignClient;
import com.epmet.dto.result.AuditedPartyMemberResultDTO;
@ -83,6 +85,20 @@ public class ResiPartyMemberServiceImpl implements ResiPartyMemberService {
return resiPartymemberFeignClient.certified(certifiedFormDTO);
}
/**
*
* @Description 已认证党员详情
* @param: formDTO
* @Author zxc
* @CreatedTime 2020/4/27 13:54
*/
@Override
public CertifiedDetailResultDTO certifiedDetail(CertifiedDetailFormDTO formDTO) {
CertifiedDetailResultDTO partyMemberDetail = resiPartymemberFeignClient.certifiedDetail(formDTO).getData();
return partyMemberDetail;
}
@Override
public Result manualConfirmResult(PartyMemberConfirmFromDTO fromDTO) {
return resiPartymemberFeignClient.manualConfirmResult(fromDTO);

2
epmet-module/gov-org/gov-org-server/src/main/resources/mapper/CustomerGridDao.xml

@ -93,7 +93,7 @@
</select>
<!-- -->
<!-- 根据gridId查询gridName -->
<select id="selectGridNameByGridId" parameterType="com.epmet.dto.form.SelectGridNameByGridIdFormDTO" resultType="com.epmet.dto.result.SelectGridNameByGridIdResultDTO">
SELECT
id AS gridId,

34
epmet-module/resi-partymember/resi-partymember-client/src/main/java/com/epmet/resi/partymember/dto/partymember/form/CertifiedDetailFormDTO.java

@ -0,0 +1,34 @@
package com.epmet.resi.partymember.dto.partymember.form;
import lombok.Data;
import javax.validation.constraints.NotBlank;
import java.io.Serializable;
/**
* @Auther zxc
* @Create 2020-04-27 13:33
* 已认证党员详情
*/
@Data
public class CertifiedDetailFormDTO implements Serializable {
private static final long serialVersionUID = 1L;
/**
* 党员认证信息表ID
*/
@NotBlank(message = "党员认证信息表ID不能为空")
private String partyMemberId;
/**
* 党员自动审核表ID
*/
private String autoId;
/**
* 党员人工审核表ID
*/
private String manualId;
}

77
epmet-module/resi-partymember/resi-partymember-client/src/main/java/com/epmet/resi/partymember/dto/partymember/result/CertifiedDetailResultDTO.java

@ -0,0 +1,77 @@
package com.epmet.resi.partymember.dto.partymember.result;
import lombok.Data;
import java.io.Serializable;
/**
* @Auther zxc
* @Create 2020-04-27 13:37
* 已认证党员详情
*/
@Data
public class CertifiedDetailResultDTO implements Serializable {
private static final long serialVersionUID = -1L;
/**
* 用户id
*/
private String userId;
/**
* 真实姓名(+)
*/
private String realName;
/**
* 联系手机号
*/
private String mobile;
/**
* 身份证号
*/
private String idCard;
/**
* 网格id
*/
private String gridId;
/**
* 认证网格XXX街道-XXX社区-XXX网格
*/
private String gridFullPath;
/**
* 认证方式自动认证auto人工认证manual
*/
private String certifyType;
/**
* 认证时间提交认证的时间
*/
private Long applyTime;
/**
* 注册时间进入本平台的时间
*/
private Long certifyTime;
/**
* 工作单位/所处街道
*/
private String extraOrganization;
/**
* 证明联系人
*/
private String contactPeople;
/**
* 证明联系人手机号
*/
private String contactMobile;
}

6
epmet-module/resi-partymember/resi-partymember-server/pom.xml

@ -93,12 +93,6 @@
<version>2.0.0</version>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>com.epmet</groupId>
<artifactId>epmet-message-server</artifactId>
<version>0.3.1</version>
<scope>compile</scope>
</dependency>
</dependencies>
<build>

3
epmet-module/resi-partymember/resi-partymember-server/src/main/java/com/epmet/modules/feign/EpmetMessageFeignClient.java

@ -3,7 +3,6 @@ package com.epmet.modules.feign;
import com.epmet.commons.tools.constant.ServiceConstant;
import com.epmet.commons.tools.utils.Result;
import com.epmet.dto.form.UserMessageFormDTO;
import com.epmet.entity.UserMessageEntity;
import com.epmet.modules.feign.fallback.EpmetMessageFeignClientFallback;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.http.MediaType;
@ -43,6 +42,6 @@ public interface EpmetMessageFeignClient {
* @Description 热心居民申请给网格长们发送消息
**/
@PostMapping(value = "message/usermessage/saveusermessagelist", consumes = MediaType.APPLICATION_JSON_UTF8_VALUE)
Result saveUserMessageList(List<UserMessageEntity> msgList);
Result saveUserMessageList(List<UserMessageFormDTO> msgList);
}

12
epmet-module/resi-partymember/resi-partymember-server/src/main/java/com/epmet/modules/feign/EpmetUserFeignClient.java

@ -4,14 +4,15 @@ import com.epmet.commons.tools.constant.ServiceConstant;
import com.epmet.commons.tools.utils.Result;
import com.epmet.dto.UserResiInfoDTO;
import com.epmet.dto.UserRoleDTO;
import com.epmet.dto.form.CreatedTimeByUserIdFormDTO;
import com.epmet.dto.form.StaffRoleFormDTO;
import com.epmet.dto.form.UserResiInfoFormDTO;
import com.epmet.dto.form.UserResiInfoListFormDTO;
import com.epmet.dto.result.CertifiedResultDTO;
import com.epmet.dto.result.CreatedTimeByUserIdResultDTO;
import com.epmet.dto.result.GovStaffRoleResultDTO;
import com.epmet.dto.result.UserResiInfoResultDTO;
import com.epmet.modules.feign.fallback.EpmetUserFeignClientFallBack;
import com.epmet.resi.partymember.dto.partymember.UserHeadPhotoDTO;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
@ -71,6 +72,15 @@ public interface EpmetUserFeignClient {
@PostMapping("/epmetuser/userwechat/selectuserheadphotobyuserid")
Result<List<CertifiedResultDTO>> selectUserHeadPhotoByUserId(List<CertifiedResultDTO> certifiedResultDTOS);
/**
*
* @Description 查询用户注册时间
* @Author zxc
* @CreatedTime 2020/4/27 16:14
*/
@PostMapping("/epmetuser/user/selectcreatedtimebyuserid")
Result<CreatedTimeByUserIdResultDTO> createdTimeByUserId(@RequestBody CreatedTimeByUserIdFormDTO formDTO);
/**
* 根据机构Id查询机构下是网格长角色的用户
* @param staffRoleFormDTO

3
epmet-module/resi-partymember/resi-partymember-server/src/main/java/com/epmet/modules/feign/fallback/EpmetMessageFeignClientFallback.java

@ -4,7 +4,6 @@ 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.UserMessageFormDTO;
import com.epmet.entity.UserMessageEntity;
import com.epmet.modules.feign.EpmetMessageFeignClient;
import org.springframework.stereotype.Component;
@ -28,7 +27,7 @@ public class EpmetMessageFeignClientFallback implements EpmetMessageFeignClient
}
@Override
public Result saveUserMessageList(List<UserMessageEntity> msgList) {
public Result saveUserMessageList(List<UserMessageFormDTO> msgList) {
return ModuleUtils.feignConError(ServiceConstant.EPMET_MESSAGE_SERVER, "saveUserMessageList", msgList);
}

7
epmet-module/resi-partymember/resi-partymember-server/src/main/java/com/epmet/modules/feign/fallback/EpmetUserFeignClientFallBack.java

@ -5,10 +5,12 @@ import com.epmet.commons.tools.utils.ModuleUtils;
import com.epmet.commons.tools.utils.Result;
import com.epmet.dto.UserResiInfoDTO;
import com.epmet.dto.UserRoleDTO;
import com.epmet.dto.form.CreatedTimeByUserIdFormDTO;
import com.epmet.dto.form.StaffRoleFormDTO;
import com.epmet.dto.form.UserResiInfoFormDTO;
import com.epmet.dto.form.UserResiInfoListFormDTO;
import com.epmet.dto.result.CertifiedResultDTO;
import com.epmet.dto.result.CreatedTimeByUserIdResultDTO;
import com.epmet.dto.result.GovStaffRoleResultDTO;
import com.epmet.dto.result.UserResiInfoResultDTO;
import com.epmet.modules.feign.EpmetUserFeignClient;
@ -48,6 +50,11 @@ public class EpmetUserFeignClientFallBack implements EpmetUserFeignClient {
return ModuleUtils.feignConError(ServiceConstant.EPMET_USER_SERVER, "selectUserHeadPhotoByUserId", certifiedResultDTOS);
}
@Override
public Result<CreatedTimeByUserIdResultDTO> createdTimeByUserId(CreatedTimeByUserIdFormDTO formDTO) {
return ModuleUtils.feignConError(ServiceConstant.EPMET_USER_SERVER, "createdTimeByUserId", formDTO);
}
@Override
public Result<List<GovStaffRoleResultDTO>> getStaffsInRole(StaffRoleFormDTO staffRoleFormDTO) {
return ModuleUtils.feignConError(ServiceConstant.EPMET_USER_SERVER, "getStaffsInRole", staffRoleFormDTO);

14
epmet-module/resi-partymember/resi-partymember-server/src/main/java/com/epmet/modules/partymember/controller/PartymemberInfoController.java

@ -29,7 +29,9 @@ import com.epmet.dto.result.CertifiedResultDTO;
import com.epmet.modules.partymember.excel.PartymemberInfoExcel;
import com.epmet.modules.partymember.service.PartymemberInfoService;
import com.epmet.resi.partymember.dto.partymember.PartymemberInfoDTO;
import com.epmet.resi.partymember.dto.partymember.form.CertifiedDetailFormDTO;
import com.epmet.resi.partymember.dto.partymember.form.CertifiedFormDTO;
import com.epmet.resi.partymember.dto.partymember.result.CertifiedDetailResultDTO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
@ -104,4 +106,16 @@ public class PartymemberInfoController {
return new Result<List<CertifiedResultDTO>>().ok(partymemberInfoService.certified(certifiedFormDTO));
}
/**
*
* @Description 查询已认证党员详情
* @param: formDTO
* @Author zxc
* @CreatedTime 2020/4/27 15:26
*/
@PostMapping("certifieddetail")
public Result<CertifiedDetailResultDTO> certifieddetail(@RequestBody CertifiedDetailFormDTO formDTO){
return new Result<CertifiedDetailResultDTO>().ok(partymemberInfoService.certifiedDetail(formDTO));
}
}

11
epmet-module/resi-partymember/resi-partymember-server/src/main/java/com/epmet/modules/partymember/dao/PartymemberInfoDao.java

@ -21,7 +21,9 @@ import com.epmet.commons.mybatis.dao.BaseDao;
import com.epmet.dto.result.CertifiedResultDTO;
import com.epmet.modules.partymember.entity.PartymemberInfoEntity;
import com.epmet.resi.partymember.dto.partymember.PartymemberInfoDTO;
import com.epmet.resi.partymember.dto.partymember.form.CertifiedDetailFormDTO;
import com.epmet.resi.partymember.dto.partymember.form.CertifiedFormDTO;
import com.epmet.resi.partymember.dto.partymember.result.CertifiedDetailResultDTO;
import org.apache.ibatis.annotations.Mapper;
import java.util.List;
@ -56,4 +58,13 @@ public interface PartymemberInfoDao extends BaseDao<PartymemberInfoEntity> {
*/
List<CertifiedResultDTO> selectCertifiedList(CertifiedFormDTO certifiedFormDTO);
/**
*
* @Description 查询已认证党员详情
* @param: formDTO
* @Author zxc
* @CreatedTime 2020/4/27 15:30
*/
CertifiedDetailResultDTO certifiedDetail(CertifiedDetailFormDTO formDTO);
}

13
epmet-module/resi-partymember/resi-partymember-server/src/main/java/com/epmet/modules/partymember/service/PartymemberInfoService.java

@ -19,10 +19,14 @@ package com.epmet.modules.partymember.service;
import com.epmet.commons.mybatis.service.BaseService;
import com.epmet.commons.tools.page.PageData;
import com.epmet.commons.tools.utils.Result;
import com.epmet.dto.result.CertifiedResultDTO;
import com.epmet.modules.partymember.entity.PartymemberInfoEntity;
import com.epmet.resi.partymember.dto.partymember.PartymemberInfoDTO;
import com.epmet.resi.partymember.dto.partymember.form.CertifiedDetailFormDTO;
import com.epmet.resi.partymember.dto.partymember.form.CertifiedFormDTO;
import com.epmet.resi.partymember.dto.partymember.result.CertifiedDetailResultDTO;
import org.springframework.web.bind.annotation.RequestBody;
import java.util.List;
import java.util.Map;
@ -124,4 +128,13 @@ public interface PartymemberInfoService extends BaseService<PartymemberInfoEntit
*/
List<CertifiedResultDTO> certified(CertifiedFormDTO certifiedFormDTO);
/**
*
* @Description 查询已认证党员详情
* @param: formDTO
* @Author zxc
* @CreatedTime 2020/4/27 15:27
*/
CertifiedDetailResultDTO certifiedDetail(CertifiedDetailFormDTO formDTO);
}

31
epmet-module/resi-partymember/resi-partymember-server/src/main/java/com/epmet/modules/partymember/service/impl/PartymemberInfoServiceImpl.java

@ -25,7 +25,9 @@ import com.epmet.commons.tools.constant.NumConstant;
import com.epmet.commons.tools.page.PageData;
import com.epmet.commons.tools.utils.ConvertUtils;
import com.epmet.commons.tools.utils.Result;
import com.epmet.dto.form.CreatedTimeByUserIdFormDTO;
import com.epmet.dto.result.CertifiedResultDTO;
import com.epmet.dto.result.CreatedTimeByUserIdResultDTO;
import com.epmet.dto.result.SelectGridNameByGridIdResultDTO;
import com.epmet.modules.feign.EpmetUserFeignClient;
import com.epmet.modules.feign.GovOrgFeignClient;
@ -34,7 +36,9 @@ import com.epmet.modules.partymember.entity.PartymemberInfoEntity;
import com.epmet.modules.partymember.redis.PartymemberInfoRedis;
import com.epmet.modules.partymember.service.PartymemberInfoService;
import com.epmet.resi.partymember.dto.partymember.PartymemberInfoDTO;
import com.epmet.resi.partymember.dto.partymember.form.CertifiedDetailFormDTO;
import com.epmet.resi.partymember.dto.partymember.form.CertifiedFormDTO;
import com.epmet.resi.partymember.dto.partymember.result.CertifiedDetailResultDTO;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
@ -151,5 +155,32 @@ public class PartymemberInfoServiceImpl extends BaseServiceImpl<PartymemberInfoD
return listResult.getData();
}
/**
*
* @Description 查询已认证党员详情
* @param: formDTO
* @Author zxc
* @CreatedTime 2020/4/27 15:26
*/
@Override
public CertifiedDetailResultDTO certifiedDetail(CertifiedDetailFormDTO formDTO) {
CertifiedDetailResultDTO certifiedDetail = partyMemberInfoDao.certifiedDetail(formDTO);
if (certifiedDetail==null){
return new CertifiedDetailResultDTO();
}
certifiedDetail.setApplyTime(certifiedDetail.getApplyTime() * 1000L);//时间戳转换毫秒级
CreatedTimeByUserIdFormDTO time = new CreatedTimeByUserIdFormDTO();
time.setUserId(certifiedDetail.getUserId());
//查询用户注册时间
Result<CreatedTimeByUserIdResultDTO> registerTime = epmetUserFeignClient.createdTimeByUserId(time);
certifiedDetail.setCertifyTime(registerTime.getData().getRegisterTime());
CertifiedFormDTO certifiedFormDTO = new CertifiedFormDTO();
certifiedFormDTO.setGridId(certifiedDetail.getGridId());
//查询网格名称
Result<SelectGridNameByGridIdResultDTO> gridName = govOrgFeignClient.selectGridNameByGridId(certifiedFormDTO);
certifiedDetail.setGridFullPath(gridName.getData().getGridName());
return certifiedDetail;
}
}

2
epmet-module/resi-partymember/resi-partymember-server/src/main/java/com/epmet/constant/ResiWarmheartedConstant.java → epmet-module/resi-partymember/resi-partymember-server/src/main/java/com/epmet/modules/warmhearted/constant/ResiWarmheartedConstant.java

@ -1,4 +1,4 @@
package com.epmet.constant;
package com.epmet.modules.warmhearted.constant;
/**
* @author sun

21
epmet-module/resi-partymember/resi-partymember-server/src/main/java/com/epmet/modules/warmhearted/service/impl/ResiWarmheartedApplyServiceImpl.java

@ -38,7 +38,6 @@ import com.epmet.dto.form.*;
import com.epmet.dto.result.AgencyAndStaffsResultDTO;
import com.epmet.dto.result.GovStaffRoleResultDTO;
import com.epmet.dto.result.UserResiInfoResultDTO;
import com.epmet.entity.UserMessageEntity;
import com.epmet.modules.feign.EpmetMessageFeignClient;
import com.epmet.modules.feign.EpmetUserFeignClient;
import com.epmet.modules.feign.GovOrgFeignClient;
@ -257,19 +256,19 @@ public class ResiWarmheartedApplyServiceImpl extends BaseServiceImpl<ResiWarmhea
Result<List<GovStaffRoleResultDTO>> resultList = epmetUserFeignClient.getStaffsInRole(staffRoleFormDTO);
List<GovStaffRoleResultDTO> roleList = resultList.getData();
//3:遍历找出当前网格的所有网格长并给网格长发消息
List<UserMessageEntity> msgList = new ArrayList<>();
List<UserMessageFormDTO> msgList = new ArrayList<>();
staffList.forEach(staff->{
roleList.forEach(role->{
if(staff.getUserId().equals(role.getStaffId())){
UserMessageEntity msgEntity = new UserMessageEntity();
msgEntity.setCustomerId(formDTO.getCustomerId());
msgEntity.setGridId(formDTO.getGridId());
msgEntity.setUserId(staff.getUserId());
msgEntity.setApp(formDTO.getApp());
msgEntity.setTitle(ResiWarmUserMessageConstant.GROUP_TITLE);
msgEntity.setMessageContent(formDTO.getMessageText());
msgEntity.setReadFlag(ReadFlagConstant.UN_READ);
msgList.add(msgEntity);
UserMessageFormDTO msgDTO = new UserMessageFormDTO();
msgDTO.setCustomerId(formDTO.getCustomerId());
msgDTO.setGridId(formDTO.getGridId());
msgDTO.setUserId(staff.getUserId());
msgDTO.setApp(formDTO.getApp());
msgDTO.setTitle(ResiWarmUserMessageConstant.GROUP_TITLE);
msgDTO.setMessageContent(formDTO.getMessageText());
msgDTO.setReadFlag(ReadFlagConstant.UN_READ);
msgList.add(msgDTO);
}
});
});

23
epmet-module/resi-partymember/resi-partymember-server/src/main/resources/mapper/partymember/PartymemberInfoDao.xml

@ -78,5 +78,28 @@
LIMIT #{pageNo},#{pageSize}
</select>
<!-- 查询已认证党员详情 -->
<select id="certifiedDetail" resultType="com.epmet.resi.partymember.dto.partymember.result.CertifiedDetailResultDTO">
SELECT
pi.user_id AS userId,
CONCAT( pi.surname, pi.NAME ) AS realName,
pi.mobile,
pi.id_card AS idCard,
grid_id AS gridId,
CASE
WHEN ( pi.confirm_result = 'auto_confirm_success' ) THEN 'auto'
WHEN ( pi.confirm_result = 'approved' ) THEN 'manual'
END AS certifyType,
UNIX_TIMESTAMP(pi.created_time) AS applyTime,
organization_type AS extraOrganization,
extra_certifier_name AS contactPeople,
extra_certifier_mobile AS contactMobile
FROM
partymember_info pi
WHERE
pi.id = #{partyMemberId}
AND pi.del_flag = 0
AND pi.confirm_result IN ( 'auto_confirm_success', 'approved' )
</select>
</mapper>

21
epmet-user/epmet-user-client/src/main/java/com/epmet/dto/form/CreatedTimeByUserIdFormDTO.java

@ -0,0 +1,21 @@
package com.epmet.dto.form;
import lombok.Data;
import java.io.Serializable;
/**
* @Auther zxc
* @Create 2020-04-27 16:08
*/
@Data
public class CreatedTimeByUserIdFormDTO implements Serializable {
private static final long serialVersionUID = 1L;
/**
* 用户id
*/
private String userId;
}

21
epmet-user/epmet-user-client/src/main/java/com/epmet/dto/result/CreatedTimeByUserIdResultDTO.java

@ -0,0 +1,21 @@
package com.epmet.dto.result;
import lombok.Data;
import java.io.Serializable;
/**
* @Auther zxc
* @Create 2020-04-27 16:08
*/
@Data
public class CreatedTimeByUserIdResultDTO implements Serializable {
private static final long serialVersionUID = -1L;
/**
* 注册时间 (empet_user库下的user表中的 created_time)
*/
private Long registerTime;
}

13
epmet-user/epmet-user-server/src/main/java/com/epmet/controller/UserController.java

@ -8,9 +8,11 @@ import com.epmet.commons.tools.validator.group.AddGroup;
import com.epmet.commons.tools.validator.group.DefaultGroup;
import com.epmet.dto.UserDTO;
import com.epmet.dto.UserWechatDTO;
import com.epmet.dto.form.CreatedTimeByUserIdFormDTO;
import com.epmet.dto.form.PasswordLoginUserInfoFormDTO;
import com.epmet.dto.form.WxLoginUserInfoFormDTO;
import com.epmet.dto.form.WxUserInfoFormDTO;
import com.epmet.dto.result.CreatedTimeByUserIdResultDTO;
import com.epmet.dto.result.PasswordLoginUserInfoResultDTO;
import com.epmet.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
@ -86,4 +88,15 @@ public class UserController {
return userService.updateWxUserInfo(wxUserInfoFormDTO);
}
/**
*
* @Description 查询用户注册时间
* @Author zxc
* @CreatedTime 2020/4/27 16:14
*/
@PostMapping("selectcreatedtimebyuserid")
public Result<CreatedTimeByUserIdResultDTO> createdTimeByUserId(@RequestBody CreatedTimeByUserIdFormDTO formDTO){
return new Result<CreatedTimeByUserIdResultDTO>().ok(userService.createdTimeByUserId(formDTO));
}
}

12
epmet-user/epmet-user-server/src/main/java/com/epmet/dao/UserDao.java

@ -1,6 +1,8 @@
package com.epmet.dao;
import com.epmet.commons.mybatis.dao.BaseDao;
import com.epmet.dto.form.CreatedTimeByUserIdFormDTO;
import com.epmet.dto.result.CreatedTimeByUserIdResultDTO;
import com.epmet.dto.result.PasswordLoginUserInfoResultDTO;
import com.epmet.entity.UserEntity;
import org.apache.ibatis.annotations.Mapper;
@ -23,4 +25,14 @@ public interface UserDao extends BaseDao<UserEntity> {
PasswordLoginUserInfoResultDTO selectOperUserByPhone(String phone);
/**
*
* @Description 查询用户注册时间
* @param: formDTO
* @Author zxc
* @CreatedTime 2020/4/27 16:17
*/
CreatedTimeByUserIdResultDTO createdTimeByUserId(CreatedTimeByUserIdFormDTO formDTO);
}

11
epmet-user/epmet-user-server/src/main/java/com/epmet/service/UserService.java

@ -5,9 +5,11 @@ import com.epmet.commons.tools.page.PageData;
import com.epmet.commons.tools.utils.Result;
import com.epmet.dto.UserDTO;
import com.epmet.dto.UserWechatDTO;
import com.epmet.dto.form.CreatedTimeByUserIdFormDTO;
import com.epmet.dto.form.PasswordLoginUserInfoFormDTO;
import com.epmet.dto.form.WxLoginUserInfoFormDTO;
import com.epmet.dto.form.WxUserInfoFormDTO;
import com.epmet.dto.result.CreatedTimeByUserIdResultDTO;
import com.epmet.dto.result.PasswordLoginUserInfoResultDTO;
import com.epmet.entity.UserEntity;
@ -55,4 +57,13 @@ public interface UserService extends BaseService<UserEntity> {
* @Description 居民端个人信息-同步用户微信信息
**/
Result updateWxUserInfo(WxUserInfoFormDTO wxUserInfoFormDTO);
/**
*
* @Description 查询用户注册时间
* @param: formDTO
* @Author zxc
* @CreatedTime 2020/4/27 16:14
*/
CreatedTimeByUserIdResultDTO createdTimeByUserId(CreatedTimeByUserIdFormDTO formDTO);
}

16
epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/UserServiceImpl.java

@ -8,9 +8,11 @@ import com.epmet.dao.UserDao;
import com.epmet.dao.UserWechatDao;
import com.epmet.dto.UserDTO;
import com.epmet.dto.UserWechatDTO;
import com.epmet.dto.form.CreatedTimeByUserIdFormDTO;
import com.epmet.dto.form.PasswordLoginUserInfoFormDTO;
import com.epmet.dto.form.WxLoginUserInfoFormDTO;
import com.epmet.dto.form.WxUserInfoFormDTO;
import com.epmet.dto.result.CreatedTimeByUserIdResultDTO;
import com.epmet.dto.result.PasswordLoginUserInfoResultDTO;
import com.epmet.entity.UserEntity;
import com.epmet.entity.UserWechatEntity;
@ -109,4 +111,18 @@ public class UserServiceImpl extends BaseServiceImpl<UserDao, UserEntity> implem
userWechatDao.updateByUserId(userWechatDTO);
return new Result();
}
/**
*
* @Description 查询用户注册时间
* @param: formDTO
* @Author zxc
* @CreatedTime 2020/4/27 16:14
*/
@Override
public CreatedTimeByUserIdResultDTO createdTimeByUserId(CreatedTimeByUserIdFormDTO formDTO) {
CreatedTimeByUserIdResultDTO registerTime = baseDao.createdTimeByUserId(formDTO);
registerTime.setRegisterTime(registerTime.getRegisterTime() * 1000L);
return registerTime;
}
}

11
epmet-user/epmet-user-server/src/main/resources/mapper/UserDao.xml

@ -15,4 +15,15 @@
AND ou.PHONE = #{phone}
</select>
<!-- 查询用户注册时间 -->
<select id="createdTimeByUserId" resultType="com.epmet.dto.result.CreatedTimeByUserIdResultDTO">
SELECT
UNIX_TIMESTAMP( created_time ) AS registerTime
FROM
user
WHERE
id = #{userId}
AND del_flag = 0
</select>
</mapper>

Loading…
Cancel
Save