forked from luyan/epmet-cloud-lingshan
52 changed files with 2893 additions and 80 deletions
@ -0,0 +1,34 @@ |
|||||
|
package com.epmet.commons.tools.enums; |
||||
|
|
||||
|
public enum CollectUrlEnum { |
||||
|
|
||||
|
|
||||
|
URL_PRE("subpages/points/pages/fangyi/xinxi/create/index", "小程序码跳转地址"), |
||||
|
GET_CODE_URL("https://api.weixin.qq.com/wxa/getwxacode?access_token=", "获取二维码的url"); |
||||
|
|
||||
|
|
||||
|
private String code; |
||||
|
private String name; |
||||
|
|
||||
|
|
||||
|
CollectUrlEnum(String code, String name) { |
||||
|
this.code = code; |
||||
|
this.name = name; |
||||
|
} |
||||
|
|
||||
|
public String getCode() { |
||||
|
return code; |
||||
|
} |
||||
|
|
||||
|
public void setCode(String code) { |
||||
|
this.code = code; |
||||
|
} |
||||
|
|
||||
|
public String getName() { |
||||
|
return name; |
||||
|
} |
||||
|
|
||||
|
public void setName(String name) { |
||||
|
this.name = name; |
||||
|
} |
||||
|
} |
@ -0,0 +1,36 @@ |
|||||
|
package com.epmet.dto.form; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
|
||||
|
import java.io.Serializable; |
||||
|
|
||||
|
/** |
||||
|
* @author wgf |
||||
|
* @date 2022/8/3 11:18 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class CollectHouseFormDTO implements Serializable { |
||||
|
private static final long serialVersionUID = 2636608477324780974L; |
||||
|
|
||||
|
private String id; |
||||
|
|
||||
|
/** |
||||
|
* 房屋状态 1:出租 0:自住 2:闲置 3:未售出 |
||||
|
*/ |
||||
|
private Integer rentFlag; |
||||
|
|
||||
|
/** |
||||
|
* 房主姓名 |
||||
|
*/ |
||||
|
private String ownerName; |
||||
|
|
||||
|
/** |
||||
|
* 客户ID |
||||
|
*/ |
||||
|
private String customerId; |
||||
|
|
||||
|
/** |
||||
|
* 居住人数 |
||||
|
*/ |
||||
|
private Integer resiNumber; |
||||
|
} |
@ -0,0 +1,25 @@ |
|||||
|
package com.epmet.dto.form; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
|
||||
|
import java.io.Serializable; |
||||
|
|
||||
|
/** |
||||
|
* @author wgf |
||||
|
* @date 2022/8/3 11:18 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class GetHouseInfoToCollectFormDTO implements Serializable { |
||||
|
private static final long serialVersionUID = 2636608477324780974L; |
||||
|
|
||||
|
/** |
||||
|
* 单元 |
||||
|
*/ |
||||
|
private String buildingUnitId; |
||||
|
|
||||
|
/** |
||||
|
* 门牌号 |
||||
|
*/ |
||||
|
private String doorName; |
||||
|
|
||||
|
} |
@ -0,0 +1,124 @@ |
|||||
|
|
||||
|
package com.epmet.dto.result; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
|
||||
|
import java.io.Serializable; |
||||
|
import java.math.BigDecimal; |
||||
|
|
||||
|
/** |
||||
|
* desc:房屋列表结果类 |
||||
|
* |
||||
|
* @author liujianjun |
||||
|
*/ |
||||
|
@Data |
||||
|
public class IcHouseInfoCollectResultDTO implements Serializable { |
||||
|
|
||||
|
|
||||
|
private static final long serialVersionUID = 4963952996288796744L; |
||||
|
|
||||
|
/** |
||||
|
* id |
||||
|
*/ |
||||
|
private String id; |
||||
|
|
||||
|
/** |
||||
|
* 客户id |
||||
|
*/ |
||||
|
private String customerId; |
||||
|
|
||||
|
/** |
||||
|
* 所属组织的PIDS,包括agency,grid |
||||
|
*/ |
||||
|
private String orgIdPath; |
||||
|
|
||||
|
/** |
||||
|
* 小区id |
||||
|
*/ |
||||
|
private String neighborHoodId; |
||||
|
|
||||
|
/** |
||||
|
* 片区id,neighbor_hood_part.id,可为空。 |
||||
|
*/ |
||||
|
private String partId; |
||||
|
|
||||
|
/** |
||||
|
* 所属楼栋id |
||||
|
*/ |
||||
|
private String buildingId; |
||||
|
|
||||
|
/** |
||||
|
* 所属单元id |
||||
|
*/ |
||||
|
private String buildingUnitId; |
||||
|
|
||||
|
/** |
||||
|
* 房屋名字后台插入时生成 |
||||
|
*/ |
||||
|
private String houseName; |
||||
|
|
||||
|
/** |
||||
|
* 全名:小区,楼栋,单元,房屋 |
||||
|
*/ |
||||
|
private String fullName; |
||||
|
|
||||
|
/** |
||||
|
* 门牌号 |
||||
|
*/ |
||||
|
private String doorName; |
||||
|
|
||||
|
/** |
||||
|
* 房屋类型,这里存储字典value就可以 |
||||
|
*/ |
||||
|
private String houseType; |
||||
|
|
||||
|
/** |
||||
|
* 存储字典value |
||||
|
*/ |
||||
|
private String purpose; |
||||
|
|
||||
|
/** |
||||
|
* 1:出租 0:自住 2:闲置 3:未出售 |
||||
|
*/ |
||||
|
private Integer rentFlag; |
||||
|
|
||||
|
/** |
||||
|
* 房主姓名 |
||||
|
*/ |
||||
|
private String ownerName; |
||||
|
|
||||
|
/** |
||||
|
* 房主电话 |
||||
|
*/ |
||||
|
private String ownerPhone; |
||||
|
|
||||
|
/** |
||||
|
* 房主身份证号 |
||||
|
*/ |
||||
|
private String ownerIdCard; |
||||
|
|
||||
|
/** |
||||
|
* 排序 |
||||
|
*/ |
||||
|
private BigDecimal sort; |
||||
|
|
||||
|
/** |
||||
|
* 备注 |
||||
|
*/ |
||||
|
private String remark; |
||||
|
|
||||
|
/** |
||||
|
* 房屋编码 |
||||
|
*/ |
||||
|
private String houseCode; |
||||
|
private String houseQrcodeUrl; |
||||
|
|
||||
|
/** |
||||
|
* 居住人数 |
||||
|
*/ |
||||
|
private Integer resiNumber; |
||||
|
/** |
||||
|
* 房屋可编辑编码 |
||||
|
*/ |
||||
|
private String coding; |
||||
|
} |
@ -0,0 +1 @@ |
|||||
|
alter table ic_neighbor_hood add COLUMN `QRCODE_URL` varchar(255) DEFAULT NULL COMMENT '二维码地址'; |
@ -0,0 +1,144 @@ |
|||||
|
package com.epmet.dto; |
||||
|
|
||||
|
import java.io.Serializable; |
||||
|
import java.util.Date; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
|
||||
|
/** |
||||
|
* 居民信息采集-访客 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-08-02 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class IcResiCollectVisitorDTO implements Serializable { |
||||
|
|
||||
|
private static final long serialVersionUID = 1L; |
||||
|
|
||||
|
/** |
||||
|
* 主键 |
||||
|
*/ |
||||
|
private String id; |
||||
|
|
||||
|
/** |
||||
|
* 目的地 |
||||
|
*/ |
||||
|
private String address; |
||||
|
|
||||
|
/** |
||||
|
* 客户Id customer.id |
||||
|
*/ |
||||
|
private String customerId; |
||||
|
|
||||
|
/** |
||||
|
* 网格ID |
||||
|
*/ |
||||
|
private String gridId; |
||||
|
|
||||
|
/** |
||||
|
* 组织Id |
||||
|
*/ |
||||
|
private String agencyId; |
||||
|
|
||||
|
/** |
||||
|
* 组织的pids |
||||
|
*/ |
||||
|
private String pids; |
||||
|
|
||||
|
/** |
||||
|
* 所属小区ID; |
||||
|
*/ |
||||
|
private String villageId; |
||||
|
|
||||
|
/** |
||||
|
* 所属小区名称 |
||||
|
*/ |
||||
|
private String villageName; |
||||
|
|
||||
|
/** |
||||
|
* 所属楼宇Id |
||||
|
*/ |
||||
|
private String buildId; |
||||
|
|
||||
|
/** |
||||
|
* 所属楼宇名称 |
||||
|
*/ |
||||
|
private String buildName; |
||||
|
|
||||
|
/** |
||||
|
* 单元id |
||||
|
*/ |
||||
|
private String unitId; |
||||
|
|
||||
|
/** |
||||
|
* 单元名 |
||||
|
*/ |
||||
|
private String unitName; |
||||
|
|
||||
|
/** |
||||
|
* 所属家庭Id |
||||
|
*/ |
||||
|
private String homeId; |
||||
|
|
||||
|
/** |
||||
|
* 房间名 |
||||
|
*/ |
||||
|
private String homeName; |
||||
|
|
||||
|
/** |
||||
|
* 姓名 |
||||
|
*/ |
||||
|
private String name; |
||||
|
|
||||
|
/** |
||||
|
* 手机号 |
||||
|
*/ |
||||
|
private String mobile; |
||||
|
|
||||
|
/** |
||||
|
* 身份证号 |
||||
|
*/ |
||||
|
private String idCard; |
||||
|
|
||||
|
/** |
||||
|
* 来访事由 |
||||
|
*/ |
||||
|
private String comeReason; |
||||
|
|
||||
|
/** |
||||
|
* 人脸照片 |
||||
|
*/ |
||||
|
private String faceImg; |
||||
|
|
||||
|
/** |
||||
|
* 删除标识 0.未删除 1.已删除 |
||||
|
*/ |
||||
|
private Integer delFlag; |
||||
|
|
||||
|
/** |
||||
|
* 乐观锁 |
||||
|
*/ |
||||
|
private Integer revision; |
||||
|
|
||||
|
/** |
||||
|
* 创建人 |
||||
|
*/ |
||||
|
private String createdBy; |
||||
|
|
||||
|
/** |
||||
|
* 创建时间 |
||||
|
*/ |
||||
|
private Date createdTime; |
||||
|
|
||||
|
/** |
||||
|
* 更新人 |
||||
|
*/ |
||||
|
private String updatedBy; |
||||
|
|
||||
|
/** |
||||
|
* 更新时间 |
||||
|
*/ |
||||
|
private Date updatedTime; |
||||
|
|
||||
|
} |
@ -0,0 +1,122 @@ |
|||||
|
package com.epmet.dto; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
|
||||
|
import javax.validation.constraints.NotBlank; |
||||
|
import java.io.Serializable; |
||||
|
|
||||
|
|
||||
|
/** |
||||
|
* 居民信息采集-访客 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-08-02 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class SaveCollectVisitorFormDTO implements Serializable { |
||||
|
|
||||
|
private static final long serialVersionUID = 1L; |
||||
|
|
||||
|
/** |
||||
|
* 客户Id customer.id |
||||
|
*/ |
||||
|
private String customerId; |
||||
|
|
||||
|
/** |
||||
|
* 网格ID |
||||
|
*/ |
||||
|
private String gridId; |
||||
|
|
||||
|
/** |
||||
|
* 组织Id |
||||
|
*/ |
||||
|
private String agencyId; |
||||
|
|
||||
|
/** |
||||
|
* 组织的pids |
||||
|
*/ |
||||
|
private String pids; |
||||
|
|
||||
|
/** |
||||
|
* 所属小区ID; |
||||
|
*/ |
||||
|
@NotBlank(message = "小区ID不能为空") |
||||
|
private String villageId; |
||||
|
|
||||
|
/** |
||||
|
* 所属小区名称 |
||||
|
*/ |
||||
|
@NotBlank(message = "小区名称不能为空") |
||||
|
private String villageName; |
||||
|
|
||||
|
/** |
||||
|
* 所属楼宇Id |
||||
|
*/ |
||||
|
@NotBlank(message = "楼宇Id不能为空") |
||||
|
private String buildId; |
||||
|
|
||||
|
/** |
||||
|
* 所属楼宇名称 |
||||
|
*/ |
||||
|
@NotBlank(message = "楼宇名称不能为空") |
||||
|
private String buildName; |
||||
|
|
||||
|
/** |
||||
|
* 单元id |
||||
|
*/ |
||||
|
@NotBlank(message = "单元id不能为空") |
||||
|
private String unitId; |
||||
|
|
||||
|
/** |
||||
|
* 单元名 |
||||
|
*/ |
||||
|
@NotBlank(message = "单元名不能为空") |
||||
|
private String unitName; |
||||
|
|
||||
|
/** |
||||
|
* 所属家庭Id |
||||
|
*/ |
||||
|
@NotBlank(message = "家庭Id不能为空") |
||||
|
private String homeId; |
||||
|
|
||||
|
/** |
||||
|
* 房间名 |
||||
|
*/ |
||||
|
@NotBlank(message = "房间名不能为空") |
||||
|
private String homeName; |
||||
|
|
||||
|
/** |
||||
|
* 详细地址 |
||||
|
*/ |
||||
|
@NotBlank(message = "家庭地址不能为空") |
||||
|
private String address; |
||||
|
|
||||
|
/** |
||||
|
* 姓名 |
||||
|
*/ |
||||
|
@NotBlank(message = "姓名不能为空") |
||||
|
private String name; |
||||
|
|
||||
|
/** |
||||
|
* 手机号 |
||||
|
*/ |
||||
|
@NotBlank(message = "手机号不能为空") |
||||
|
private String mobile; |
||||
|
|
||||
|
/** |
||||
|
* 身份证号 |
||||
|
*/ |
||||
|
private String idCard; |
||||
|
|
||||
|
/** |
||||
|
* 来访事由 |
||||
|
*/ |
||||
|
private String comeReason; |
||||
|
|
||||
|
/** |
||||
|
* 人脸照片 |
||||
|
*/ |
||||
|
private String faceImg; |
||||
|
|
||||
|
|
||||
|
} |
@ -0,0 +1,20 @@ |
|||||
|
package com.epmet.dto.form; |
||||
|
|
||||
|
import com.epmet.commons.tools.dto.form.PageFormDTO; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
import javax.validation.constraints.NotBlank; |
||||
|
import java.io.Serializable; |
||||
|
|
||||
|
/** |
||||
|
* @program: epmet-cloud |
||||
|
* @description: |
||||
|
* @author: wangtong |
||||
|
* @create: 2022-08-03 14:15 |
||||
|
**/ |
||||
|
@Data |
||||
|
public class CollectDetailFormDTO extends PageFormDTO implements Serializable { |
||||
|
|
||||
|
@NotBlank(message = "id不可为空") |
||||
|
private String id; |
||||
|
} |
@ -0,0 +1,76 @@ |
|||||
|
package com.epmet.dto.form; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
|
||||
|
import java.io.Serializable; |
||||
|
import java.util.List; |
||||
|
|
||||
|
/** |
||||
|
* 收集居民信息入参 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class CollectDetailResultDTO implements Serializable { |
||||
|
|
||||
|
private String id; |
||||
|
|
||||
|
/** |
||||
|
* 组织Id |
||||
|
*/ |
||||
|
private String agencyId; |
||||
|
|
||||
|
/** |
||||
|
* 所属小区ID |
||||
|
*/ |
||||
|
private String villageId; |
||||
|
private String villageName; |
||||
|
|
||||
|
/** |
||||
|
* 所属楼宇Id |
||||
|
*/ |
||||
|
private String buildId; |
||||
|
private String buildName; |
||||
|
|
||||
|
/** |
||||
|
* 单元id |
||||
|
*/ |
||||
|
private String unitId; |
||||
|
private String unitName; |
||||
|
|
||||
|
/** |
||||
|
* 所属家庭Id |
||||
|
*/ |
||||
|
private String homeId; |
||||
|
private String homeName; |
||||
|
|
||||
|
/** |
||||
|
* 详细地址 |
||||
|
*/ |
||||
|
private String address; |
||||
|
|
||||
|
/** |
||||
|
* 房屋状态 |
||||
|
*/ |
||||
|
private String houseType; |
||||
|
|
||||
|
/** |
||||
|
* 户主姓名 |
||||
|
*/ |
||||
|
private String houseHolderName; |
||||
|
|
||||
|
/** |
||||
|
* 居住成员人数 |
||||
|
*/ |
||||
|
private Integer totalResi; |
||||
|
|
||||
|
/** |
||||
|
* 审核状态:0待审核 1未通过 2已通过 |
||||
|
*/ |
||||
|
private String checkState; |
||||
|
|
||||
|
/** |
||||
|
* 审核原因 |
||||
|
*/ |
||||
|
private String checkReason; |
||||
|
|
||||
|
private List<IcResiCollectMemDetailDTO> memberList; |
||||
|
} |
@ -0,0 +1,20 @@ |
|||||
|
package com.epmet.dto.form; |
||||
|
|
||||
|
import com.epmet.commons.tools.dto.form.PageFormDTO; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
import java.io.Serializable; |
||||
|
|
||||
|
/** |
||||
|
* @program: epmet-cloud |
||||
|
* @description: |
||||
|
* @author: wangtong |
||||
|
* @create: 2022-08-03 14:15 |
||||
|
**/ |
||||
|
@Data |
||||
|
public class CollectPageFormDTO extends PageFormDTO implements Serializable { |
||||
|
|
||||
|
private String customerId; |
||||
|
|
||||
|
private String userId; |
||||
|
} |
@ -0,0 +1,65 @@ |
|||||
|
package com.epmet.dto.form; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
|
||||
|
import javax.validation.constraints.NotBlank; |
||||
|
import java.io.Serializable; |
||||
|
import java.util.Date; |
||||
|
|
||||
|
|
||||
|
/** |
||||
|
* 居民信息采集-审核入参 |
||||
|
* |
||||
|
* @author wgf |
||||
|
* @since v1.0.0 2022-08-02 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class IcResiCollectCheckFormDTO implements Serializable { |
||||
|
|
||||
|
private static final long serialVersionUID = 1L; |
||||
|
|
||||
|
/** |
||||
|
* 主键 |
||||
|
*/ |
||||
|
@NotBlank(message = "Id不能为空") |
||||
|
private String id; |
||||
|
|
||||
|
/** |
||||
|
* 审核状态:0待审核 1未通过 2已通过 |
||||
|
*/ |
||||
|
@NotBlank(message = "审核状态不能为空") |
||||
|
private String checkState; |
||||
|
|
||||
|
/** |
||||
|
* 审核原因 |
||||
|
*/ |
||||
|
private String checkReason; |
||||
|
|
||||
|
/** |
||||
|
* 单元号 |
||||
|
*/ |
||||
|
private String buildingUnitId; |
||||
|
|
||||
|
/** |
||||
|
* 房间号 |
||||
|
*/ |
||||
|
private String doorName; |
||||
|
|
||||
|
/** |
||||
|
* 客户ID(审核人) |
||||
|
*/ |
||||
|
private String customerId; |
||||
|
|
||||
|
/** |
||||
|
* 员工ID(审核人) |
||||
|
*/ |
||||
|
private String userId; |
||||
|
|
||||
|
/** |
||||
|
* 员工姓名(审核人) |
||||
|
*/ |
||||
|
private String realName; |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
@ -0,0 +1,28 @@ |
|||||
|
package com.epmet.dto.form; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
|
||||
|
import javax.validation.constraints.NotBlank; |
||||
|
import java.io.Serializable; |
||||
|
|
||||
|
|
||||
|
/** |
||||
|
* 居民信息采集-获取房屋信息 |
||||
|
* |
||||
|
* @author wgf |
||||
|
* @since v1.0.0 2022-08-02 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class IcResiCollectGetDetailFormDTO implements Serializable { |
||||
|
|
||||
|
private static final long serialVersionUID = 1L; |
||||
|
|
||||
|
/** |
||||
|
* 主键 |
||||
|
*/ |
||||
|
@NotBlank(message = "Id不能为空") |
||||
|
private String id; |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
@ -0,0 +1,93 @@ |
|||||
|
package com.epmet.dto.form; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
|
||||
|
import java.io.Serializable; |
||||
|
|
||||
|
/** |
||||
|
* 家庭成员信息 |
||||
|
* 前端做校验 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class IcResiCollectMemDetailDTO implements Serializable { |
||||
|
|
||||
|
/** |
||||
|
* 居住成员1姓名 |
||||
|
*/ |
||||
|
// @NotBlank(message = "姓名不能为空", groups = {ResiCollectFormDTO.InternalShowGroup.class, IcResiCollectFormDTO.ExternalShowGroup.class})
|
||||
|
private String name; |
||||
|
|
||||
|
/** |
||||
|
* 居住成员1身份证号 |
||||
|
*/ |
||||
|
// @NotBlank(message = "身份证号不能为空", groups = {ResiCollectFormDTO.InternalShowGroup.class, IcResiCollectFormDTO.ExternalShowGroup.class})
|
||||
|
private String idNum; |
||||
|
|
||||
|
/** |
||||
|
* 居住成员1手机号 |
||||
|
*/ |
||||
|
// @NotBlank(message = "手机号不能为空", groups = {IcResiCollectFormDTO.InternalShowGroup.class, IcResiCollectFormDTO.ExternalShowGroup.class})
|
||||
|
private String mobile; |
||||
|
|
||||
|
/** |
||||
|
* 居住成员1是否参加几轮全员核算检测,数字1-10 |
||||
|
*/ |
||||
|
// @NotBlank(message = "核算检测情况不能为空", groups = {IcResiCollectFormDTO.InternalShowGroup.class, IcResiCollectFormDTO.ExternalShowGroup.class})
|
||||
|
private String heSuanCount; |
||||
|
|
||||
|
/** |
||||
|
* 居住成员1新冠疫苗接种情况;1:已全程接种;2:未全程接种;0未接种; |
||||
|
*/ |
||||
|
// @NotNull(message = "疫苗接种情况不能为空", groups = {IcResiCollectFormDTO.InternalShowGroup.class, IcResiCollectFormDTO.ExternalShowGroup.class})
|
||||
|
private Integer ymjz; |
||||
|
|
||||
|
/** |
||||
|
* 户籍所在地 |
||||
|
*/ |
||||
|
private String domicilePlace; |
||||
|
|
||||
|
/** |
||||
|
* 户籍所在地行政地区编码 |
||||
|
*/ |
||||
|
private String domicilePlaceCode; |
||||
|
|
||||
|
/** |
||||
|
* 户籍所在地行政地区编码全路径,包含自己,英文逗号隔开例如:37,3702,370203 |
||||
|
*/ |
||||
|
private String domicilePlaceCodePath; |
||||
|
|
||||
|
/** |
||||
|
* 学校或公司 |
||||
|
*/ |
||||
|
private String workPlace; |
||||
|
|
||||
|
/** |
||||
|
* 备注 |
||||
|
*/ |
||||
|
private String remark; |
||||
|
|
||||
|
/** |
||||
|
* 社区居民信息登记-查询返参用 |
||||
|
*/ |
||||
|
private String id; |
||||
|
|
||||
|
/** |
||||
|
* 与房主关系 |
||||
|
*/ |
||||
|
private String relationship; |
||||
|
|
||||
|
/** |
||||
|
* 人脸头像 |
||||
|
*/ |
||||
|
private String faceImg; |
||||
|
|
||||
|
/** |
||||
|
* 是否是党员 |
||||
|
*/ |
||||
|
private String isParty; |
||||
|
|
||||
|
/** |
||||
|
* 客户ID |
||||
|
*/ |
||||
|
private String customerId; |
||||
|
} |
@ -0,0 +1,105 @@ |
|||||
|
package com.epmet.dto.form; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
|
||||
|
import javax.validation.constraints.NotBlank; |
||||
|
import javax.validation.constraints.NotEmpty; |
||||
|
import javax.validation.constraints.NotNull; |
||||
|
import java.io.Serializable; |
||||
|
import java.util.List; |
||||
|
|
||||
|
/** |
||||
|
* 收集居民信息入参 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class SaveCollectFormDTO implements Serializable { |
||||
|
|
||||
|
/** |
||||
|
* id |
||||
|
*/ |
||||
|
private String id; |
||||
|
|
||||
|
/** |
||||
|
* 客户Id customer.id |
||||
|
*/ |
||||
|
private String customerId; |
||||
|
|
||||
|
/** |
||||
|
* 内部:internal;外部:external |
||||
|
*/ |
||||
|
private String origin; |
||||
|
|
||||
|
/** |
||||
|
* 网格ID_后端接口赋值 |
||||
|
*/ |
||||
|
private String gridId; |
||||
|
|
||||
|
/** |
||||
|
* 组织Id_后端接口赋值 |
||||
|
*/ |
||||
|
private String agencyId; |
||||
|
|
||||
|
/** |
||||
|
* 组织的pid_后端接口赋值 |
||||
|
*/ |
||||
|
private String pids; |
||||
|
|
||||
|
/** |
||||
|
* 所属小区ID |
||||
|
*/ |
||||
|
@NotBlank(message = "小区不能为空") |
||||
|
private String villageId; |
||||
|
@NotBlank(message = "小区名不能为空") |
||||
|
private String villageName; |
||||
|
|
||||
|
/** |
||||
|
* 所属楼宇Id |
||||
|
*/ |
||||
|
@NotBlank(message = "楼栋不能为空") |
||||
|
private String buildId; |
||||
|
@NotBlank(message = "楼栋名不能为空") |
||||
|
private String buildName; |
||||
|
|
||||
|
/** |
||||
|
* 单元id |
||||
|
*/ |
||||
|
@NotBlank(message = "单元不能为空") |
||||
|
private String unitId; |
||||
|
@NotBlank(message = "单元名不能为空") |
||||
|
private String unitName; |
||||
|
|
||||
|
/** |
||||
|
* 所属家庭Id |
||||
|
*/ |
||||
|
private String homeId; |
||||
|
@NotBlank(message = "家庭名不能为空") |
||||
|
private String homeName; |
||||
|
|
||||
|
/** |
||||
|
* 详细地址 |
||||
|
*/ |
||||
|
@NotBlank(message = "家庭地址不能为空") |
||||
|
private String address; |
||||
|
|
||||
|
/** |
||||
|
* 1自有0租住 |
||||
|
*/ |
||||
|
@NotBlank(message = "房子属于自有还是租住?") |
||||
|
private String houseType; |
||||
|
|
||||
|
/** |
||||
|
* 户主姓名 |
||||
|
*/ |
||||
|
@NotBlank(message = "户主姓名不能为空") |
||||
|
private String houseHolderName; |
||||
|
|
||||
|
/** |
||||
|
* 居住成员人数 |
||||
|
*/ |
||||
|
@NotNull(message = "居住成员人数不能为空") |
||||
|
private Integer totalResi; |
||||
|
|
||||
|
|
||||
|
@NotEmpty(message = "成员信息不能为空") |
||||
|
private List<IcResiCollectMemFormDTO> memberList; |
||||
|
} |
@ -0,0 +1,26 @@ |
|||||
|
package com.epmet.dto.form; |
||||
|
|
||||
|
import com.epmet.commons.tools.dto.form.PageFormDTO; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* @Author wgf |
||||
|
* @DateTime 2022/8/5 8:00 |
||||
|
* @DESC |
||||
|
*/ |
||||
|
@Data |
||||
|
public class VisitListFormDTO extends PageFormDTO { |
||||
|
|
||||
|
private static final long serialVersionUID = 2106773724057183577L; |
||||
|
|
||||
|
private String startTime; |
||||
|
|
||||
|
private String endTime; |
||||
|
|
||||
|
private String userId; |
||||
|
|
||||
|
private String customerId; |
||||
|
|
||||
|
private String orgId; |
||||
|
|
||||
|
} |
@ -0,0 +1,57 @@ |
|||||
|
package com.epmet.dto.result; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
|
||||
|
import java.io.Serializable; |
||||
|
import java.util.List; |
||||
|
|
||||
|
/** |
||||
|
* @Author wgf |
||||
|
* @DateTime 2022/3/18 19:00 |
||||
|
* @DESC |
||||
|
*/ |
||||
|
@Data |
||||
|
public class CollectHouseInfoResultDTO implements Serializable { |
||||
|
|
||||
|
private static final long serialVersionUID = -6692672375850864451L; |
||||
|
|
||||
|
/** |
||||
|
* label |
||||
|
*/ |
||||
|
private String label; |
||||
|
|
||||
|
/** |
||||
|
* 所属小区id |
||||
|
*/ |
||||
|
private String neighborHoodId; |
||||
|
|
||||
|
/** |
||||
|
* 所属小区姓名 |
||||
|
*/ |
||||
|
private String neighborHoodName; |
||||
|
|
||||
|
/** |
||||
|
* 所属楼栋id |
||||
|
*/ |
||||
|
private String buildingId; |
||||
|
/** |
||||
|
* 所属楼栋名称 |
||||
|
*/ |
||||
|
private String buildName; |
||||
|
/** |
||||
|
* 所属单元id |
||||
|
*/ |
||||
|
private String buildingUnitId; |
||||
|
/** |
||||
|
* 所属单元名称 |
||||
|
*/ |
||||
|
private String buildingUnitName; |
||||
|
/** |
||||
|
* 门牌号 |
||||
|
*/ |
||||
|
private String doorName; |
||||
|
/** |
||||
|
* 房主姓名 |
||||
|
*/ |
||||
|
private String ownerName; |
||||
|
} |
@ -0,0 +1,56 @@ |
|||||
|
package com.epmet.dto.result; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
|
||||
|
import java.io.Serializable; |
||||
|
|
||||
|
/** |
||||
|
* @Author zxc |
||||
|
* @DateTime 2022/3/18 19:00 |
||||
|
* @DESC |
||||
|
*/ |
||||
|
@Data |
||||
|
public class CollectPageListDTO implements Serializable { |
||||
|
|
||||
|
private static final long serialVersionUID = -6692672375850864451L; |
||||
|
|
||||
|
|
||||
|
private String id; |
||||
|
|
||||
|
/** |
||||
|
* 居住地址 |
||||
|
*/ |
||||
|
private String address; |
||||
|
|
||||
|
/** |
||||
|
* 居民:resi 访客:visitor |
||||
|
*/ |
||||
|
private String type; |
||||
|
|
||||
|
/** |
||||
|
* 居民登记/访客登记 |
||||
|
*/ |
||||
|
private String title; |
||||
|
|
||||
|
/** |
||||
|
* 审核状态:0待审核 1审核不通过 2审核通过 |
||||
|
*/ |
||||
|
private String checkState; |
||||
|
|
||||
|
/** |
||||
|
* 审核状态名称 |
||||
|
*/ |
||||
|
private String checkStateName; |
||||
|
|
||||
|
/** |
||||
|
* 审核原因 |
||||
|
*/ |
||||
|
private String checkReason; |
||||
|
|
||||
|
/** |
||||
|
* 提交时间 |
||||
|
*/ |
||||
|
private String createTime; |
||||
|
|
||||
|
|
||||
|
} |
@ -0,0 +1,137 @@ |
|||||
|
package com.epmet.controller; |
||||
|
|
||||
|
import com.epmet.commons.tools.annotation.LoginUser; |
||||
|
import com.epmet.commons.tools.annotation.MaskResponse; |
||||
|
import com.epmet.commons.tools.aop.NoRepeatSubmit; |
||||
|
import com.epmet.commons.tools.page.PageData; |
||||
|
import com.epmet.commons.tools.security.dto.TokenDto; |
||||
|
import com.epmet.commons.tools.utils.ExcelUtils; |
||||
|
import com.epmet.commons.tools.utils.Result; |
||||
|
import com.epmet.commons.tools.validator.AssertUtils; |
||||
|
import com.epmet.commons.tools.validator.ValidatorUtils; |
||||
|
import com.epmet.commons.tools.validator.group.AddGroup; |
||||
|
import com.epmet.commons.tools.validator.group.DefaultGroup; |
||||
|
import com.epmet.commons.tools.validator.group.UpdateGroup; |
||||
|
import com.epmet.dto.IcResiCollectVisitorDTO; |
||||
|
import com.epmet.dto.SaveCollectVisitorFormDTO; |
||||
|
import com.epmet.dto.form.CollectDetailFormDTO; |
||||
|
import com.epmet.dto.form.CollectListFormDTO; |
||||
|
import com.epmet.dto.form.VisitListFormDTO; |
||||
|
import com.epmet.dto.result.CollectListResultDTO; |
||||
|
import com.epmet.excel.IcResiCollectVisitorExcel; |
||||
|
import com.epmet.service.IcResiCollectVisitorService; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
import javax.servlet.http.HttpServletResponse; |
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
|
||||
|
/** |
||||
|
* 居民信息采集-访客 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-08-02 |
||||
|
*/ |
||||
|
@RestController |
||||
|
@RequestMapping("icResiCollectVisitor") |
||||
|
public class IcResiCollectVisitorController { |
||||
|
|
||||
|
@Autowired |
||||
|
private IcResiCollectVisitorService icResiCollectVisitorService; |
||||
|
|
||||
|
@RequestMapping("page") |
||||
|
public Result<PageData<IcResiCollectVisitorDTO>> page(@RequestParam Map<String, Object> params){ |
||||
|
// PageData<IcResiCollectVisitorDTO> page = icResiCollectVisitorService.page(params);
|
||||
|
PageData<IcResiCollectVisitorDTO> page = icResiCollectVisitorService.getPhrasePage(params); |
||||
|
return new Result<PageData<IcResiCollectVisitorDTO>>().ok(page); |
||||
|
|
||||
|
|
||||
|
} |
||||
|
|
||||
|
/** |
||||
|
* Desc: 访客记录列表 |
||||
|
* @param formDTO |
||||
|
* @param tokenDto |
||||
|
* @author wgf |
||||
|
* @date 2022/8/5 8:23 |
||||
|
*/ |
||||
|
@PostMapping("list") |
||||
|
// @MaskResponse(fieldNames = { "memberIdNum", "memberMobile" },
|
||||
|
// fieldsMaskType = { MaskResponse.MASK_TYPE_ID_CARD, MaskResponse.MASK_TYPE_MOBILE })
|
||||
|
public Result<PageData<IcResiCollectVisitorDTO>> getVisitorList(@RequestBody VisitListFormDTO formDTO, @LoginUser TokenDto tokenDto){ |
||||
|
ValidatorUtils.validateEntity(formDTO,CollectListFormDTO.CollectListForm.class); |
||||
|
formDTO.setUserId(tokenDto.getUserId()); |
||||
|
formDTO.setCustomerId(tokenDto.getCustomerId()); |
||||
|
return new Result<PageData<IcResiCollectVisitorDTO>>().ok(icResiCollectVisitorService.getVisitorList(formDTO)); |
||||
|
} |
||||
|
|
||||
|
@RequestMapping(value = "{id}",method = {RequestMethod.POST,RequestMethod.GET}) |
||||
|
public Result<IcResiCollectVisitorDTO> get(@PathVariable("id") String id){ |
||||
|
IcResiCollectVisitorDTO data = icResiCollectVisitorService.get(id); |
||||
|
return new Result<IcResiCollectVisitorDTO>().ok(data); |
||||
|
} |
||||
|
|
||||
|
@NoRepeatSubmit |
||||
|
@PostMapping("save") |
||||
|
public Result save(@RequestBody IcResiCollectVisitorDTO dto){ |
||||
|
//效验数据
|
||||
|
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class); |
||||
|
icResiCollectVisitorService.save(dto); |
||||
|
return new Result(); |
||||
|
} |
||||
|
|
||||
|
@NoRepeatSubmit |
||||
|
@PostMapping("update") |
||||
|
public Result update(@RequestBody IcResiCollectVisitorDTO dto){ |
||||
|
//效验数据
|
||||
|
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class); |
||||
|
icResiCollectVisitorService.update(dto); |
||||
|
return new Result(); |
||||
|
} |
||||
|
|
||||
|
@PostMapping("delete") |
||||
|
public Result delete(@RequestBody String[] ids){ |
||||
|
//效验数据
|
||||
|
AssertUtils.isArrayEmpty(ids, "id"); |
||||
|
icResiCollectVisitorService.delete(ids); |
||||
|
return new Result(); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("export") |
||||
|
public void export(@RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception { |
||||
|
List<IcResiCollectVisitorDTO> list = icResiCollectVisitorService.list(params); |
||||
|
ExcelUtils.exportExcelToTarget(response, null, list, IcResiCollectVisitorExcel.class); |
||||
|
} |
||||
|
|
||||
|
/** |
||||
|
* @describe: 保存访客信息 |
||||
|
* @author wangtong |
||||
|
* @date 2022/8/3 10:33 |
||||
|
* @params [dto] |
||||
|
* @return com.epmet.commons.tools.utils.Result |
||||
|
*/ |
||||
|
@NoRepeatSubmit |
||||
|
@PostMapping("saveInfo") |
||||
|
public Result saveInfo(@RequestBody SaveCollectVisitorFormDTO dto){ |
||||
|
//效验数据
|
||||
|
ValidatorUtils.validateEntity(dto); |
||||
|
return icResiCollectVisitorService.saveInfo(dto); |
||||
|
} |
||||
|
|
||||
|
/** |
||||
|
* @describe: 访客信息详情 |
||||
|
* @author wangtong |
||||
|
* @date 2022/8/3 15:41 |
||||
|
* @params [dto] |
||||
|
* @return com.epmet.commons.tools.utils.Result |
||||
|
*/ |
||||
|
@PostMapping("getVisitorDetail") |
||||
|
public Result getVisitorDetail(@RequestBody CollectDetailFormDTO dto) { |
||||
|
ValidatorUtils.validateEntity(dto); |
||||
|
return icResiCollectVisitorService.getVisitorDetail(dto); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
} |
@ -0,0 +1,38 @@ |
|||||
|
package com.epmet.dao; |
||||
|
|
||||
|
import com.epmet.commons.mybatis.dao.BaseDao; |
||||
|
import com.epmet.dto.IcResiCollectVisitorDTO; |
||||
|
import com.epmet.dto.form.CollectListFormDTO; |
||||
|
import com.epmet.dto.form.VisitListFormDTO; |
||||
|
import com.epmet.dto.result.CollectListResultDTO; |
||||
|
import com.epmet.entity.IcResiCollectVisitorEntity; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
/** |
||||
|
* 居民信息采集-访客 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-08-02 |
||||
|
*/ |
||||
|
@Mapper |
||||
|
public interface IcResiCollectVisitorDao extends BaseDao<IcResiCollectVisitorEntity> { |
||||
|
|
||||
|
/** |
||||
|
* 条件查询 |
||||
|
* @param params |
||||
|
* @return |
||||
|
*/ |
||||
|
List<IcResiCollectVisitorDTO> getPhrasePage(Map<String, Object> params); |
||||
|
|
||||
|
/** |
||||
|
* Desc: 查询访客信息 |
||||
|
* @param formDTO |
||||
|
* @author wgf |
||||
|
* @date 2022/8/5 8:41 |
||||
|
*/ |
||||
|
List<IcResiCollectVisitorDTO> getCollectList(VisitListFormDTO formDTO); |
||||
|
|
||||
|
} |
@ -0,0 +1,111 @@ |
|||||
|
package com.epmet.entity; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.annotation.TableName; |
||||
|
import com.epmet.commons.mybatis.entity.BaseEpmetEntity; |
||||
|
import lombok.Data; |
||||
|
import lombok.EqualsAndHashCode; |
||||
|
|
||||
|
/** |
||||
|
* 居民信息采集-访客 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-08-02 |
||||
|
*/ |
||||
|
@Data |
||||
|
@EqualsAndHashCode(callSuper=false) |
||||
|
@TableName("ic_resi_collect_visitor") |
||||
|
public class IcResiCollectVisitorEntity extends BaseEpmetEntity { |
||||
|
|
||||
|
private static final long serialVersionUID = 1L; |
||||
|
|
||||
|
/** |
||||
|
* 客户Id customer.id |
||||
|
*/ |
||||
|
private String customerId; |
||||
|
|
||||
|
/** |
||||
|
* 网格ID |
||||
|
*/ |
||||
|
private String gridId; |
||||
|
|
||||
|
/** |
||||
|
* 组织Id |
||||
|
*/ |
||||
|
private String agencyId; |
||||
|
|
||||
|
/** |
||||
|
* 组织的pids |
||||
|
*/ |
||||
|
private String pids; |
||||
|
|
||||
|
/** |
||||
|
* 所属小区ID; |
||||
|
*/ |
||||
|
private String villageId; |
||||
|
|
||||
|
/** |
||||
|
* 所属小区名称 |
||||
|
*/ |
||||
|
private String villageName; |
||||
|
|
||||
|
/** |
||||
|
* 所属楼宇Id |
||||
|
*/ |
||||
|
private String buildId; |
||||
|
|
||||
|
/** |
||||
|
* 所属楼宇名称 |
||||
|
*/ |
||||
|
private String buildName; |
||||
|
|
||||
|
/** |
||||
|
* 单元id |
||||
|
*/ |
||||
|
private String unitId; |
||||
|
|
||||
|
/** |
||||
|
* 单元名 |
||||
|
*/ |
||||
|
private String unitName; |
||||
|
|
||||
|
/** |
||||
|
* 所属家庭Id |
||||
|
*/ |
||||
|
private String homeId; |
||||
|
|
||||
|
/** |
||||
|
* 房间名 |
||||
|
*/ |
||||
|
private String homeName; |
||||
|
|
||||
|
/** |
||||
|
* 详细地址 |
||||
|
*/ |
||||
|
private String address; |
||||
|
|
||||
|
/** |
||||
|
* 姓名 |
||||
|
*/ |
||||
|
private String name; |
||||
|
|
||||
|
/** |
||||
|
* 手机号 |
||||
|
*/ |
||||
|
private String mobile; |
||||
|
|
||||
|
/** |
||||
|
* 身份证号 |
||||
|
*/ |
||||
|
private String idCard; |
||||
|
|
||||
|
/** |
||||
|
* 来访事由 |
||||
|
*/ |
||||
|
private String comeReason; |
||||
|
|
||||
|
/** |
||||
|
* 人脸照片 |
||||
|
*/ |
||||
|
private String faceImg; |
||||
|
|
||||
|
} |
@ -0,0 +1,90 @@ |
|||||
|
package com.epmet.excel; |
||||
|
|
||||
|
import cn.afterturn.easypoi.excel.annotation.Excel; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
import java.util.Date; |
||||
|
|
||||
|
/** |
||||
|
* 居民信息采集-访客 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-08-02 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class IcResiCollectVisitorExcel { |
||||
|
|
||||
|
@Excel(name = "主键") |
||||
|
private String id; |
||||
|
|
||||
|
@Excel(name = "客户Id customer.id") |
||||
|
private String customerId; |
||||
|
|
||||
|
@Excel(name = "网格ID") |
||||
|
private String gridId; |
||||
|
|
||||
|
@Excel(name = "组织Id") |
||||
|
private String agencyId; |
||||
|
|
||||
|
@Excel(name = "组织的pids") |
||||
|
private String pids; |
||||
|
|
||||
|
@Excel(name = "所属小区ID;") |
||||
|
private String villageId; |
||||
|
|
||||
|
@Excel(name = "所属小区名称") |
||||
|
private String villageName; |
||||
|
|
||||
|
@Excel(name = "所属楼宇Id") |
||||
|
private String buildId; |
||||
|
|
||||
|
@Excel(name = "所属楼宇名称") |
||||
|
private String buildName; |
||||
|
|
||||
|
@Excel(name = "单元id") |
||||
|
private String unitId; |
||||
|
|
||||
|
@Excel(name = "单元名") |
||||
|
private String unitName; |
||||
|
|
||||
|
@Excel(name = "所属家庭Id") |
||||
|
private String homeId; |
||||
|
|
||||
|
@Excel(name = "房间名") |
||||
|
private String homeName; |
||||
|
|
||||
|
@Excel(name = "姓名") |
||||
|
private String name; |
||||
|
|
||||
|
@Excel(name = "手机号") |
||||
|
private String mobile; |
||||
|
|
||||
|
@Excel(name = "身份证号") |
||||
|
private String idCard; |
||||
|
|
||||
|
@Excel(name = "来访事由") |
||||
|
private String comeReason; |
||||
|
|
||||
|
@Excel(name = "人脸照片") |
||||
|
private String faceImg; |
||||
|
|
||||
|
@Excel(name = "删除标识 0.未删除 1.已删除") |
||||
|
private Integer delFlag; |
||||
|
|
||||
|
@Excel(name = "乐观锁") |
||||
|
private Integer revision; |
||||
|
|
||||
|
@Excel(name = "创建人") |
||||
|
private String createdBy; |
||||
|
|
||||
|
@Excel(name = "创建时间") |
||||
|
private Date createdTime; |
||||
|
|
||||
|
@Excel(name = "更新人") |
||||
|
private String updatedBy; |
||||
|
|
||||
|
@Excel(name = "更新时间") |
||||
|
private Date updatedTime; |
||||
|
|
||||
|
|
||||
|
} |
@ -0,0 +1,30 @@ |
|||||
|
package com.epmet.redis; |
||||
|
|
||||
|
import com.epmet.commons.tools.redis.RedisUtils; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.stereotype.Component; |
||||
|
|
||||
|
/** |
||||
|
* 居民信息采集-访客 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-08-02 |
||||
|
*/ |
||||
|
@Component |
||||
|
public class IcResiCollectVisitorRedis { |
||||
|
@Autowired |
||||
|
private RedisUtils redisUtils; |
||||
|
|
||||
|
public void delete(Object[] ids) { |
||||
|
|
||||
|
} |
||||
|
|
||||
|
public void set(){ |
||||
|
|
||||
|
} |
||||
|
|
||||
|
public String get(String id){ |
||||
|
return null; |
||||
|
} |
||||
|
|
||||
|
} |
@ -0,0 +1,111 @@ |
|||||
|
package com.epmet.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.IcResiCollectVisitorDTO; |
||||
|
import com.epmet.dto.SaveCollectVisitorFormDTO; |
||||
|
import com.epmet.dto.form.CollectDetailFormDTO; |
||||
|
import com.epmet.dto.form.CollectListFormDTO; |
||||
|
import com.epmet.dto.form.VisitListFormDTO; |
||||
|
import com.epmet.dto.result.CollectListResultDTO; |
||||
|
import com.epmet.entity.IcResiCollectVisitorEntity; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
/** |
||||
|
* 居民信息采集-访客 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-08-02 |
||||
|
*/ |
||||
|
public interface IcResiCollectVisitorService extends BaseService<IcResiCollectVisitorEntity> { |
||||
|
|
||||
|
/** |
||||
|
* 默认分页 |
||||
|
* |
||||
|
* @param params |
||||
|
* @return PageData<IcResiCollectVisitorDTO> |
||||
|
* @author generator |
||||
|
* @date 2022-08-02 |
||||
|
*/ |
||||
|
PageData<IcResiCollectVisitorDTO> page(Map<String, Object> params); |
||||
|
|
||||
|
/** |
||||
|
* 分页条件查询 |
||||
|
* @param params |
||||
|
* @return |
||||
|
*/ |
||||
|
PageData<IcResiCollectVisitorDTO> getPhrasePage(Map<String, Object> params); |
||||
|
|
||||
|
PageData<IcResiCollectVisitorDTO> getVisitorList(VisitListFormDTO formDTO); |
||||
|
|
||||
|
/** |
||||
|
* 默认查询 |
||||
|
* |
||||
|
* @param params |
||||
|
* @return java.util.List<IcResiCollectVisitorDTO> |
||||
|
* @author generator |
||||
|
* @date 2022-08-02 |
||||
|
*/ |
||||
|
List<IcResiCollectVisitorDTO> list(Map<String, Object> params); |
||||
|
|
||||
|
/** |
||||
|
* 单条查询 |
||||
|
* |
||||
|
* @param id |
||||
|
* @return IcResiCollectVisitorDTO |
||||
|
* @author generator |
||||
|
* @date 2022-08-02 |
||||
|
*/ |
||||
|
IcResiCollectVisitorDTO get(String id); |
||||
|
|
||||
|
/** |
||||
|
* 默认保存 |
||||
|
* |
||||
|
* @param dto |
||||
|
* @return void |
||||
|
* @author generator |
||||
|
* @date 2022-08-02 |
||||
|
*/ |
||||
|
void save(IcResiCollectVisitorDTO dto); |
||||
|
|
||||
|
/** |
||||
|
* 默认更新 |
||||
|
* |
||||
|
* @param dto |
||||
|
* @return void |
||||
|
* @author generator |
||||
|
* @date 2022-08-02 |
||||
|
*/ |
||||
|
void update(IcResiCollectVisitorDTO dto); |
||||
|
|
||||
|
/** |
||||
|
* 批量删除 |
||||
|
* |
||||
|
* @param ids |
||||
|
* @return void |
||||
|
* @author generator |
||||
|
* @date 2022-08-02 |
||||
|
*/ |
||||
|
void delete(String[] ids); |
||||
|
|
||||
|
/** |
||||
|
* @describe: 保存访客信息 |
||||
|
* @author wangtong |
||||
|
* @date 2022/8/3 10:44 |
||||
|
* @params [dto] |
||||
|
* @return com.epmet.commons.tools.utils.Result |
||||
|
*/ |
||||
|
Result saveInfo(SaveCollectVisitorFormDTO dto); |
||||
|
|
||||
|
/** |
||||
|
* @describe: 访客信息详情 |
||||
|
* @author wangtong |
||||
|
* @date 2022/8/3 15:43 |
||||
|
* @params [dto] |
||||
|
* @return com.epmet.commons.tools.utils.Result |
||||
|
*/ |
||||
|
Result getVisitorDetail(CollectDetailFormDTO dto); |
||||
|
} |
@ -0,0 +1,158 @@ |
|||||
|
package com.epmet.service.impl; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
||||
|
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
|
import com.epmet.commons.mybatis.service.impl.BaseServiceImpl; |
||||
|
import com.epmet.commons.tools.constant.FieldConstant; |
||||
|
import com.epmet.commons.tools.dto.result.CustomerStaffInfoCacheResult; |
||||
|
import com.epmet.commons.tools.exception.EpmetException; |
||||
|
import com.epmet.commons.tools.page.PageData; |
||||
|
import com.epmet.commons.tools.redis.common.CustomerStaffRedis; |
||||
|
import com.epmet.commons.tools.utils.ConvertUtils; |
||||
|
import com.epmet.commons.tools.utils.Result; |
||||
|
import com.epmet.dao.IcResiCollectVisitorDao; |
||||
|
import com.epmet.dto.IcNeighborHoodDTO; |
||||
|
import com.epmet.dto.IcResiCollectVisitorDTO; |
||||
|
import com.epmet.dto.SaveCollectVisitorFormDTO; |
||||
|
import com.epmet.dto.form.CollectDetailFormDTO; |
||||
|
import com.epmet.dto.form.CollectListFormDTO; |
||||
|
import com.epmet.dto.form.VisitListFormDTO; |
||||
|
import com.epmet.dto.result.CollectListResultDTO; |
||||
|
import com.epmet.entity.IcResiCollectVisitorEntity; |
||||
|
import com.epmet.redis.IcResiCollectVisitorRedis; |
||||
|
import com.epmet.service.IcResiCollectVisitorService; |
||||
|
import com.github.pagehelper.PageHelper; |
||||
|
import com.github.pagehelper.PageInfo; |
||||
|
import org.apache.commons.lang3.StringUtils; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.stereotype.Service; |
||||
|
import org.springframework.transaction.annotation.Transactional; |
||||
|
|
||||
|
import java.util.ArrayList; |
||||
|
import java.util.Arrays; |
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
/** |
||||
|
* 居民信息采集-访客 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-08-02 |
||||
|
*/ |
||||
|
@Service |
||||
|
public class IcResiCollectVisitorServiceImpl extends BaseServiceImpl<IcResiCollectVisitorDao, IcResiCollectVisitorEntity> implements IcResiCollectVisitorService { |
||||
|
|
||||
|
@Autowired |
||||
|
private IcResiCollectVisitorRedis icResiCollectVisitorRedis; |
||||
|
|
||||
|
@Autowired |
||||
|
private IcResiCollectServiceImpl icResiCollectServiceImpl; |
||||
|
|
||||
|
@Override |
||||
|
public PageData<IcResiCollectVisitorDTO> page(Map<String, Object> params) { |
||||
|
IPage<IcResiCollectVisitorEntity> page = baseDao.selectPage( |
||||
|
getPage(params, FieldConstant.CREATED_TIME, false), |
||||
|
getWrapper(params) |
||||
|
); |
||||
|
return getPageData(page, IcResiCollectVisitorDTO.class); |
||||
|
} |
||||
|
|
||||
|
/** |
||||
|
* 条件查询 |
||||
|
* @param params |
||||
|
* @return |
||||
|
*/ |
||||
|
@Override |
||||
|
public PageData<IcResiCollectVisitorDTO> getPhrasePage(Map<String, Object> params) { |
||||
|
IPage<IcResiCollectVisitorDTO> page = getPage(params); |
||||
|
List<IcResiCollectVisitorDTO> list = baseDao.getPhrasePage(params); |
||||
|
return new PageData<>(list, page.getTotal()); |
||||
|
} |
||||
|
|
||||
|
/** |
||||
|
* Desc: 查询访客信息 |
||||
|
* @param formDTO |
||||
|
* @author wgf |
||||
|
* @date 2022/8/5 8:23 |
||||
|
*/ |
||||
|
@Override |
||||
|
public PageData<IcResiCollectVisitorDTO> getVisitorList(VisitListFormDTO formDTO) { |
||||
|
PageData<IcResiCollectVisitorDTO> result = new PageData<>(new ArrayList<>(), 0); |
||||
|
if (StringUtils.isBlank(formDTO.getStartTime()) && StringUtils.isBlank(formDTO.getEndTime()) ){ |
||||
|
CustomerStaffInfoCacheResult staffInfo = CustomerStaffRedis.getStaffInfo(formDTO.getCustomerId(), formDTO.getUserId()); |
||||
|
if (null == staffInfo){ |
||||
|
throw new EpmetException("查询人员信息失败"+formDTO.getUserId()); |
||||
|
} |
||||
|
formDTO.setOrgId(staffInfo.getAgencyId()); |
||||
|
} |
||||
|
PageInfo<IcResiCollectVisitorDTO> pageList = PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize()).doSelectPageInfo(() -> baseDao.getCollectList(formDTO)); |
||||
|
result.setList(pageList.getList()); |
||||
|
result.setTotal(Integer.parseInt(String.valueOf(pageList.getTotal()))); |
||||
|
return result; |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
public List<IcResiCollectVisitorDTO> list(Map<String, Object> params) { |
||||
|
List<IcResiCollectVisitorEntity> entityList = baseDao.selectList(getWrapper(params)); |
||||
|
|
||||
|
return ConvertUtils.sourceToTarget(entityList, IcResiCollectVisitorDTO.class); |
||||
|
} |
||||
|
|
||||
|
private QueryWrapper<IcResiCollectVisitorEntity> getWrapper(Map<String, Object> params){ |
||||
|
String id = (String)params.get(FieldConstant.ID_HUMP); |
||||
|
|
||||
|
QueryWrapper<IcResiCollectVisitorEntity> wrapper = new QueryWrapper<>(); |
||||
|
wrapper.eq(StringUtils.isNotBlank(id), FieldConstant.ID, id); |
||||
|
|
||||
|
return wrapper; |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
public IcResiCollectVisitorDTO get(String id) { |
||||
|
IcResiCollectVisitorEntity entity = baseDao.selectById(id); |
||||
|
return ConvertUtils.sourceToTarget(entity, IcResiCollectVisitorDTO.class); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
@Transactional(rollbackFor = Exception.class) |
||||
|
public void save(IcResiCollectVisitorDTO dto) { |
||||
|
IcResiCollectVisitorEntity entity = ConvertUtils.sourceToTarget(dto, IcResiCollectVisitorEntity.class); |
||||
|
insert(entity); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
@Transactional(rollbackFor = Exception.class) |
||||
|
public void update(IcResiCollectVisitorDTO dto) { |
||||
|
IcResiCollectVisitorEntity entity = ConvertUtils.sourceToTarget(dto, IcResiCollectVisitorEntity.class); |
||||
|
updateById(entity); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
@Transactional(rollbackFor = Exception.class) |
||||
|
public void delete(String[] ids) { |
||||
|
// 逻辑删除(@TableLogic 注解)
|
||||
|
baseDao.deleteBatchIds(Arrays.asList(ids)); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
@Override |
||||
|
@Transactional(rollbackFor = Exception.class) |
||||
|
public Result saveInfo(SaveCollectVisitorFormDTO dto) { |
||||
|
IcResiCollectVisitorEntity entity = ConvertUtils.sourceToTarget(dto, IcResiCollectVisitorEntity.class); |
||||
|
//根据小区id查询网格相关信息
|
||||
|
IcNeighborHoodDTO neighborHoodDTO = icResiCollectServiceImpl.queryIcNeighborHood(dto.getVillageId()); |
||||
|
entity.setGridId(neighborHoodDTO.getGridId()); |
||||
|
entity.setAgencyId(neighborHoodDTO.getAgencyId()); |
||||
|
entity.setPids(neighborHoodDTO.getAgencyPids()); |
||||
|
entity.setCustomerId(neighborHoodDTO.getCustomerId()); |
||||
|
insert(entity); |
||||
|
return new Result().ok("提交成功"); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
public Result getVisitorDetail(CollectDetailFormDTO dto) { |
||||
|
IcResiCollectVisitorEntity entity = baseDao.selectById(dto.getId()); |
||||
|
return new Result().ok(entity); |
||||
|
} |
||||
|
|
||||
|
} |
@ -0,0 +1,36 @@ |
|||||
|
alter table ic_resi_collect add COLUMN `CHECK_STATE` varchar(1) DEFAULT NULL COMMENT '审核状态:0待审核 1审核不通过 2审核通过'; |
||||
|
alter table ic_resi_collect add COLUMN `CHECK_REASON` varchar(255) DEFAULT NULL COMMENT '审核理由'; |
||||
|
|
||||
|
|
||||
|
alter table ic_resi_member add COLUMN `RELATIONSHIP` varchar(10) DEFAULT NULL COMMENT '与户主关系'; |
||||
|
alter table ic_resi_member add COLUMN `FACE_IMG` varchar(255) DEFAULT NULL COMMENT '人脸照片'; |
||||
|
|
||||
|
|
||||
|
CREATE TABLE `ic_resi_collect_visitor` ( |
||||
|
`ID` varchar(64) NOT NULL COMMENT '主键', |
||||
|
`CUSTOMER_ID` varchar(64) NOT NULL COMMENT '客户Id customer.id', |
||||
|
`GRID_ID` varchar(64) DEFAULT NULL COMMENT '网格ID', |
||||
|
`AGENCY_ID` varchar(64) DEFAULT NULL COMMENT '组织Id', |
||||
|
`PIDS` varchar(255) DEFAULT NULL COMMENT '组织的pids', |
||||
|
`VILLAGE_ID` varchar(64) DEFAULT NULL COMMENT '所属小区ID;', |
||||
|
`VILLAGE_NAME` varchar(64) DEFAULT NULL COMMENT '所属小区名称', |
||||
|
`BUILD_ID` varchar(64) DEFAULT NULL COMMENT '所属楼宇Id', |
||||
|
`BUILD_NAME` varchar(64) DEFAULT NULL COMMENT '所属楼宇名称', |
||||
|
`UNIT_ID` varchar(64) DEFAULT NULL COMMENT '单元id', |
||||
|
`UNIT_NAME` varchar(64) DEFAULT NULL COMMENT '单元名', |
||||
|
`HOME_ID` varchar(64) DEFAULT NULL COMMENT '所属家庭Id', |
||||
|
`HOME_NAME` varchar(64) DEFAULT NULL COMMENT '房间名', |
||||
|
`ADDRESS` varchar(255) NOT NULL COMMENT '详细地址', |
||||
|
`NAME` varchar(64) NOT NULL COMMENT '姓名', |
||||
|
`MOBILE` varchar(15) NOT NULL COMMENT '手机号', |
||||
|
`ID_CARD` varchar(18) DEFAULT NULL COMMENT '身份证号', |
||||
|
`COME_REASON` varchar(255) DEFAULT NULL COMMENT '来访事由', |
||||
|
`FACE_IMG` varchar(255) DEFAULT NULL COMMENT '人脸照片', |
||||
|
`DEL_FLAG` int(11) NOT NULL DEFAULT '0' COMMENT '删除标识 0.未删除 1.已删除', |
||||
|
`REVISION` int(11) NOT NULL COMMENT '乐观锁', |
||||
|
`CREATED_BY` varchar(64) NOT NULL COMMENT '创建人', |
||||
|
`CREATED_TIME` datetime NOT NULL COMMENT '创建时间', |
||||
|
`UPDATED_BY` varchar(64) NOT NULL COMMENT '更新人', |
||||
|
`UPDATED_TIME` datetime NOT NULL COMMENT '更新时间', |
||||
|
PRIMARY KEY (`ID`) |
||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='居民信息采集-访客'; |
@ -0,0 +1,108 @@ |
|||||
|
<?xml version="1.0" encoding="UTF-8"?> |
||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
||||
|
|
||||
|
<mapper namespace="com.epmet.dao.IcResiCollectVisitorDao"> |
||||
|
|
||||
|
<resultMap type="com.epmet.entity.IcResiCollectVisitorEntity" id="icResiCollectVisitorMap"> |
||||
|
<result property="id" column="ID"/> |
||||
|
<result property="customerId" column="CUSTOMER_ID"/> |
||||
|
<result property="gridId" column="GRID_ID"/> |
||||
|
<result property="agencyId" column="AGENCY_ID"/> |
||||
|
<result property="pids" column="PIDS"/> |
||||
|
<result property="villageId" column="VILLAGE_ID"/> |
||||
|
<result property="villageName" column="VILLAGE_NAME"/> |
||||
|
<result property="buildId" column="BUILD_ID"/> |
||||
|
<result property="buildName" column="BUILD_NAME"/> |
||||
|
<result property="unitId" column="UNIT_ID"/> |
||||
|
<result property="unitName" column="UNIT_NAME"/> |
||||
|
<result property="homeId" column="HOME_ID"/> |
||||
|
<result property="homeName" column="HOME_NAME"/> |
||||
|
<result property="name" column="NAME"/> |
||||
|
<result property="mobile" column="MOBILE"/> |
||||
|
<result property="idCard" column="ID_CARD"/> |
||||
|
<result property="comeReason" column="COME_REASON"/> |
||||
|
<result property="faceImg" column="FACE_IMG"/> |
||||
|
<result property="delFlag" column="DEL_FLAG"/> |
||||
|
<result property="revision" column="REVISION"/> |
||||
|
<result property="createdBy" column="CREATED_BY"/> |
||||
|
<result property="createdTime" column="CREATED_TIME"/> |
||||
|
<result property="updatedBy" column="UPDATED_BY"/> |
||||
|
<result property="updatedTime" column="UPDATED_TIME"/> |
||||
|
</resultMap> |
||||
|
|
||||
|
<select id="getPhrasePage" resultType="com.epmet.dto.IcResiCollectVisitorDTO"> |
||||
|
select |
||||
|
ID, |
||||
|
concat(VILLAGE_NAME,BUILD_NAME,UNIT_NAME,HOME_NAME) as address, |
||||
|
CUSTOMER_ID, |
||||
|
GRID_ID, |
||||
|
AGENCY_ID, |
||||
|
PIDS, |
||||
|
VILLAGE_ID, |
||||
|
VILLAGE_NAME, |
||||
|
BUILD_ID, |
||||
|
BUILD_NAME, |
||||
|
UNIT_ID, |
||||
|
UNIT_NAME, |
||||
|
HOME_ID, |
||||
|
HOME_NAME, |
||||
|
ADDRESS, |
||||
|
NAME, |
||||
|
MOBILE, |
||||
|
ID_CARD, |
||||
|
COME_REASON, |
||||
|
FACE_IMG, |
||||
|
DEL_FLAG, |
||||
|
REVISION, |
||||
|
CREATED_BY, |
||||
|
CREATED_TIME, |
||||
|
UPDATED_BY, |
||||
|
UPDATED_TIME |
||||
|
from ic_resi_collect_visitor |
||||
|
where DEL_FLAG = '0' |
||||
|
<if test="startTime != null and startTime != '' and endTime != null and endTime != ''"> |
||||
|
AND DATE_FORMAT( CREATED_TIME, '%Y-%m-%d' ) BETWEEN #{startTime} AND #{endTime} |
||||
|
</if> |
||||
|
order by CREATED_TIME desc |
||||
|
</select> |
||||
|
|
||||
|
<select id="getCollectList" resultType="com.epmet.dto.IcResiCollectVisitorDTO"> |
||||
|
select |
||||
|
ID, |
||||
|
CUSTOMER_ID, |
||||
|
GRID_ID, |
||||
|
AGENCY_ID, |
||||
|
PIDS, |
||||
|
VILLAGE_ID, |
||||
|
VILLAGE_NAME, |
||||
|
BUILD_ID, |
||||
|
BUILD_NAME, |
||||
|
UNIT_ID, |
||||
|
UNIT_NAME, |
||||
|
HOME_ID, |
||||
|
HOME_NAME, |
||||
|
ADDRESS, |
||||
|
NAME, |
||||
|
MOBILE, |
||||
|
ID_CARD, |
||||
|
COME_REASON, |
||||
|
FACE_IMG, |
||||
|
DEL_FLAG, |
||||
|
REVISION, |
||||
|
CREATED_BY, |
||||
|
CREATED_TIME, |
||||
|
UPDATED_BY, |
||||
|
UPDATED_TIME |
||||
|
from ic_resi_collect_visitor |
||||
|
where DEL_FLAG = '0' |
||||
|
<if test="startTime != null and startTime != '' and endTime != null and endTime != ''"> |
||||
|
AND DATE_FORMAT( CREATED_TIME, '%Y-%m-%d' ) BETWEEN #{startTime} AND #{endTime} |
||||
|
</if> |
||||
|
<if test='orgId != null and orgId != "" '> |
||||
|
AND CONCAT(PIDS,':',AGENCY_ID) LIKE CONCAT('%',#{orgId},'%') |
||||
|
</if> |
||||
|
order by CREATED_TIME desc |
||||
|
</select> |
||||
|
|
||||
|
|
||||
|
</mapper> |
Loading…
Reference in new issue