Browse Source

合并

master
qushutong 2 years ago
parent
commit
07fb6c5706
  1. 156
      esua-epdc/epdc-module/epdc-user/epdc-user-client/src/main/java/com/elink/esua/epdc/user/dto/PartyMembersDTO.java
  2. 31
      esua-epdc/epdc-module/epdc-user/epdc-user-client/src/main/java/com/elink/esua/epdc/user/dto/party/FlowPartyDTO.java
  3. 5
      esua-epdc/epdc-module/epdc-user/epdc-user-client/src/main/java/com/elink/esua/epdc/user/dto/party/ReportPartyDTO.java
  4. 4
      esua-epdc/epdc-module/epdc-user/epdc-user-server/src/main/java/com/elink/esua/epdc/party/controller/ReportPartyController.java
  5. 58
      esua-epdc/epdc-module/epdc-user/epdc-user-server/src/main/java/com/elink/esua/epdc/party/entity/FlowPartyEntity.java
  6. 2
      esua-epdc/epdc-module/epdc-user/epdc-user-server/src/main/java/com/elink/esua/epdc/party/entity/ReportPartyEntity.java
  7. 12
      esua-epdc/epdc-module/epdc-user/epdc-user-server/src/main/java/com/elink/esua/epdc/party/service/impl/FlowPartyServiceImpl.java
  8. 16
      esua-epdc/epdc-module/epdc-user/epdc-user-server/src/main/java/com/elink/esua/epdc/party/service/impl/ReportPartyServiceImpl.java

156
esua-epdc/epdc-module/epdc-user/epdc-user-client/src/main/java/com/elink/esua/epdc/user/dto/PartyMembersDTO.java

@ -31,114 +31,120 @@ import java.util.Date;
*/
@Data
public class PartyMembersDTO implements Serializable {
private static final long serialVersionUID = 1L;
private String tagIds;
private static final long serialVersionUID = 8381758784113388927L;
private String[] tagIdsNew;
private String tagIds;
private String tagName;
private String[] tagIdsNew;
private String id;
private String tagName;
private String realName;
private String id;
private String mobile;
private String realName;
private String identityNo;
private String mobile;
private String post;
private String identityNo;
private String postValue;
private String post;
private String cadreFlag;
private String postValue;
private String registFlag;
private String cadreFlag;
private String registName;
private String registFlag;
private Date registTime;
private String registName;
private String streetName;
private Date registTime;
private Long streetId;
private String streetName;
private String communityName;
private Long streetId;
private Long communityId;
private String communityName;
private String gridName;
private Long communityId;
private Long gridId;
private String gridName;
private long deptId;
private Long gridId;
private Integer revision;
private long deptId;
private String createdBy;
private Integer revision;
private Date createdTime;
private String createdBy;
private String updatedBy;
private Date createdTime;
private Date updatedTime;
private String updatedBy;
private String delFlag;
private Date updatedTime;
private String allDeptNames;
private String delFlag;
private String deptStrIds;
private String allDeptNames;
private String[] allDeptIds;
private String deptStrIds;
private String partyOrganization;
private String[] allDeptIds;
/**
* 父所有部门ID
*/
private String parentDeptIds;
/**
* 父所有部门名称
*/
private String parentDeptNames;
/**
* 所有部门ID
*/
private String allDeptIdsStr;
private String partyOrganization;
/**
* 入党时间
*/
private Date joinDate;
/**
* 职务字典项
*/
private String position;
/**
* 父所有部门ID
*/
private String parentDeptIds;
/**
* 父所有部门名称
*/
private String parentDeptNames;
/**
* 所有部门ID
*/
private String allDeptIdsStr;
/**
* 职务名称
*/
private String positionName;
/**
* 是否是流动性党员 0否1是
*/
private String isMobility;
/**
* 流动党员证号
*/
private String mobilityNum;
/**
* 文化程度字典项
*/
private String education;
/**
* 备注
*/
private String note;
/**
* 入党时间
*/
private Date joinDate;
/**
* 职务字典项
*/
private String position;
/**
* 地址
*/
private String address;
/**
* 职务名称
*/
private String positionName;
/**
* 是否是流动性党员 0否1是
*/
private String isMobility;
/**
* 流动党员证号
*/
private String mobilityNum;
/**
* 文化程度字典项
*/
private String education;
/**
* 备注
*/
private String note;
/**
* 地址
*/
private String address;
/**
* 党员类别1商户党员2企业党员3机关党员4居民党员
*/
private Integer partyType;
}

31
esua-epdc/epdc-module/epdc-user/epdc-user-client/src/main/java/com/elink/esua/epdc/user/dto/party/FlowPartyDTO.java

@ -31,49 +31,60 @@ import java.io.Serializable;
@Data
public class FlowPartyDTO implements Serializable {
private static final long serialVersionUID = 1L;
private static final long serialVersionUID = -6292115918565727132L;
/**
* 流动党员ID
*/
private String id;
private String id;
/**
* 党员姓名
*/
private String name;
private String name;
/**
* 身份证号码
*/
private String idCard;
private String idCard;
/**
* 联系电话
*/
private String mobile;
private String mobile;
/**
* 是否自由职业 0 1
*/
private Integer freelance;
private Integer freelance;
/**
* 是否党员 0 1
*/
private Integer party;
/**
* 入党时间
*/
private String partyDate;
/**
* 现工作单位
*/
private String workUnit;
private String workUnit;
/**
* 工作单位地址
*/
private String workAddr;
private String workAddr;
/**
* 居住网格id
*/
private Long deptId;
private Long deptId;
private String[] allDeptIds;
private String[] allDeptIds;
/***
*父所有部门

5
esua-epdc/epdc-module/epdc-user/epdc-user-client/src/main/java/com/elink/esua/epdc/user/dto/party/ReportPartyDTO.java

@ -161,6 +161,11 @@ public class ReportPartyDTO implements Serializable {
@NotBlank(message = "包联单位不能为空")
private String[] couplingCommunity;
/**
* 包联社区名称
*/
private String couplingCommunityName;
/**
* 报到时间
*/

4
esua-epdc/epdc-module/epdc-user/epdc-user-server/src/main/java/com/elink/esua/epdc/party/controller/ReportPartyController.java

@ -72,7 +72,7 @@ public class ReportPartyController {
if (StringUtils.isNotEmpty(dto.getIdCard()) && StringUtils.isNotEmpty(dto.getName())) {
int sum = reportPartyService.findByIdCardAndName(dto.getIdCard(),dto.getName());
if(sum == 1){
throw new RenException("您已经报到,请等待审核!");
throw new RenException("您已经报到,无需再次报道!");
}
}
reportPartyService.save(dto);
@ -86,7 +86,7 @@ public class ReportPartyController {
if (StringUtils.isNotEmpty(dto.getIdCard()) && StringUtils.isNotEmpty(dto.getName())) {
int sum = reportPartyService.findByIdCardAndName(dto.getIdCard(),dto.getName());
if(sum == 1){
throw new RenException("您已经报到,请等待审核!");
throw new RenException("您已经报到,无需再次报道!");
}
}
reportPartyService.update(dto);

58
esua-epdc/epdc-module/epdc-user/epdc-user-server/src/main/java/com/elink/esua/epdc/party/entity/FlowPartyEntity.java

@ -22,6 +22,8 @@ import com.elink.esua.epdc.commons.mybatis.entity.DeptScope;
import lombok.Data;
import lombok.EqualsAndHashCode;
import java.util.Date;
/**
* 流动党员报道表
*
@ -29,62 +31,72 @@ import lombok.EqualsAndHashCode;
* @since v1.0.0 2023-06-30
*/
@Data
@EqualsAndHashCode(callSuper=false)
@EqualsAndHashCode(callSuper = false)
@TableName("flow_party")
public class FlowPartyEntity extends DeptScope {
private static final long serialVersionUID = 6728231988052417884L;
private static final long serialVersionUID = 6728231988052417884L;
/**
/**
* 党员姓名
*/
private String name;
private String name;
/**
* 身份证号码
*/
private String idCard;
private String idCard;
/**
* 联系电话
*/
private String mobile;
private String mobile;
/**
* 是否自由职业 0 1
*/
private Integer freelance;
private Integer freelance;
/**
* 是否党员 0 1
*/
private Integer party;
/**
* 入党时间
*/
private Date partyDate;
/**
* 现工作单位
*/
private String workUnit;
private String workUnit;
/**
* 工作单位地址
*/
private String workAddr;
private String workAddr;
/**
* 居住网格id
*/
private String deptId;
private String deptId;
private String allDeptIds;
private String allDeptIds;
/**
* 审核状态 0待审核 1审核通过
*/
private Integer status;
/**
* 审核状态 0待审核 1审核通过
*/
private Integer status;
/**
* 现属党支部
*/
private String partyName;
/**
* 现属党支部
*/
private String partyName;
/**
* 审核意见
*/
private String examineMsg;
/**
* 审核意见
*/
private String examineMsg;
}

2
esua-epdc/epdc-module/epdc-user/epdc-user-server/src/main/java/com/elink/esua/epdc/party/entity/ReportPartyEntity.java

@ -22,8 +22,6 @@ import com.elink.esua.epdc.commons.mybatis.entity.DeptScope;
import lombok.Data;
import lombok.EqualsAndHashCode;
import java.util.Date;
/**
* 党员报道
*

12
esua-epdc/epdc-module/epdc-user/epdc-user-server/src/main/java/com/elink/esua/epdc/party/service/impl/FlowPartyServiceImpl.java

@ -17,6 +17,7 @@
package com.elink.esua.epdc.party.service.impl;
import cn.hutool.core.date.DateUtil;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.elink.esua.epdc.commons.mybatis.service.impl.BaseServiceImpl;
@ -85,12 +86,16 @@ public class FlowPartyServiceImpl extends BaseServiceImpl<FlowPartyDao, FlowPart
String idCard = (String) params.get(FieldConstant.ID_CARD_HUMP);
String mobile = (String) params.get(FieldConstant.MOBILE_HUMP);
String status = (String) params.get("status");
String deptId = (String) params.get("deptId");
String party = (String) params.get("party");
QueryWrapper<FlowPartyEntity> wrapper = new QueryWrapper<>();
wrapper.eq(StringUtils.isNotBlank(id), FieldConstant.ID, id);
wrapper.like(StringUtils.isNotBlank(name), FieldConstant.NAME_HUMP, name);
wrapper.like(StringUtils.isNotBlank(idCard), FieldConstant.ID_CARD, idCard);
wrapper.like(StringUtils.isNotBlank(mobile), FieldConstant.MOBILE_HUMP, mobile);
wrapper.likeLeft(StringUtils.isNotBlank(deptId), "PARENT_DEPT_IDS", deptId);
wrapper.eq(StringUtils.isNotBlank(status), "STATUS", status);
wrapper.eq(StringUtils.isNotBlank(party), "PARTY", party);
return wrapper;
}
@ -112,7 +117,7 @@ public class FlowPartyServiceImpl extends BaseServiceImpl<FlowPartyDao, FlowPart
setDeptId(dto);
}
FlowPartyEntity entity = ConvertUtils.sourceToTarget(dto, FlowPartyEntity.class);
Result<ParentAndAllDeptDTO> parentResult = null;
Result<ParentAndAllDeptDTO> parentResult;
if (dto.getAllDeptIds() != null && dto.getAllDeptIds().length > 1) {
entity.setDeptId(dto.getAllDeptIds()[dto.getAllDeptIds().length - 1]);
parentResult = adminFeignClient.getParentAndAllDept(dto.getAllDeptIds()[dto.getAllDeptIds().length - 1]);
@ -128,6 +133,9 @@ public class FlowPartyServiceImpl extends BaseServiceImpl<FlowPartyDao, FlowPart
entity.setParentDeptIds(deptDTO.getParentDeptIds());
entity.setParentDeptNames(deptDTO.getParentDeptNames());
}
if (StringUtils.isNotEmpty(dto.getPartyDate())) {
entity.setPartyDate(DateUtil.parseDate(dto.getPartyDate()));
}
entity.setStatus(0);
insert(entity);
}
@ -156,7 +164,7 @@ public class FlowPartyServiceImpl extends BaseServiceImpl<FlowPartyDao, FlowPart
entity.setParentDeptIds(deptDTO.getParentDeptIds());
entity.setParentDeptNames(deptDTO.getParentDeptNames());
}
if (Objects.equals(0,entity.getStatus())){
if (Objects.equals(0, entity.getStatus())) {
entity.setExamineMsg(null);
}
updateById(entity);

16
esua-epdc/epdc-module/epdc-user/epdc-user-server/src/main/java/com/elink/esua/epdc/party/service/impl/ReportPartyServiceImpl.java

@ -38,10 +38,7 @@ import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import javax.annotation.Resource;
import java.util.Arrays;
import java.util.List;
import java.util.Map;
import java.util.Objects;
import java.util.*;
/**
* 党员报道
@ -65,7 +62,16 @@ public class ReportPartyServiceImpl extends BaseServiceImpl<ReportPartyDao, Repo
page.getRecords().forEach(entity -> {
result.getList().forEach(dto -> {
if (entity.getId().equals(dto.getId())) {
dto.setAllDeptIds(entity.getAllDeptIds().split(","));
String[] ids;
if (StringUtils.isNotEmpty(entity.getAllDeptIds())) {
dto.setAllDeptIds(entity.getAllDeptIds().split(","));
}
if (StringUtils.isNotEmpty(entity.getCouplingCommunity())) {
ids = entity.getCouplingCommunity().split(",");
String deptId = ids[ids.length - 1];
ParentAndAllDeptDTO deptDTO = adminFeignClient.getParentAndAllDept(deptId).getData();
dto.setCouplingCommunityName(deptDTO.getAllDeptNames());
}
}
});
});

Loading…
Cancel
Save