83 changed files with 5049 additions and 85 deletions
@ -0,0 +1,43 @@ |
|||||
|
package com.epmet.commons.tools.enums; |
||||
|
|
||||
|
/** |
||||
|
* 用户详细状态:01:新增、02:导入、03:迁入、04:新生、11:迁出、21死亡 未完待续 |
||||
|
*/ |
||||
|
public enum IcResiUserSubStatusEnum { |
||||
|
/** |
||||
|
* 环境变量枚举 |
||||
|
*/ |
||||
|
ADD("01", "新增"), |
||||
|
IMPORT("02", "导入"), |
||||
|
MOVE_IN("03", "迁入"), |
||||
|
BIRTH("04", "新生"), |
||||
|
MOVE_OUT("11", "迁出"), |
||||
|
DIED("21", "死亡"); |
||||
|
|
||||
|
private final String subStatus; |
||||
|
private final String statusDesc; |
||||
|
|
||||
|
|
||||
|
IcResiUserSubStatusEnum(String subStatus, String statusDesc) { |
||||
|
this.subStatus = subStatus; |
||||
|
this.statusDesc = statusDesc; |
||||
|
} |
||||
|
|
||||
|
public static IcResiUserSubStatusEnum getEnum(String subStatus) { |
||||
|
IcResiUserSubStatusEnum[] values = IcResiUserSubStatusEnum.values(); |
||||
|
for (IcResiUserSubStatusEnum value : values) { |
||||
|
if (value.getSubStatus().equals(subStatus)) { |
||||
|
return value; |
||||
|
} |
||||
|
} |
||||
|
return IcResiUserSubStatusEnum.ADD; |
||||
|
} |
||||
|
|
||||
|
public String getSubStatus() { |
||||
|
return subStatus; |
||||
|
} |
||||
|
|
||||
|
public String getStatusDesc() { |
||||
|
return statusDesc; |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,79 @@ |
|||||
|
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-05-09 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class IcHouseChangeDetailDTO implements Serializable { |
||||
|
|
||||
|
private static final long serialVersionUID = 1L; |
||||
|
|
||||
|
/** |
||||
|
* ID |
||||
|
*/ |
||||
|
private String id; |
||||
|
|
||||
|
/** |
||||
|
* 客户ID |
||||
|
*/ |
||||
|
private String customerId; |
||||
|
|
||||
|
/** |
||||
|
* 记录ID |
||||
|
*/ |
||||
|
private String recordId; |
||||
|
|
||||
|
/** |
||||
|
* 变更类型,HOUSE_TYPE:房屋类型,PURPOSE:房屋用途,RENT_FLAG:房屋状态,OWNER_NAME:房主姓名,OWNER_PHONE:房主电话,OWNER_ID_CARD:房主身份证 |
||||
|
*/ |
||||
|
private String changeCol; |
||||
|
|
||||
|
/** |
||||
|
* 变更前 |
||||
|
*/ |
||||
|
private String changeBefore; |
||||
|
|
||||
|
/** |
||||
|
* 变更后 |
||||
|
*/ |
||||
|
private String changeAfter; |
||||
|
|
||||
|
/** |
||||
|
* |
||||
|
*/ |
||||
|
private Integer delFlag; |
||||
|
|
||||
|
/** |
||||
|
* 乐观锁 |
||||
|
*/ |
||||
|
private Integer revision; |
||||
|
|
||||
|
/** |
||||
|
* 创建人 |
||||
|
*/ |
||||
|
private String createdBy; |
||||
|
|
||||
|
/** |
||||
|
* 创建时间 |
||||
|
*/ |
||||
|
private Date createdTime; |
||||
|
|
||||
|
/** |
||||
|
* 更新人 |
||||
|
*/ |
||||
|
private String updatedBy; |
||||
|
|
||||
|
/** |
||||
|
* 更新时间 |
||||
|
*/ |
||||
|
private Date updatedTime; |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,104 @@ |
|||||
|
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-05-09 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class IcHouseChangeRecordDTO implements Serializable { |
||||
|
|
||||
|
private static final long serialVersionUID = 1L; |
||||
|
|
||||
|
/** |
||||
|
* ID |
||||
|
*/ |
||||
|
private String id; |
||||
|
|
||||
|
/** |
||||
|
* 客户ID |
||||
|
*/ |
||||
|
private String customerId; |
||||
|
|
||||
|
/** |
||||
|
* 组织ID |
||||
|
*/ |
||||
|
private String agencyId; |
||||
|
|
||||
|
/** |
||||
|
* 网格ID |
||||
|
*/ |
||||
|
private String gridId; |
||||
|
|
||||
|
/** |
||||
|
* 小区ID |
||||
|
*/ |
||||
|
private String neighborHoodId; |
||||
|
|
||||
|
/** |
||||
|
* 楼栋ID |
||||
|
*/ |
||||
|
private String buildingId; |
||||
|
|
||||
|
/** |
||||
|
* 楼栋单元ID |
||||
|
*/ |
||||
|
private String buildingUnitId; |
||||
|
|
||||
|
/** |
||||
|
* 房屋ID |
||||
|
*/ |
||||
|
private String houseId; |
||||
|
|
||||
|
/** |
||||
|
* 变更前 |
||||
|
*/ |
||||
|
private String changeBefore; |
||||
|
|
||||
|
/** |
||||
|
* 变更后 |
||||
|
*/ |
||||
|
private String changeAfter; |
||||
|
|
||||
|
/** |
||||
|
* 组织ID的所有上级 |
||||
|
*/ |
||||
|
private String pids; |
||||
|
|
||||
|
/** |
||||
|
* |
||||
|
*/ |
||||
|
private Integer delFlag; |
||||
|
|
||||
|
/** |
||||
|
* 乐观锁 |
||||
|
*/ |
||||
|
private Integer revision; |
||||
|
|
||||
|
/** |
||||
|
* 创建人 |
||||
|
*/ |
||||
|
private String createdBy; |
||||
|
|
||||
|
/** |
||||
|
* 创建时间 |
||||
|
*/ |
||||
|
private Date createdTime; |
||||
|
|
||||
|
/** |
||||
|
* 更新人 |
||||
|
*/ |
||||
|
private String updatedBy; |
||||
|
|
||||
|
/** |
||||
|
* 更新时间 |
||||
|
*/ |
||||
|
private Date updatedTime; |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,57 @@ |
|||||
|
package com.epmet.dto.form; |
||||
|
|
||||
|
import com.epmet.commons.tools.dto.form.PageFormDTO; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
import java.io.Serializable; |
||||
|
|
||||
|
/** |
||||
|
* @Author zxc |
||||
|
* @DateTime 2022/5/10 13:34 |
||||
|
* @DESC |
||||
|
*/ |
||||
|
@Data |
||||
|
public class HouseChangeListFormDTO extends PageFormDTO implements Serializable { |
||||
|
|
||||
|
private static final long serialVersionUID = 3650098822228397304L; |
||||
|
|
||||
|
/** |
||||
|
* 网格ID |
||||
|
*/ |
||||
|
private String gridId; |
||||
|
|
||||
|
/** |
||||
|
* 工作人员所属组织ID |
||||
|
*/ |
||||
|
private String agencyId; |
||||
|
|
||||
|
/** |
||||
|
* 小区ID |
||||
|
*/ |
||||
|
private String neighborHoodId; |
||||
|
|
||||
|
/** |
||||
|
* 楼栋ID |
||||
|
*/ |
||||
|
private String buildingId; |
||||
|
|
||||
|
/** |
||||
|
* 楼栋单元ID |
||||
|
*/ |
||||
|
private String buildingUnitId; |
||||
|
|
||||
|
/** |
||||
|
* 房屋ID |
||||
|
*/ |
||||
|
private String houseId; |
||||
|
|
||||
|
/** |
||||
|
* 开始日期,eg:20220510 |
||||
|
*/ |
||||
|
private String startDate; |
||||
|
|
||||
|
/** |
||||
|
* 结束日期,eg:20220510 |
||||
|
*/ |
||||
|
private String endDate; |
||||
|
} |
||||
@ -0,0 +1,34 @@ |
|||||
|
package com.epmet.dto.result; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
|
||||
|
import java.io.Serializable; |
||||
|
|
||||
|
/** |
||||
|
* @Author zxc |
||||
|
* @DateTime 2022/5/10 09:21 |
||||
|
* @DESC |
||||
|
*/ |
||||
|
@Data |
||||
|
public class HouseAgencyInfoResultDTO implements Serializable { |
||||
|
|
||||
|
private static final long serialVersionUID = 2056073386531945191L; |
||||
|
|
||||
|
private String agencyId; |
||||
|
private String gridId; |
||||
|
private String pids; |
||||
|
private String houseId; |
||||
|
private String neighborHoodId; |
||||
|
private String buildingId; |
||||
|
private String buildingUnitId; |
||||
|
|
||||
|
public HouseAgencyInfoResultDTO() { |
||||
|
this.agencyId = ""; |
||||
|
this.gridId = ""; |
||||
|
this.pids = ""; |
||||
|
this.houseId = ""; |
||||
|
this.neighborHoodId = ""; |
||||
|
this.buildingId = ""; |
||||
|
this.buildingUnitId = ""; |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,41 @@ |
|||||
|
package com.epmet.dto.result; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
|
||||
|
import java.io.Serializable; |
||||
|
|
||||
|
/** |
||||
|
* @Author zxc |
||||
|
* @DateTime 2022/5/10 13:42 |
||||
|
* @DESC |
||||
|
*/ |
||||
|
@Data |
||||
|
public class HouseChangeListResultDTO implements Serializable { |
||||
|
|
||||
|
private static final long serialVersionUID = 4501420202270980751L; |
||||
|
|
||||
|
/** |
||||
|
* 所属网格 |
||||
|
*/ |
||||
|
private String gridName; |
||||
|
|
||||
|
/** |
||||
|
* 所属房屋 |
||||
|
*/ |
||||
|
private String houseName; |
||||
|
|
||||
|
/** |
||||
|
* 变更前 |
||||
|
*/ |
||||
|
private String changeBefore; |
||||
|
|
||||
|
/** |
||||
|
* 变更后 |
||||
|
*/ |
||||
|
private String changeAfter; |
||||
|
|
||||
|
/** |
||||
|
* 变更时间 |
||||
|
*/ |
||||
|
private String changeTime; |
||||
|
} |
||||
@ -0,0 +1,47 @@ |
|||||
|
package com.epmet.enums; |
||||
|
|
||||
|
import org.springframework.util.StringUtils; |
||||
|
|
||||
|
/** |
||||
|
* @Author zxc |
||||
|
* @DateTime 2022/5/9 17:03 |
||||
|
* @DESC |
||||
|
*/ |
||||
|
public enum HouseChangeEnums { |
||||
|
|
||||
|
HOUSE_TYPE("HOUSE_TYPE","房屋类型"), |
||||
|
PURPOSE("PURPOSE","房屋用途"), |
||||
|
RENT_FLAG("RENT_FLAG","房屋状态"), |
||||
|
OWNER_NAME("OWNER_NAME","房主姓名"), |
||||
|
OWNER_PHONE("OWNER_PHONE","房主电话"), |
||||
|
OWNER_ID_CARD("OWNER_ID_CARD","房主身份证"); |
||||
|
|
||||
|
private String column; |
||||
|
|
||||
|
private String columnName; |
||||
|
|
||||
|
HouseChangeEnums(String column, String columnName) { |
||||
|
this.column = column; |
||||
|
this.columnName = columnName; |
||||
|
} |
||||
|
|
||||
|
public static String getColumnNameByColumn(String column){ |
||||
|
if(StringUtils.isEmpty(column)){ |
||||
|
return ""; |
||||
|
} |
||||
|
for (HouseChangeEnums v : HouseChangeEnums.values()) { |
||||
|
if (v.column.equals(column)){ |
||||
|
return v.getColumnName(); |
||||
|
} |
||||
|
} |
||||
|
return ""; |
||||
|
} |
||||
|
|
||||
|
public String getColumn() { |
||||
|
return column; |
||||
|
} |
||||
|
|
||||
|
public String getColumnName() { |
||||
|
return columnName; |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,70 @@ |
|||||
|
package com.epmet.controller; |
||||
|
|
||||
|
import com.epmet.commons.tools.aop.NoRepeatSubmit; |
||||
|
import com.epmet.commons.tools.page.PageData; |
||||
|
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.UpdateGroup; |
||||
|
import com.epmet.commons.tools.validator.group.DefaultGroup; |
||||
|
import com.epmet.dto.IcHouseChangeDetailDTO; |
||||
|
import com.epmet.service.IcHouseChangeDetailService; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
import java.util.Map; |
||||
|
|
||||
|
|
||||
|
/** |
||||
|
* 房屋变更详情表 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-09 |
||||
|
*/ |
||||
|
@RestController |
||||
|
@RequestMapping("icHouseChangeDetail") |
||||
|
public class IcHouseChangeDetailController { |
||||
|
|
||||
|
@Autowired |
||||
|
private IcHouseChangeDetailService icHouseChangeDetailService; |
||||
|
|
||||
|
@RequestMapping("page") |
||||
|
public Result<PageData<IcHouseChangeDetailDTO>> page(@RequestParam Map<String, Object> params){ |
||||
|
PageData<IcHouseChangeDetailDTO> page = icHouseChangeDetailService.page(params); |
||||
|
return new Result<PageData<IcHouseChangeDetailDTO>>().ok(page); |
||||
|
} |
||||
|
|
||||
|
@RequestMapping(value = "{id}",method = {RequestMethod.POST,RequestMethod.GET}) |
||||
|
public Result<IcHouseChangeDetailDTO> get(@PathVariable("id") String id){ |
||||
|
IcHouseChangeDetailDTO data = icHouseChangeDetailService.get(id); |
||||
|
return new Result<IcHouseChangeDetailDTO>().ok(data); |
||||
|
} |
||||
|
|
||||
|
@NoRepeatSubmit |
||||
|
@PostMapping("save") |
||||
|
public Result save(@RequestBody IcHouseChangeDetailDTO dto){ |
||||
|
//效验数据
|
||||
|
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class); |
||||
|
icHouseChangeDetailService.save(dto); |
||||
|
return new Result(); |
||||
|
} |
||||
|
|
||||
|
@NoRepeatSubmit |
||||
|
@PostMapping("update") |
||||
|
public Result update(@RequestBody IcHouseChangeDetailDTO dto){ |
||||
|
//效验数据
|
||||
|
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class); |
||||
|
icHouseChangeDetailService.update(dto); |
||||
|
return new Result(); |
||||
|
} |
||||
|
|
||||
|
@PostMapping("delete") |
||||
|
public Result delete(@RequestBody String[] ids){ |
||||
|
//效验数据
|
||||
|
AssertUtils.isArrayEmpty(ids, "id"); |
||||
|
icHouseChangeDetailService.delete(ids); |
||||
|
return new Result(); |
||||
|
} |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,87 @@ |
|||||
|
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.dto.form.PageFormDTO; |
||||
|
import com.epmet.commons.tools.page.PageData; |
||||
|
import com.epmet.commons.tools.security.dto.TokenDto; |
||||
|
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.UpdateGroup; |
||||
|
import com.epmet.commons.tools.validator.group.DefaultGroup; |
||||
|
import com.epmet.dto.IcHouseChangeRecordDTO; |
||||
|
import com.epmet.dto.form.HouseChangeListFormDTO; |
||||
|
import com.epmet.service.IcHouseChangeRecordService; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.web.bind.annotation.*; |
||||
|
|
||||
|
import java.util.Map; |
||||
|
|
||||
|
|
||||
|
/** |
||||
|
* 房屋变更记录表 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-09 |
||||
|
*/ |
||||
|
@RestController |
||||
|
@RequestMapping("icHouseChangeRecord") |
||||
|
public class IcHouseChangeRecordController { |
||||
|
|
||||
|
@Autowired |
||||
|
private IcHouseChangeRecordService icHouseChangeRecordService; |
||||
|
|
||||
|
@RequestMapping("page") |
||||
|
public Result<PageData<IcHouseChangeRecordDTO>> page(@RequestParam Map<String, Object> params){ |
||||
|
PageData<IcHouseChangeRecordDTO> page = icHouseChangeRecordService.page(params); |
||||
|
return new Result<PageData<IcHouseChangeRecordDTO>>().ok(page); |
||||
|
} |
||||
|
|
||||
|
@RequestMapping(value = "{id}",method = {RequestMethod.POST,RequestMethod.GET}) |
||||
|
public Result<IcHouseChangeRecordDTO> get(@PathVariable("id") String id){ |
||||
|
IcHouseChangeRecordDTO data = icHouseChangeRecordService.get(id); |
||||
|
return new Result<IcHouseChangeRecordDTO>().ok(data); |
||||
|
} |
||||
|
|
||||
|
@NoRepeatSubmit |
||||
|
@PostMapping("save") |
||||
|
public Result save(@RequestBody IcHouseChangeRecordDTO dto){ |
||||
|
//效验数据
|
||||
|
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class); |
||||
|
icHouseChangeRecordService.save(dto); |
||||
|
return new Result(); |
||||
|
} |
||||
|
|
||||
|
@NoRepeatSubmit |
||||
|
@PostMapping("update") |
||||
|
public Result update(@RequestBody IcHouseChangeRecordDTO dto){ |
||||
|
//效验数据
|
||||
|
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class); |
||||
|
icHouseChangeRecordService.update(dto); |
||||
|
return new Result(); |
||||
|
} |
||||
|
|
||||
|
@PostMapping("delete") |
||||
|
public Result delete(@RequestBody String[] ids){ |
||||
|
//效验数据
|
||||
|
AssertUtils.isArrayEmpty(ids, "id"); |
||||
|
icHouseChangeRecordService.delete(ids); |
||||
|
return new Result(); |
||||
|
} |
||||
|
|
||||
|
/** |
||||
|
* Desc: 查询房屋变更记录 |
||||
|
* @param tokenDto |
||||
|
* @param formDTO |
||||
|
* @author zxc |
||||
|
* @date 2022/5/10 14:32 |
||||
|
*/ |
||||
|
@PostMapping("list") |
||||
|
public Result<PageData> list(@LoginUser TokenDto tokenDto,@RequestBody HouseChangeListFormDTO formDTO){ |
||||
|
ValidatorUtils.validateEntity(formDTO, PageFormDTO.AddUserInternalGroup.class); |
||||
|
return new Result<PageData>().ok(icHouseChangeRecordService.list(tokenDto, formDTO)); |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,16 @@ |
|||||
|
package com.epmet.dao; |
||||
|
|
||||
|
import com.epmet.commons.mybatis.dao.BaseDao; |
||||
|
import com.epmet.entity.IcHouseChangeDetailEntity; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
|
||||
|
/** |
||||
|
* 房屋变更详情表 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-09 |
||||
|
*/ |
||||
|
@Mapper |
||||
|
public interface IcHouseChangeDetailDao extends BaseDao<IcHouseChangeDetailEntity> { |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,28 @@ |
|||||
|
package com.epmet.dao; |
||||
|
|
||||
|
import com.epmet.commons.mybatis.dao.BaseDao; |
||||
|
import com.epmet.dto.form.HouseChangeListFormDTO; |
||||
|
import com.epmet.dto.result.HouseChangeListResultDTO; |
||||
|
import com.epmet.entity.IcHouseChangeRecordEntity; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
/** |
||||
|
* 房屋变更记录表 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-09 |
||||
|
*/ |
||||
|
@Mapper |
||||
|
public interface IcHouseChangeRecordDao extends BaseDao<IcHouseChangeRecordEntity> { |
||||
|
|
||||
|
/** |
||||
|
* Desc: 获取房屋变更记录 |
||||
|
* @param formDTO |
||||
|
* @author zxc |
||||
|
* @date 2022/5/10 14:22 |
||||
|
*/ |
||||
|
List<HouseChangeListResultDTO> getHouseChangeList(HouseChangeListFormDTO formDTO); |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,49 @@ |
|||||
|
package com.epmet.entity; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.annotation.TableName; |
||||
|
|
||||
|
import com.epmet.commons.mybatis.entity.BaseEpmetEntity; |
||||
|
import lombok.Data; |
||||
|
import lombok.EqualsAndHashCode; |
||||
|
|
||||
|
import java.util.Date; |
||||
|
|
||||
|
/** |
||||
|
* 房屋变更详情表 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-09 |
||||
|
*/ |
||||
|
@Data |
||||
|
@EqualsAndHashCode(callSuper=false) |
||||
|
@TableName("ic_house_change_detail") |
||||
|
public class IcHouseChangeDetailEntity extends BaseEpmetEntity { |
||||
|
|
||||
|
private static final long serialVersionUID = 1L; |
||||
|
|
||||
|
/** |
||||
|
* 客户ID |
||||
|
*/ |
||||
|
private String customerId; |
||||
|
|
||||
|
/** |
||||
|
* 记录ID |
||||
|
*/ |
||||
|
private String recordId; |
||||
|
|
||||
|
/** |
||||
|
* 变更类型,HOUSE_TYPE:房屋类型,PURPOSE:房屋用途,RENT_FLAG:房屋状态,OWNER_NAME:房主姓名,OWNER_PHONE:房主电话,OWNER_ID_CARD:房主身份证 |
||||
|
*/ |
||||
|
private String changeCol; |
||||
|
|
||||
|
/** |
||||
|
* 变更前 |
||||
|
*/ |
||||
|
private String changeBefore; |
||||
|
|
||||
|
/** |
||||
|
* 变更后 |
||||
|
*/ |
||||
|
private String changeAfter; |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,74 @@ |
|||||
|
package com.epmet.entity; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.annotation.TableName; |
||||
|
|
||||
|
import com.epmet.commons.mybatis.entity.BaseEpmetEntity; |
||||
|
import lombok.Data; |
||||
|
import lombok.EqualsAndHashCode; |
||||
|
|
||||
|
import java.util.Date; |
||||
|
|
||||
|
/** |
||||
|
* 房屋变更记录表 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-09 |
||||
|
*/ |
||||
|
@Data |
||||
|
@EqualsAndHashCode(callSuper=false) |
||||
|
@TableName("ic_house_change_record") |
||||
|
public class IcHouseChangeRecordEntity extends BaseEpmetEntity { |
||||
|
|
||||
|
private static final long serialVersionUID = 1L; |
||||
|
|
||||
|
/** |
||||
|
* 客户ID |
||||
|
*/ |
||||
|
private String customerId; |
||||
|
|
||||
|
/** |
||||
|
* 组织ID |
||||
|
*/ |
||||
|
private String agencyId; |
||||
|
|
||||
|
/** |
||||
|
* 网格ID |
||||
|
*/ |
||||
|
private String gridId; |
||||
|
|
||||
|
/** |
||||
|
* 小区ID |
||||
|
*/ |
||||
|
private String neighborHoodId; |
||||
|
|
||||
|
/** |
||||
|
* 楼栋ID |
||||
|
*/ |
||||
|
private String buildingId; |
||||
|
|
||||
|
/** |
||||
|
* 楼栋单元ID |
||||
|
*/ |
||||
|
private String buildingUnitId; |
||||
|
|
||||
|
/** |
||||
|
* 房屋ID |
||||
|
*/ |
||||
|
private String houseId; |
||||
|
|
||||
|
/** |
||||
|
* 变更前 |
||||
|
*/ |
||||
|
private String changeBefore; |
||||
|
|
||||
|
/** |
||||
|
* 变更后 |
||||
|
*/ |
||||
|
private String changeAfter; |
||||
|
|
||||
|
/** |
||||
|
* 组织ID的所有上级 |
||||
|
*/ |
||||
|
private String pids; |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,78 @@ |
|||||
|
package com.epmet.service; |
||||
|
|
||||
|
import com.epmet.commons.mybatis.service.BaseService; |
||||
|
import com.epmet.commons.tools.page.PageData; |
||||
|
import com.epmet.dto.IcHouseChangeDetailDTO; |
||||
|
import com.epmet.entity.IcHouseChangeDetailEntity; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
/** |
||||
|
* 房屋变更详情表 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-09 |
||||
|
*/ |
||||
|
public interface IcHouseChangeDetailService extends BaseService<IcHouseChangeDetailEntity> { |
||||
|
|
||||
|
/** |
||||
|
* 默认分页 |
||||
|
* |
||||
|
* @param params |
||||
|
* @return PageData<IcHouseChangeDetailDTO> |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
PageData<IcHouseChangeDetailDTO> page(Map<String, Object> params); |
||||
|
|
||||
|
/** |
||||
|
* 默认查询 |
||||
|
* |
||||
|
* @param params |
||||
|
* @return java.util.List<IcHouseChangeDetailDTO> |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
List<IcHouseChangeDetailDTO> list(Map<String, Object> params); |
||||
|
|
||||
|
/** |
||||
|
* 单条查询 |
||||
|
* |
||||
|
* @param id |
||||
|
* @return IcHouseChangeDetailDTO |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
IcHouseChangeDetailDTO get(String id); |
||||
|
|
||||
|
/** |
||||
|
* 默认保存 |
||||
|
* |
||||
|
* @param dto |
||||
|
* @return void |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
void save(IcHouseChangeDetailDTO dto); |
||||
|
|
||||
|
/** |
||||
|
* 默认更新 |
||||
|
* |
||||
|
* @param dto |
||||
|
* @return void |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
void update(IcHouseChangeDetailDTO dto); |
||||
|
|
||||
|
/** |
||||
|
* 批量删除 |
||||
|
* |
||||
|
* @param ids |
||||
|
* @return void |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
void delete(String[] ids); |
||||
|
} |
||||
@ -0,0 +1,89 @@ |
|||||
|
package com.epmet.service; |
||||
|
|
||||
|
import com.epmet.commons.mybatis.service.BaseService; |
||||
|
import com.epmet.commons.tools.page.PageData; |
||||
|
import com.epmet.commons.tools.security.dto.TokenDto; |
||||
|
import com.epmet.dto.IcHouseChangeRecordDTO; |
||||
|
import com.epmet.dto.form.HouseChangeListFormDTO; |
||||
|
import com.epmet.entity.IcHouseChangeRecordEntity; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
/** |
||||
|
* 房屋变更记录表 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-09 |
||||
|
*/ |
||||
|
public interface IcHouseChangeRecordService extends BaseService<IcHouseChangeRecordEntity> { |
||||
|
|
||||
|
/** |
||||
|
* 默认分页 |
||||
|
* |
||||
|
* @param params |
||||
|
* @return PageData<IcHouseChangeRecordDTO> |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
PageData<IcHouseChangeRecordDTO> page(Map<String, Object> params); |
||||
|
|
||||
|
/** |
||||
|
* 默认查询 |
||||
|
* |
||||
|
* @param params |
||||
|
* @return java.util.List<IcHouseChangeRecordDTO> |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
List<IcHouseChangeRecordDTO> list(Map<String, Object> params); |
||||
|
|
||||
|
/** |
||||
|
* 单条查询 |
||||
|
* |
||||
|
* @param id |
||||
|
* @return IcHouseChangeRecordDTO |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
IcHouseChangeRecordDTO get(String id); |
||||
|
|
||||
|
/** |
||||
|
* 默认保存 |
||||
|
* |
||||
|
* @param dto |
||||
|
* @return void |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
void save(IcHouseChangeRecordDTO dto); |
||||
|
|
||||
|
/** |
||||
|
* 默认更新 |
||||
|
* |
||||
|
* @param dto |
||||
|
* @return void |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
void update(IcHouseChangeRecordDTO dto); |
||||
|
|
||||
|
/** |
||||
|
* 批量删除 |
||||
|
* |
||||
|
* @param ids |
||||
|
* @return void |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
void delete(String[] ids); |
||||
|
|
||||
|
/** |
||||
|
* Desc: 查询房屋变更记录 |
||||
|
* @param tokenDto |
||||
|
* @param formDTO |
||||
|
* @author zxc |
||||
|
* @date 2022/5/10 14:32 |
||||
|
*/ |
||||
|
PageData list(TokenDto tokenDto, HouseChangeListFormDTO formDTO); |
||||
|
} |
||||
@ -0,0 +1,83 @@ |
|||||
|
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.page.PageData; |
||||
|
import com.epmet.commons.tools.utils.ConvertUtils; |
||||
|
import com.epmet.commons.tools.constant.FieldConstant; |
||||
|
import com.epmet.dao.IcHouseChangeDetailDao; |
||||
|
import com.epmet.dto.IcHouseChangeDetailDTO; |
||||
|
import com.epmet.entity.IcHouseChangeDetailEntity; |
||||
|
import com.epmet.service.IcHouseChangeDetailService; |
||||
|
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.Arrays; |
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
/** |
||||
|
* 房屋变更详情表 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-09 |
||||
|
*/ |
||||
|
@Service |
||||
|
public class IcHouseChangeDetailServiceImpl extends BaseServiceImpl<IcHouseChangeDetailDao, IcHouseChangeDetailEntity> implements IcHouseChangeDetailService { |
||||
|
|
||||
|
@Override |
||||
|
public PageData<IcHouseChangeDetailDTO> page(Map<String, Object> params) { |
||||
|
IPage<IcHouseChangeDetailEntity> page = baseDao.selectPage( |
||||
|
getPage(params, FieldConstant.CREATED_TIME, false), |
||||
|
getWrapper(params) |
||||
|
); |
||||
|
return getPageData(page, IcHouseChangeDetailDTO.class); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
public List<IcHouseChangeDetailDTO> list(Map<String, Object> params) { |
||||
|
List<IcHouseChangeDetailEntity> entityList = baseDao.selectList(getWrapper(params)); |
||||
|
|
||||
|
return ConvertUtils.sourceToTarget(entityList, IcHouseChangeDetailDTO.class); |
||||
|
} |
||||
|
|
||||
|
private QueryWrapper<IcHouseChangeDetailEntity> getWrapper(Map<String, Object> params){ |
||||
|
String id = (String)params.get(FieldConstant.ID_HUMP); |
||||
|
|
||||
|
QueryWrapper<IcHouseChangeDetailEntity> wrapper = new QueryWrapper<>(); |
||||
|
wrapper.eq(StringUtils.isNotBlank(id), FieldConstant.ID, id); |
||||
|
|
||||
|
return wrapper; |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
public IcHouseChangeDetailDTO get(String id) { |
||||
|
IcHouseChangeDetailEntity entity = baseDao.selectById(id); |
||||
|
return ConvertUtils.sourceToTarget(entity, IcHouseChangeDetailDTO.class); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
@Transactional(rollbackFor = Exception.class) |
||||
|
public void save(IcHouseChangeDetailDTO dto) { |
||||
|
IcHouseChangeDetailEntity entity = ConvertUtils.sourceToTarget(dto, IcHouseChangeDetailEntity.class); |
||||
|
insert(entity); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
@Transactional(rollbackFor = Exception.class) |
||||
|
public void update(IcHouseChangeDetailDTO dto) { |
||||
|
IcHouseChangeDetailEntity entity = ConvertUtils.sourceToTarget(dto, IcHouseChangeDetailEntity.class); |
||||
|
updateById(entity); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
@Transactional(rollbackFor = Exception.class) |
||||
|
public void delete(String[] ids) { |
||||
|
// 逻辑删除(@TableLogic 注解)
|
||||
|
baseDao.deleteBatchIds(Arrays.asList(ids)); |
||||
|
} |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,120 @@ |
|||||
|
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.NumConstant; |
||||
|
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.security.dto.TokenDto; |
||||
|
import com.epmet.commons.tools.utils.ConvertUtils; |
||||
|
import com.epmet.commons.tools.constant.FieldConstant; |
||||
|
import com.epmet.dao.IcHouseChangeRecordDao; |
||||
|
import com.epmet.dto.IcHouseChangeRecordDTO; |
||||
|
import com.epmet.dto.form.HouseChangeListFormDTO; |
||||
|
import com.epmet.dto.result.HouseChangeListResultDTO; |
||||
|
import com.epmet.entity.IcHouseChangeRecordEntity; |
||||
|
import com.epmet.service.IcHouseChangeRecordService; |
||||
|
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-05-09 |
||||
|
*/ |
||||
|
@Service |
||||
|
public class IcHouseChangeRecordServiceImpl extends BaseServiceImpl<IcHouseChangeRecordDao, IcHouseChangeRecordEntity> implements IcHouseChangeRecordService { |
||||
|
|
||||
|
@Override |
||||
|
public PageData<IcHouseChangeRecordDTO> page(Map<String, Object> params) { |
||||
|
IPage<IcHouseChangeRecordEntity> page = baseDao.selectPage( |
||||
|
getPage(params, FieldConstant.CREATED_TIME, false), |
||||
|
getWrapper(params) |
||||
|
); |
||||
|
return getPageData(page, IcHouseChangeRecordDTO.class); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
public List<IcHouseChangeRecordDTO> list(Map<String, Object> params) { |
||||
|
List<IcHouseChangeRecordEntity> entityList = baseDao.selectList(getWrapper(params)); |
||||
|
|
||||
|
return ConvertUtils.sourceToTarget(entityList, IcHouseChangeRecordDTO.class); |
||||
|
} |
||||
|
|
||||
|
private QueryWrapper<IcHouseChangeRecordEntity> getWrapper(Map<String, Object> params){ |
||||
|
String id = (String)params.get(FieldConstant.ID_HUMP); |
||||
|
|
||||
|
QueryWrapper<IcHouseChangeRecordEntity> wrapper = new QueryWrapper<>(); |
||||
|
wrapper.eq(StringUtils.isNotBlank(id), FieldConstant.ID, id); |
||||
|
|
||||
|
return wrapper; |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
public IcHouseChangeRecordDTO get(String id) { |
||||
|
IcHouseChangeRecordEntity entity = baseDao.selectById(id); |
||||
|
return ConvertUtils.sourceToTarget(entity, IcHouseChangeRecordDTO.class); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
@Transactional(rollbackFor = Exception.class) |
||||
|
public void save(IcHouseChangeRecordDTO dto) { |
||||
|
IcHouseChangeRecordEntity entity = ConvertUtils.sourceToTarget(dto, IcHouseChangeRecordEntity.class); |
||||
|
insert(entity); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
@Transactional(rollbackFor = Exception.class) |
||||
|
public void update(IcHouseChangeRecordDTO dto) { |
||||
|
IcHouseChangeRecordEntity entity = ConvertUtils.sourceToTarget(dto, IcHouseChangeRecordEntity.class); |
||||
|
updateById(entity); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
@Transactional(rollbackFor = Exception.class) |
||||
|
public void delete(String[] ids) { |
||||
|
// 逻辑删除(@TableLogic 注解)
|
||||
|
baseDao.deleteBatchIds(Arrays.asList(ids)); |
||||
|
} |
||||
|
|
||||
|
/** |
||||
|
* Desc: 查询房屋变更记录 |
||||
|
* @param tokenDto |
||||
|
* @param formDTO |
||||
|
* @author zxc |
||||
|
* @date 2022/5/10 14:32 |
||||
|
*/ |
||||
|
@Override |
||||
|
public PageData list(TokenDto tokenDto, HouseChangeListFormDTO formDTO) { |
||||
|
PageData<HouseChangeListResultDTO> pageData = new PageData<>(new ArrayList<>(), NumConstant.ZERO); |
||||
|
CustomerStaffInfoCacheResult staffInfo = CustomerStaffRedis.getStaffInfo(tokenDto.getCustomerId(), tokenDto.getUserId()); |
||||
|
if (null == staffInfo){ |
||||
|
throw new EpmetException("未查询到此工作人员"+tokenDto.getUserId()); |
||||
|
} |
||||
|
formDTO.setAgencyId(staffInfo.getAgencyId()); |
||||
|
if (formDTO.getIsPage()){ |
||||
|
PageInfo<HouseChangeListResultDTO> pageInfo = PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize()).doSelectPageInfo(() -> baseDao.getHouseChangeList(formDTO)); |
||||
|
pageData.setList(pageInfo.getList()); |
||||
|
pageData.setTotal(Integer.valueOf(String.valueOf(pageInfo.getTotal()))); |
||||
|
}else { |
||||
|
List<HouseChangeListResultDTO> houseChangeList = baseDao.getHouseChangeList(formDTO); |
||||
|
pageData.setList(houseChangeList); |
||||
|
pageData.setTotal(houseChangeList.size()); |
||||
|
} |
||||
|
return pageData; |
||||
|
} |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,37 @@ |
|||||
|
CREATE TABLE `ic_house_change_record` ( |
||||
|
`ID` varchar(64) NOT NULL COMMENT 'ID', |
||||
|
`CUSTOMER_ID` varchar(64) NOT NULL COMMENT '客户ID', |
||||
|
`AGENCY_ID` varchar(64) NOT NULL COMMENT '组织ID', |
||||
|
`GRID_ID` varchar(64) NOT NULL COMMENT '网格ID', |
||||
|
`NEIGHBOR_HOOD_ID` varchar(64) NOT NULL COMMENT '小区ID', |
||||
|
`BUILDING_ID` varchar(64) NOT NULL COMMENT '楼栋ID', |
||||
|
`BUILDING_UNIT_ID` varchar(64) NOT NULL COMMENT '楼栋单元ID', |
||||
|
`HOUSE_ID` varchar(64) NOT NULL COMMENT '房屋ID', |
||||
|
`CHANGE_BEFORE` varchar(255) NOT NULL COMMENT '变更前', |
||||
|
`CHANGE_AFTER` varchar(255) NOT NULL COMMENT '变更后', |
||||
|
`PIDS` varchar(255) NOT NULL COMMENT '组织ID的所有上级', |
||||
|
`DEL_FLAG` int(11) NOT NULL, |
||||
|
`REVISION` int(11) NOT NULL COMMENT '乐观锁', |
||||
|
`CREATED_BY` varchar(32) NOT NULL COMMENT '创建人', |
||||
|
`CREATED_TIME` datetime NOT NULL COMMENT '创建时间', |
||||
|
`UPDATED_BY` varchar(32) NOT NULL COMMENT '更新人', |
||||
|
`UPDATED_TIME` datetime NOT NULL COMMENT '更新时间', |
||||
|
PRIMARY KEY (`ID`) |
||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='房屋变更记录表'; |
||||
|
|
||||
|
CREATE TABLE `ic_house_change_detail` ( |
||||
|
`ID` varchar(64) NOT NULL COMMENT 'ID', |
||||
|
`CUSTOMER_ID` varchar(64) NOT NULL COMMENT '客户id', |
||||
|
`RECORD_ID` varchar(64) NOT NULL COMMENT '记录ID', |
||||
|
`CHANGE_COL` varchar(64) NOT NULL COMMENT '变更字段,HOUSE_TYPE:房屋类型,PURPOSE:房屋用途,RENT_FLAG:房屋状态,OWNER_NAME:房主姓名,OWNER_PHONE:房主电话,OWNER_ID_CARD:房主身份证', |
||||
|
`CHANGE_BEFORE` varchar(255) NOT NULL COMMENT '变更前', |
||||
|
`CHANGE_AFTER` varchar(255) NOT NULL COMMENT '变更后', |
||||
|
`DEL_FLAG` int(1) NOT NULL, |
||||
|
`REVISION` int(11) NOT NULL COMMENT '乐观锁', |
||||
|
`CREATED_BY` varchar(32) NOT NULL COMMENT '创建人', |
||||
|
`CREATED_TIME` datetime NOT NULL COMMENT '创建时间', |
||||
|
`UPDATED_BY` varchar(32) NOT NULL COMMENT '更新人', |
||||
|
`UPDATED_TIME` datetime NOT NULL COMMENT '更新时间', |
||||
|
PRIMARY KEY (`ID`) USING BTREE, |
||||
|
KEY `recordId` (`RECORD_ID`) |
||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='房屋变更详情表'; |
||||
@ -0,0 +1,6 @@ |
|||||
|
<?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.IcHouseChangeDetailDao"> |
||||
|
|
||||
|
</mapper> |
||||
@ -0,0 +1,46 @@ |
|||||
|
<?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.IcHouseChangeRecordDao"> |
||||
|
|
||||
|
<!-- 获取房屋变更记录 --> |
||||
|
<select id="getHouseChangeList" resultType="com.epmet.dto.result.HouseChangeListResultDTO"> |
||||
|
SELECT |
||||
|
CONCAT(a.ORGANIZATION_NAME,'-',g.GRID_NAME) AS gridName, |
||||
|
CONCAT(h.NEIGHBOR_HOOD_NAME,'-',house.HOUSE_NAME) AS houseName, |
||||
|
change_after, |
||||
|
change_before, |
||||
|
DATE_FORMAT(r.CREATED_TIME,'%Y-%m-%d') AS changeTime |
||||
|
FROM ic_house_change_record r |
||||
|
LEFT JOIN customer_grid g ON (r.GRID_ID = g.ID AND g.DEL_FLAG = 0) |
||||
|
LEFT JOIN customer_agency a ON (g.PID = a.ID AND a.DEL_FLAG = '0') |
||||
|
INNER JOIN ic_neighbor_hood h ON (r.NEIGHBOR_HOOD_ID = h.ID AND h.DEL_FLAG = '0') |
||||
|
INNER JOIN ic_house house ON (house.ID = r.HOUSE_ID AND house.DEL_FLAG = '0') |
||||
|
WHERE r.DEL_FLAG = 0 |
||||
|
<if test='null != startDate and startDate != "" '> |
||||
|
AND DATE_FORMAT(r.CREATED_TIME,'%Y%m%d') >= #{startDate} |
||||
|
</if> |
||||
|
<if test='null != endDate and endDate != "" '> |
||||
|
AND DATE_FORMAT(r.CREATED_TIME,'%Y%m%d') <![CDATA[<=]]> #{endDate} |
||||
|
</if> |
||||
|
<if test='null != houseId and houseId != "" '> |
||||
|
AND r.HOUSE_ID = #{houseId} |
||||
|
</if> |
||||
|
<if test='null != buildingUnitId and buildingUnitId != "" '> |
||||
|
AND r.BUILDING_UNIT_ID = #{buildingUnitId} |
||||
|
</if> |
||||
|
<if test='null != buildingId and buildingId != "" '> |
||||
|
AND r.BUILDING_ID = #{buildingId} |
||||
|
</if> |
||||
|
<if test='null != neighborHoodId and neighborHoodId != "" '> |
||||
|
AND r.NEIGHBOR_HOOD_ID = #{neighborHoodId} |
||||
|
</if> |
||||
|
<if test='null != gridId and gridId != "" '> |
||||
|
AND r.GRID_ID = #{gridId} |
||||
|
</if> |
||||
|
<if test='null != agencyId and agencyId != "" '> |
||||
|
AND CONCAT(r.PIDS,':',r.AGENCY_ID) LIKE CONCAT('%',#{agencyId},'%') |
||||
|
</if> |
||||
|
ORDER BY r.CREATED_TIME DESC,r.HOUSE_ID |
||||
|
</select> |
||||
|
</mapper> |
||||
@ -0,0 +1,131 @@ |
|||||
|
package com.epmet.dto; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
|
||||
|
import javax.validation.constraints.NotBlank; |
||||
|
import java.io.Serializable; |
||||
|
import java.util.Date; |
||||
|
|
||||
|
|
||||
|
/** |
||||
|
* 死亡名单表 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-05 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class ChangeDeathDTO implements Serializable { |
||||
|
|
||||
|
private static final long serialVersionUID = 1L; |
||||
|
|
||||
|
|
||||
|
/** |
||||
|
* 主键 |
||||
|
*/ |
||||
|
private String id; |
||||
|
|
||||
|
/** |
||||
|
* epmet用户主键 |
||||
|
*/ |
||||
|
@NotBlank(message = "用户ID不能为空") |
||||
|
private String userId; |
||||
|
|
||||
|
/** |
||||
|
* epmet网格ID |
||||
|
*/ |
||||
|
private String gridId; |
||||
|
|
||||
|
/** |
||||
|
* 姓名 |
||||
|
*/ |
||||
|
@NotBlank(message = "姓名不能为空") |
||||
|
private String name; |
||||
|
|
||||
|
/** |
||||
|
* 身份证 |
||||
|
*/ |
||||
|
@NotBlank(message = "身份证不能为空") |
||||
|
private String idCard; |
||||
|
|
||||
|
/** |
||||
|
* 手机号 |
||||
|
*/ |
||||
|
@NotBlank(message = "手机号不能为空") |
||||
|
private String mobile; |
||||
|
|
||||
|
/** |
||||
|
* 性别 0女 1男 |
||||
|
*/ |
||||
|
@NotBlank(message = "性别不能为空") |
||||
|
private String gender; |
||||
|
|
||||
|
/** |
||||
|
* 类型 0 租客 1 房东 |
||||
|
*/ |
||||
|
private String type; |
||||
|
|
||||
|
/** |
||||
|
* 加入时间 |
||||
|
*/ |
||||
|
private String joinDate; |
||||
|
|
||||
|
/** |
||||
|
* 加入原因 |
||||
|
*/ |
||||
|
private String joinReason; |
||||
|
|
||||
|
/** |
||||
|
* 移除时间 |
||||
|
*/ |
||||
|
private String removeDate; |
||||
|
|
||||
|
/** |
||||
|
* 移除原因 |
||||
|
*/ |
||||
|
private String removeReason; |
||||
|
|
||||
|
/** |
||||
|
* 删除标记 0:未删除,1:已删除 |
||||
|
*/ |
||||
|
private String delFlag; |
||||
|
|
||||
|
/** |
||||
|
* 乐观锁 |
||||
|
*/ |
||||
|
private Integer revision; |
||||
|
|
||||
|
/** |
||||
|
* 创建人 |
||||
|
*/ |
||||
|
private String createdBy; |
||||
|
|
||||
|
/** |
||||
|
* 创建时间 |
||||
|
*/ |
||||
|
private Date createdTime; |
||||
|
|
||||
|
/** |
||||
|
* 更新人 |
||||
|
*/ |
||||
|
private String updatedBy; |
||||
|
|
||||
|
/** |
||||
|
* 更新时间 |
||||
|
*/ |
||||
|
private Date updatedTime; |
||||
|
|
||||
|
/** |
||||
|
* 客户ID |
||||
|
*/ |
||||
|
private String customerId; |
||||
|
|
||||
|
/** |
||||
|
* 是否保存为福利人员 |
||||
|
*/ |
||||
|
private Boolean welfareFlag; |
||||
|
|
||||
|
/** |
||||
|
* 当前登录用户id |
||||
|
*/ |
||||
|
private String staffId; |
||||
|
} |
||||
@ -0,0 +1,214 @@ |
|||||
|
package com.epmet.dto; |
||||
|
|
||||
|
import com.alibaba.fastjson.annotation.JSONField; |
||||
|
import com.fasterxml.jackson.annotation.JsonFormat; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
import javax.validation.constraints.NotNull; |
||||
|
import java.io.Serializable; |
||||
|
import java.util.Date; |
||||
|
|
||||
|
|
||||
|
/** |
||||
|
* 合同表 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-06 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class ChangeRelocationDTO implements Serializable { |
||||
|
|
||||
|
private static final long serialVersionUID = 1L; |
||||
|
|
||||
|
/** |
||||
|
* 主键 |
||||
|
*/ |
||||
|
private String id; |
||||
|
|
||||
|
/** |
||||
|
* 姓名 |
||||
|
*/ |
||||
|
private String name; |
||||
|
|
||||
|
/** |
||||
|
* 性别 |
||||
|
*/ |
||||
|
private String gender; |
||||
|
|
||||
|
/** |
||||
|
* 年龄 |
||||
|
*/ |
||||
|
private String age; |
||||
|
|
||||
|
/** |
||||
|
* 组织PID |
||||
|
*/ |
||||
|
private String pid; |
||||
|
|
||||
|
/** |
||||
|
* 组织ID |
||||
|
*/ |
||||
|
private String agencyId; |
||||
|
|
||||
|
/** |
||||
|
* 组织名 |
||||
|
*/ |
||||
|
private String agencyName; |
||||
|
|
||||
|
/** |
||||
|
* 组织ID |
||||
|
*/ |
||||
|
private String gridId; |
||||
|
|
||||
|
/** |
||||
|
* 组织名 |
||||
|
*/ |
||||
|
private String gridName; |
||||
|
|
||||
|
/** |
||||
|
* 房屋小区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; |
||||
|
|
||||
|
/** |
||||
|
* 操作类型【客户外out,客户内in】 |
||||
|
*/ |
||||
|
private String type; |
||||
|
|
||||
|
/** |
||||
|
* 原房主姓名 |
||||
|
*/ |
||||
|
private String ownerName; |
||||
|
|
||||
|
/** |
||||
|
* 原网格信息 |
||||
|
*/ |
||||
|
private String oldDept; |
||||
|
|
||||
|
/** |
||||
|
* 原房屋信息 |
||||
|
*/ |
||||
|
private String oldAddress; |
||||
|
|
||||
|
/** |
||||
|
* 原房间号 |
||||
|
*/ |
||||
|
private String oldHome; |
||||
|
|
||||
|
/** |
||||
|
* 浅出原因 |
||||
|
*/ |
||||
|
private String reason; |
||||
|
|
||||
|
/** |
||||
|
* 删除标记 0:未删除,1:已删除 |
||||
|
*/ |
||||
|
private String delFlag; |
||||
|
|
||||
|
/** |
||||
|
* 乐观锁 |
||||
|
*/ |
||||
|
private Integer revision; |
||||
|
|
||||
|
/** |
||||
|
* 创建人 |
||||
|
*/ |
||||
|
private String createdBy; |
||||
|
|
||||
|
/** |
||||
|
* 创建时间 |
||||
|
*/ |
||||
|
private Date createdTime; |
||||
|
|
||||
|
/** |
||||
|
* 更新人 |
||||
|
*/ |
||||
|
private String updatedBy; |
||||
|
|
||||
|
/** |
||||
|
* 更新时间 |
||||
|
*/ |
||||
|
private Date updatedTime; |
||||
|
|
||||
|
/** |
||||
|
* 客户ID |
||||
|
*/ |
||||
|
private String customerId; |
||||
|
|
||||
|
/** |
||||
|
* 迁出时间 |
||||
|
*/ |
||||
|
@JsonFormat(pattern = "yyyy-MM-dd",timezone = "GMT+8") |
||||
|
@JSONField(format = "yyyy-MM-dd") |
||||
|
private Date outOfTime; |
||||
|
|
||||
|
/** |
||||
|
* 身份证号 |
||||
|
*/ |
||||
|
private String idCard; |
||||
|
|
||||
|
/** |
||||
|
* 手机号 |
||||
|
*/ |
||||
|
private String mobile; |
||||
|
|
||||
|
/** |
||||
|
* epmet用户主键 |
||||
|
*/ |
||||
|
private String icUserId; |
||||
|
|
||||
|
/** |
||||
|
* 是否保存为福利人员 |
||||
|
*/ |
||||
|
private Boolean welfareFlag; |
||||
|
|
||||
|
/** |
||||
|
* 当前登录用户id |
||||
|
*/ |
||||
|
private String staffId; |
||||
|
/** |
||||
|
* 调动时间 |
||||
|
*/ |
||||
|
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") |
||||
|
private Date transferTime; |
||||
|
} |
||||
@ -0,0 +1,115 @@ |
|||||
|
package com.epmet.dto; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
|
||||
|
import java.io.Serializable; |
||||
|
import java.util.Date; |
||||
|
|
||||
|
|
||||
|
/** |
||||
|
* 福利表 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-09 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class ChangeWelfareDTO implements Serializable { |
||||
|
|
||||
|
private static final long serialVersionUID = 1L; |
||||
|
|
||||
|
/** |
||||
|
* 主键 |
||||
|
*/ |
||||
|
private String id; |
||||
|
|
||||
|
/** |
||||
|
* epmet用户主键 |
||||
|
*/ |
||||
|
private String userId; |
||||
|
|
||||
|
/** |
||||
|
* epmet网格ID |
||||
|
*/ |
||||
|
private String gridId; |
||||
|
|
||||
|
/** |
||||
|
* 姓名 |
||||
|
*/ |
||||
|
private String name; |
||||
|
|
||||
|
/** |
||||
|
* 身份证 |
||||
|
*/ |
||||
|
private String idCard; |
||||
|
|
||||
|
/** |
||||
|
* 手机号 |
||||
|
*/ |
||||
|
private String mobile; |
||||
|
|
||||
|
/** |
||||
|
* 性别 0女 1男 |
||||
|
*/ |
||||
|
private String gender; |
||||
|
|
||||
|
/** |
||||
|
* 类型 |
||||
|
*/ |
||||
|
private String type; |
||||
|
|
||||
|
/** |
||||
|
* 加入时间 |
||||
|
*/ |
||||
|
private String joinDate; |
||||
|
|
||||
|
/** |
||||
|
* 加入原因 |
||||
|
*/ |
||||
|
private String joinReason; |
||||
|
|
||||
|
/** |
||||
|
* 移除时间 |
||||
|
*/ |
||||
|
private String removeDate; |
||||
|
|
||||
|
/** |
||||
|
* 移除原因 |
||||
|
*/ |
||||
|
private String removeReason; |
||||
|
|
||||
|
/** |
||||
|
* 删除标记 0:未删除,1:已删除 |
||||
|
*/ |
||||
|
private String delFlag; |
||||
|
|
||||
|
/** |
||||
|
* 乐观锁 |
||||
|
*/ |
||||
|
private Integer revision; |
||||
|
|
||||
|
/** |
||||
|
* 创建人 |
||||
|
*/ |
||||
|
private String createdBy; |
||||
|
|
||||
|
/** |
||||
|
* 创建时间 |
||||
|
*/ |
||||
|
private Date createdTime; |
||||
|
|
||||
|
/** |
||||
|
* 更新人 |
||||
|
*/ |
||||
|
private String updatedBy; |
||||
|
|
||||
|
/** |
||||
|
* 更新时间 |
||||
|
*/ |
||||
|
private Date updatedTime; |
||||
|
|
||||
|
/** |
||||
|
* 客户ID |
||||
|
*/ |
||||
|
private String customerId; |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,20 @@ |
|||||
|
package com.epmet.dto; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
|
||||
|
import javax.validation.constraints.NotBlank; |
||||
|
import java.io.Serializable; |
||||
|
|
||||
|
/** |
||||
|
* @program: epmet-plugins |
||||
|
* @description: |
||||
|
* @author: wangtong |
||||
|
* @create: 2022-05-09 13:52 |
||||
|
**/ |
||||
|
@Data |
||||
|
public class CheckWelfareByIdCardDTO implements Serializable { |
||||
|
|
||||
|
|
||||
|
@NotBlank(message = "身份证不能为空") |
||||
|
private String idCard; |
||||
|
} |
||||
@ -0,0 +1,169 @@ |
|||||
|
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-05-09 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class IcMoveInRecordDTO implements Serializable { |
||||
|
|
||||
|
private static final long serialVersionUID = 1L; |
||||
|
|
||||
|
/** |
||||
|
* 唯一标识 |
||||
|
*/ |
||||
|
private String id; |
||||
|
|
||||
|
/** |
||||
|
* 客户Id customer.id |
||||
|
*/ |
||||
|
private String customerId; |
||||
|
|
||||
|
/** |
||||
|
* 组织Id |
||||
|
*/ |
||||
|
private String agencyId; |
||||
|
|
||||
|
/** |
||||
|
* 组织的pids |
||||
|
*/ |
||||
|
private String pids; |
||||
|
|
||||
|
/** |
||||
|
* 网格ID |
||||
|
*/ |
||||
|
private String gridId; |
||||
|
|
||||
|
/** |
||||
|
* 所属小区ID |
||||
|
*/ |
||||
|
private String villageId; |
||||
|
|
||||
|
/** |
||||
|
* 所属楼宇Id |
||||
|
*/ |
||||
|
private String buildId; |
||||
|
|
||||
|
/** |
||||
|
* 单元id |
||||
|
*/ |
||||
|
private String unitId; |
||||
|
|
||||
|
/** |
||||
|
* 所属家庭Id |
||||
|
*/ |
||||
|
private String homeId; |
||||
|
|
||||
|
/** |
||||
|
* 姓名 |
||||
|
*/ |
||||
|
private String name; |
||||
|
|
||||
|
/** |
||||
|
* 是否享受福利【否:0 是:1】 |
||||
|
*/ |
||||
|
private String isWeifare; |
||||
|
|
||||
|
/** |
||||
|
* 手机号 |
||||
|
*/ |
||||
|
private String mobile; |
||||
|
|
||||
|
/** |
||||
|
* 身份证号 |
||||
|
*/ |
||||
|
private String idCard; |
||||
|
|
||||
|
/** |
||||
|
* 性别(1男2女0未知) |
||||
|
*/ |
||||
|
private String gender; |
||||
|
|
||||
|
/** |
||||
|
* 年龄 |
||||
|
*/ |
||||
|
private Integer age; |
||||
|
|
||||
|
/** |
||||
|
* 迁入时间 |
||||
|
*/ |
||||
|
private Date inTime; |
||||
|
|
||||
|
/** |
||||
|
* 迁入原因 |
||||
|
*/ |
||||
|
private String inReason; |
||||
|
|
||||
|
/** |
||||
|
* 来源地区编码 |
||||
|
*/ |
||||
|
private String sourceAddressCode; |
||||
|
|
||||
|
/** |
||||
|
* 来源地区编码全路径 |
||||
|
*/ |
||||
|
private String sourceAddressPathCode; |
||||
|
|
||||
|
/** |
||||
|
* 来源地区地址 |
||||
|
*/ |
||||
|
private String sourceAddress; |
||||
|
|
||||
|
/** |
||||
|
* 详细地址 |
||||
|
*/ |
||||
|
private String address; |
||||
|
|
||||
|
/** |
||||
|
* 迁移证号码 |
||||
|
*/ |
||||
|
private String moveNumber; |
||||
|
|
||||
|
/** |
||||
|
* 户主姓名 |
||||
|
*/ |
||||
|
private String householderName; |
||||
|
|
||||
|
/** |
||||
|
* 与户主关系[字典表] |
||||
|
*/ |
||||
|
private String householderRelation; |
||||
|
|
||||
|
/** |
||||
|
* 删除标识 0.未删除 1.已删除 |
||||
|
*/ |
||||
|
private Integer delFlag; |
||||
|
|
||||
|
/** |
||||
|
* 乐观锁 |
||||
|
*/ |
||||
|
private Integer revision; |
||||
|
|
||||
|
/** |
||||
|
* 创建人 |
||||
|
*/ |
||||
|
private String createdBy; |
||||
|
|
||||
|
/** |
||||
|
* 创建时间 |
||||
|
*/ |
||||
|
private Date createdTime; |
||||
|
|
||||
|
/** |
||||
|
* 更新人 |
||||
|
*/ |
||||
|
private String updatedBy; |
||||
|
|
||||
|
/** |
||||
|
* 更新时间 |
||||
|
*/ |
||||
|
private Date updatedTime; |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,20 @@ |
|||||
|
package com.epmet.dto.result; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
|
||||
|
import java.io.Serializable; |
||||
|
|
||||
|
/** |
||||
|
* |
||||
|
* 房屋的户主信息 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class HouseHolderResDTO implements Serializable { |
||||
|
private static final long serialVersionUID = 8849057608809731937L; |
||||
|
|
||||
|
/** |
||||
|
* 户主姓名:取的是家庭信息-与户主关系-本人的居民 |
||||
|
*/ |
||||
|
private String name; |
||||
|
private String id; |
||||
|
} |
||||
@ -0,0 +1,67 @@ |
|||||
|
package com.epmet.dto.result; |
||||
|
|
||||
|
import com.epmet.commons.tools.constant.StrConstant; |
||||
|
import com.epmet.commons.tools.validator.group.CustomerClientShowGroup; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
import javax.validation.constraints.NotBlank; |
||||
|
import java.io.Serializable; |
||||
|
|
||||
|
/** |
||||
|
* 迁入管理、出生管理,勾选了补充居民信息,输入身份证号后,调用接口校验是否可继续执行 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class SyncResiResDTO implements Serializable { |
||||
|
private static final long serialVersionUID = 673439146165836938L; |
||||
|
|
||||
|
public interface FormShow extends CustomerClientShowGroup { |
||||
|
} |
||||
|
|
||||
|
public interface FormInternal { |
||||
|
} |
||||
|
|
||||
|
/** |
||||
|
* 身份证号 |
||||
|
*/ |
||||
|
@NotBlank(message = "身份证号不能为空", groups = FormShow.class) |
||||
|
private String idCard; |
||||
|
/** |
||||
|
* 当前登录用户所属的组织id |
||||
|
*/ |
||||
|
@NotBlank(message = "当前登录用户所属组织不能为空", groups = FormInternal.class) |
||||
|
private String agencyId; |
||||
|
|
||||
|
private String customerId; |
||||
|
/** |
||||
|
* true:可以迁入;flase:不可迁入 |
||||
|
*/ |
||||
|
private Boolean moveInstatus; |
||||
|
/** |
||||
|
* 身份证号已存在的居民,返回其所属社区名称 |
||||
|
*/ |
||||
|
private String resiAgencyName; |
||||
|
|
||||
|
/** |
||||
|
* 身份证号已存在的居民,返回其所属社区id |
||||
|
*/ |
||||
|
private String resiAgencyId; |
||||
|
|
||||
|
/** |
||||
|
* 身份证号已存在的居民,返回其房屋id |
||||
|
*/ |
||||
|
private String resiHomeId; |
||||
|
private String status; |
||||
|
private String icResiUserId; |
||||
|
|
||||
|
public SyncResiResDTO(String customerId, String idCard, String agencyId) { |
||||
|
this.idCard = idCard; |
||||
|
this.customerId = customerId; |
||||
|
this.agencyId = agencyId; |
||||
|
this.moveInstatus = true; |
||||
|
this.resiAgencyId = StrConstant.EPMETY_STR; |
||||
|
this.resiAgencyName = StrConstant.EPMETY_STR; |
||||
|
this.resiHomeId = StrConstant.EPMETY_STR; |
||||
|
this.status=StrConstant.EPMETY_STR; |
||||
|
this.icResiUserId=StrConstant.EPMETY_STR; |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,84 @@ |
|||||
|
package com.epmet.controller; |
||||
|
|
||||
|
import com.epmet.commons.tools.annotation.LoginUser; |
||||
|
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.ChangeDeathDTO; |
||||
|
import com.epmet.excel.ChangeDeathExcel; |
||||
|
import com.epmet.service.ChangeDeathService; |
||||
|
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-05-05 |
||||
|
*/ |
||||
|
@RestController |
||||
|
@RequestMapping("rentDeath") |
||||
|
public class ChangeDeathController { |
||||
|
|
||||
|
@Autowired |
||||
|
private ChangeDeathService changeDeathService; |
||||
|
|
||||
|
@RequestMapping("page") |
||||
|
public Result<PageData<ChangeDeathDTO>> page(@RequestParam Map<String, Object> params){ |
||||
|
PageData<ChangeDeathDTO> page = changeDeathService.page(params); |
||||
|
return new Result<PageData<ChangeDeathDTO>>().ok(page); |
||||
|
} |
||||
|
|
||||
|
@RequestMapping(value = "{id}", method = {RequestMethod.POST, RequestMethod.GET}) |
||||
|
public Result<ChangeDeathDTO> get(@PathVariable("id") String id){ |
||||
|
ChangeDeathDTO data = changeDeathService.get(id); |
||||
|
return new Result<ChangeDeathDTO>().ok(data); |
||||
|
} |
||||
|
|
||||
|
@NoRepeatSubmit |
||||
|
@PostMapping("save") |
||||
|
public Result save(@LoginUser TokenDto tokenDto, @RequestBody ChangeDeathDTO dto){ |
||||
|
dto.setStaffId(tokenDto.getUserId()); |
||||
|
//效验数据
|
||||
|
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class); |
||||
|
return changeDeathService.save(dto); |
||||
|
} |
||||
|
|
||||
|
@NoRepeatSubmit |
||||
|
@PostMapping("update") |
||||
|
public Result update(@RequestBody ChangeDeathDTO dto){ |
||||
|
//效验数据
|
||||
|
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class); |
||||
|
changeDeathService.update(dto); |
||||
|
return new Result(); |
||||
|
} |
||||
|
|
||||
|
@RequestMapping(value = "delete", method = {RequestMethod.POST, RequestMethod.DELETE}) |
||||
|
public Result delete(@RequestBody String[] ids){ |
||||
|
//效验数据
|
||||
|
AssertUtils.isArrayEmpty(ids, "id"); |
||||
|
changeDeathService.delete(ids); |
||||
|
return new Result(); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("export") |
||||
|
public void export(@RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception { |
||||
|
List<ChangeDeathDTO> list = changeDeathService.list(params); |
||||
|
ExcelUtils.exportExcelToTarget(response, null, list, ChangeDeathExcel.class); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
||||
@ -0,0 +1,98 @@ |
|||||
|
package com.epmet.controller; |
||||
|
|
||||
|
import com.epmet.commons.tools.annotation.LoginUser; |
||||
|
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.ChangeRelocationDTO; |
||||
|
import com.epmet.excel.ChangeRelocationExcel; |
||||
|
import com.epmet.service.ChangeRelocationService; |
||||
|
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-05-06 |
||||
|
*/ |
||||
|
@RestController |
||||
|
@RequestMapping("changeRelocation") |
||||
|
public class ChangeRelocationController { |
||||
|
|
||||
|
@Autowired |
||||
|
private ChangeRelocationService changeRelocationService; |
||||
|
|
||||
|
@RequestMapping("page") |
||||
|
public Result<PageData<ChangeRelocationDTO>> page(@RequestParam Map<String, Object> params){ |
||||
|
PageData<ChangeRelocationDTO> page = changeRelocationService.page(params); |
||||
|
return new Result<PageData<ChangeRelocationDTO>>().ok(page); |
||||
|
} |
||||
|
|
||||
|
@RequestMapping(value = "{id}", method = {RequestMethod.POST, RequestMethod.GET}) |
||||
|
public Result<ChangeRelocationDTO> get(@PathVariable("id") String id){ |
||||
|
ChangeRelocationDTO data = changeRelocationService.get(id); |
||||
|
return new Result<ChangeRelocationDTO>().ok(data); |
||||
|
} |
||||
|
|
||||
|
@NoRepeatSubmit |
||||
|
@PostMapping("save") |
||||
|
public Result save(@RequestBody ChangeRelocationDTO dto){ |
||||
|
//效验数据
|
||||
|
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class); |
||||
|
changeRelocationService.save(dto); |
||||
|
return new Result(); |
||||
|
} |
||||
|
|
||||
|
@NoRepeatSubmit |
||||
|
@PostMapping("update") |
||||
|
public Result update(@RequestBody ChangeRelocationDTO dto){ |
||||
|
//效验数据
|
||||
|
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class); |
||||
|
changeRelocationService.update(dto); |
||||
|
return new Result(); |
||||
|
} |
||||
|
|
||||
|
@RequestMapping(value = "delete", method = {RequestMethod.POST, RequestMethod.DELETE}) |
||||
|
public Result delete(@RequestBody String[] ids){ |
||||
|
//效验数据
|
||||
|
AssertUtils.isArrayEmpty(ids, "id"); |
||||
|
changeRelocationService.delete(ids); |
||||
|
return new Result(); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("export") |
||||
|
public void export(@RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception { |
||||
|
List<ChangeRelocationDTO> list = changeRelocationService.list(params); |
||||
|
ExcelUtils.exportExcelToTarget(response, null, list, ChangeRelocationExcel.class); |
||||
|
} |
||||
|
|
||||
|
/** |
||||
|
* @describe: 保存迁出信息 |
||||
|
* @author wangtong |
||||
|
* @date 2022/5/7 9:49 |
||||
|
* @params [dto] |
||||
|
* @return com.epmet.commons.tools.utils.Result |
||||
|
*/ |
||||
|
@NoRepeatSubmit |
||||
|
@PostMapping("saveOutOfInfo") |
||||
|
public Result saveOutOfInfo(@LoginUser TokenDto tokenDto, @RequestBody ChangeRelocationDTO dto){ |
||||
|
dto.setStaffId(tokenDto.getUserId()); |
||||
|
//效验数据
|
||||
|
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class); |
||||
|
return changeRelocationService.saveOutOfInfo(dto); |
||||
|
} |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,109 @@ |
|||||
|
package com.epmet.controller; |
||||
|
|
||||
|
import com.epmet.commons.tools.aop.NoRepeatSubmit; |
||||
|
import com.epmet.commons.tools.page.PageData; |
||||
|
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.ChangeWelfareDTO; |
||||
|
import com.epmet.dto.CheckWelfareByIdCardDTO; |
||||
|
import com.epmet.excel.ChangeWelfareExcel; |
||||
|
import com.epmet.service.ChangeWelfareService; |
||||
|
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-05-09 |
||||
|
*/ |
||||
|
@RestController |
||||
|
@RequestMapping("changeWelfare") |
||||
|
public class ChangeWelfareController { |
||||
|
|
||||
|
@Autowired |
||||
|
private ChangeWelfareService changeWelfareService; |
||||
|
|
||||
|
@RequestMapping("page") |
||||
|
public Result<PageData<ChangeWelfareDTO>> page(@RequestParam Map<String, Object> params){ |
||||
|
PageData<ChangeWelfareDTO> page = changeWelfareService.page(params); |
||||
|
return new Result<PageData<ChangeWelfareDTO>>().ok(page); |
||||
|
} |
||||
|
|
||||
|
@RequestMapping(value = "{id}", method = {RequestMethod.POST, RequestMethod.GET}) |
||||
|
public Result<ChangeWelfareDTO> get(@PathVariable("id") String id){ |
||||
|
ChangeWelfareDTO data = changeWelfareService.get(id); |
||||
|
return new Result<ChangeWelfareDTO>().ok(data); |
||||
|
} |
||||
|
|
||||
|
@NoRepeatSubmit |
||||
|
@PostMapping("save") |
||||
|
public Result save(@RequestBody ChangeWelfareDTO dto){ |
||||
|
//效验数据
|
||||
|
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class); |
||||
|
return changeWelfareService.save(dto); |
||||
|
} |
||||
|
|
||||
|
@NoRepeatSubmit |
||||
|
@PostMapping("update") |
||||
|
public Result update(@RequestBody ChangeWelfareDTO dto){ |
||||
|
//效验数据
|
||||
|
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class); |
||||
|
changeWelfareService.update(dto); |
||||
|
return new Result(); |
||||
|
} |
||||
|
|
||||
|
@RequestMapping(value = "delete", method = {RequestMethod.POST, RequestMethod.DELETE}) |
||||
|
public Result delete(@RequestBody String[] ids){ |
||||
|
//效验数据
|
||||
|
AssertUtils.isArrayEmpty(ids, "id"); |
||||
|
changeWelfareService.delete(ids); |
||||
|
return new Result(); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("export") |
||||
|
public void export(@RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception { |
||||
|
List<ChangeWelfareDTO> list = changeWelfareService.list(params); |
||||
|
ExcelUtils.exportExcelToTarget(response, null, list, ChangeWelfareExcel.class); |
||||
|
} |
||||
|
|
||||
|
/** |
||||
|
* @describe: 移除福利人员 |
||||
|
* @author wangtong |
||||
|
* @date 2022/5/9 11:11 |
||||
|
* @params [dto] |
||||
|
* @return com.epmet.commons.tools.utils.Result |
||||
|
*/ |
||||
|
@NoRepeatSubmit |
||||
|
@PostMapping("removeWelfare") |
||||
|
public Result removeWelfare(@RequestBody ChangeWelfareDTO dto){ |
||||
|
return changeWelfareService.removeWelfare(dto); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
/** |
||||
|
* @describe: 通过身份证号查询是否属于福利人员,是-true,否-false |
||||
|
* @author wangtong |
||||
|
* @date 2022/5/9 13:52 |
||||
|
* @params [dto] |
||||
|
* @return com.epmet.commons.tools.utils.Result |
||||
|
*/ |
||||
|
@NoRepeatSubmit |
||||
|
@GetMapping("checkWelfareByIdCard") |
||||
|
public Boolean checkWelfareByIdCard(CheckWelfareByIdCardDTO dto){ |
||||
|
//效验数据
|
||||
|
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class); |
||||
|
return changeWelfareService.checkWelfareByIdCard(dto); |
||||
|
} |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,83 @@ |
|||||
|
package com.epmet.controller; |
||||
|
|
||||
|
import com.epmet.commons.tools.aop.NoRepeatSubmit; |
||||
|
import com.epmet.commons.tools.page.PageData; |
||||
|
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.IcMoveInRecordDTO; |
||||
|
import com.epmet.excel.IcMoveInRecordExcel; |
||||
|
import com.epmet.service.IcMoveInRecordService; |
||||
|
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-05-09 |
||||
|
*/ |
||||
|
@RestController |
||||
|
@RequestMapping("icMoveIn") |
||||
|
public class IcMoveInRecordController { |
||||
|
|
||||
|
@Autowired |
||||
|
private IcMoveInRecordService icMoveInRecordService; |
||||
|
|
||||
|
|
||||
|
@RequestMapping(value = "{id}",method = {RequestMethod.POST,RequestMethod.GET}) |
||||
|
public Result<IcMoveInRecordDTO> get(@PathVariable("id") String id){ |
||||
|
IcMoveInRecordDTO data = icMoveInRecordService.get(id); |
||||
|
return new Result<IcMoveInRecordDTO>().ok(data); |
||||
|
} |
||||
|
|
||||
|
@RequestMapping("list") |
||||
|
public Result<PageData<IcMoveInRecordDTO>> page(@RequestParam Map<String, Object> params){ |
||||
|
PageData<IcMoveInRecordDTO> page = icMoveInRecordService.page(params); |
||||
|
return new Result<PageData<IcMoveInRecordDTO>>().ok(page); |
||||
|
} |
||||
|
|
||||
|
@NoRepeatSubmit |
||||
|
@PostMapping("add") |
||||
|
public Result save(@RequestBody IcMoveInRecordDTO dto){ |
||||
|
//效验数据
|
||||
|
ValidatorUtils.validateEntity(dto, AddGroup.class, DefaultGroup.class); |
||||
|
icMoveInRecordService.save(dto); |
||||
|
return new Result(); |
||||
|
} |
||||
|
|
||||
|
@NoRepeatSubmit |
||||
|
@PostMapping("edit") |
||||
|
public Result update(@RequestBody IcMoveInRecordDTO dto){ |
||||
|
//效验数据
|
||||
|
ValidatorUtils.validateEntity(dto, UpdateGroup.class, DefaultGroup.class); |
||||
|
icMoveInRecordService.update(dto); |
||||
|
return new Result(); |
||||
|
} |
||||
|
|
||||
|
@PostMapping("delete") |
||||
|
public Result delete(@RequestBody String[] ids){ |
||||
|
//效验数据
|
||||
|
AssertUtils.isArrayEmpty(ids, "id"); |
||||
|
icMoveInRecordService.delete(ids); |
||||
|
return new Result(); |
||||
|
} |
||||
|
|
||||
|
@GetMapping("export") |
||||
|
public void export(@RequestParam Map<String, Object> params, HttpServletResponse response) throws Exception { |
||||
|
List<IcMoveInRecordDTO> list = icMoveInRecordService.list(params); |
||||
|
ExcelUtils.exportExcelToTarget(response, null, list, IcMoveInRecordExcel.class); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
||||
@ -0,0 +1,16 @@ |
|||||
|
package com.epmet.dao; |
||||
|
|
||||
|
import com.epmet.commons.mybatis.dao.BaseDao; |
||||
|
import com.epmet.entity.ChangeDeathEntity; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
|
||||
|
/** |
||||
|
* 死亡名单表 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-05 |
||||
|
*/ |
||||
|
@Mapper |
||||
|
public interface ChangeDeathDao extends BaseDao<ChangeDeathEntity> { |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,16 @@ |
|||||
|
package com.epmet.dao; |
||||
|
|
||||
|
import com.epmet.commons.mybatis.dao.BaseDao; |
||||
|
import com.epmet.entity.ChangeRelocationEntity; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
|
||||
|
/** |
||||
|
* 合同表 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-06 |
||||
|
*/ |
||||
|
@Mapper |
||||
|
public interface ChangeRelocationDao extends BaseDao<ChangeRelocationEntity> { |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,35 @@ |
|||||
|
package com.epmet.dao; |
||||
|
|
||||
|
import com.epmet.commons.mybatis.dao.BaseDao; |
||||
|
import com.epmet.dto.ChangeWelfareDTO; |
||||
|
import com.epmet.entity.ChangeWelfareEntity; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
import org.apache.ibatis.annotations.Param; |
||||
|
|
||||
|
/** |
||||
|
* 福利表 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-09 |
||||
|
*/ |
||||
|
@Mapper |
||||
|
public interface ChangeWelfareDao extends BaseDao<ChangeWelfareEntity> { |
||||
|
|
||||
|
/** |
||||
|
* @describe: 通过身份证号查询福利人员 |
||||
|
* @author wangtong |
||||
|
* @date 2022/5/9 13:59 |
||||
|
* @params [idCard] |
||||
|
* @return com.epmet.plugin.power.modules.change.entity.ChangeWelfareEntity |
||||
|
*/ |
||||
|
ChangeWelfareEntity selectByIdCard(@Param("idCard") String idCard); |
||||
|
|
||||
|
/** |
||||
|
* @describe: 移除福利人员 |
||||
|
* @author wangtong |
||||
|
* @date 2022/5/9 14:36 |
||||
|
* @params [dto] |
||||
|
* @return com.epmet.commons.tools.utils.Result |
||||
|
*/ |
||||
|
void removeWelfare(ChangeWelfareDTO dto); |
||||
|
} |
||||
@ -0,0 +1,16 @@ |
|||||
|
package com.epmet.dao; |
||||
|
|
||||
|
import com.epmet.commons.mybatis.dao.BaseDao; |
||||
|
import com.epmet.entity.IcMoveInRecordEntity; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
|
||||
|
/** |
||||
|
* 迁入管理记录 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-09 |
||||
|
*/ |
||||
|
@Mapper |
||||
|
public interface IcMoveInRecordDao extends BaseDao<IcMoveInRecordEntity> { |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,81 @@ |
|||||
|
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-05-05 |
||||
|
*/ |
||||
|
@Data |
||||
|
@EqualsAndHashCode(callSuper=false) |
||||
|
@TableName("pli_change_death") |
||||
|
public class ChangeDeathEntity extends BaseEpmetEntity { |
||||
|
|
||||
|
private static final long serialVersionUID = 1L; |
||||
|
|
||||
|
/** |
||||
|
* epmet用户主键 |
||||
|
*/ |
||||
|
private String userId; |
||||
|
|
||||
|
/** |
||||
|
* epmet网格ID |
||||
|
*/ |
||||
|
private String gridId; |
||||
|
|
||||
|
/** |
||||
|
* 姓名 |
||||
|
*/ |
||||
|
private String name; |
||||
|
|
||||
|
/** |
||||
|
* 身份证 |
||||
|
*/ |
||||
|
private String idCard; |
||||
|
|
||||
|
/** |
||||
|
* 手机号 |
||||
|
*/ |
||||
|
private String mobile; |
||||
|
|
||||
|
/** |
||||
|
* 性别 0女 1男 |
||||
|
*/ |
||||
|
private String gender; |
||||
|
|
||||
|
/** |
||||
|
* 类型 0 租客 1 房东 |
||||
|
*/ |
||||
|
private String type; |
||||
|
|
||||
|
/** |
||||
|
* 加入时间 |
||||
|
*/ |
||||
|
private String joinDate; |
||||
|
|
||||
|
/** |
||||
|
* 加入原因 |
||||
|
*/ |
||||
|
private String joinReason; |
||||
|
|
||||
|
/** |
||||
|
* 移除时间 |
||||
|
*/ |
||||
|
private String removeDate; |
||||
|
|
||||
|
/** |
||||
|
* 移除原因 |
||||
|
*/ |
||||
|
private String removeReason; |
||||
|
|
||||
|
/** |
||||
|
* 客户ID |
||||
|
*/ |
||||
|
private String customerId; |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,153 @@ |
|||||
|
package com.epmet.entity; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.annotation.TableName; |
||||
|
import com.epmet.commons.mybatis.entity.BaseEpmetEntity; |
||||
|
import lombok.Data; |
||||
|
import lombok.EqualsAndHashCode; |
||||
|
|
||||
|
import java.util.Date; |
||||
|
|
||||
|
/** |
||||
|
* 合同表 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-06 |
||||
|
*/ |
||||
|
@Data |
||||
|
@EqualsAndHashCode(callSuper=false) |
||||
|
@TableName("pli_change_relocation") |
||||
|
public class ChangeRelocationEntity extends BaseEpmetEntity { |
||||
|
|
||||
|
private static final long serialVersionUID = 1L; |
||||
|
|
||||
|
/** |
||||
|
* 姓名 |
||||
|
*/ |
||||
|
private String name; |
||||
|
|
||||
|
/** |
||||
|
* 性别 |
||||
|
*/ |
||||
|
private String gender; |
||||
|
|
||||
|
/** |
||||
|
* 年龄 |
||||
|
*/ |
||||
|
private String age; |
||||
|
|
||||
|
/** |
||||
|
* 组织PID |
||||
|
*/ |
||||
|
private String pid; |
||||
|
|
||||
|
/** |
||||
|
* 组织ID |
||||
|
*/ |
||||
|
private String agencyId; |
||||
|
|
||||
|
/** |
||||
|
* 组织名 |
||||
|
*/ |
||||
|
private String agencyName; |
||||
|
|
||||
|
/** |
||||
|
* 房屋小区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; |
||||
|
|
||||
|
/** |
||||
|
* 操作类型【客户外out,客户内in】 |
||||
|
*/ |
||||
|
private String type; |
||||
|
|
||||
|
/** |
||||
|
* 原房主姓名 |
||||
|
*/ |
||||
|
private String ownerName; |
||||
|
|
||||
|
/** |
||||
|
* 原网格信息 |
||||
|
*/ |
||||
|
private String oldDept; |
||||
|
|
||||
|
/** |
||||
|
* 原房屋信息 |
||||
|
*/ |
||||
|
private String oldAddress; |
||||
|
|
||||
|
/** |
||||
|
* 原房间号 |
||||
|
*/ |
||||
|
private String oldHome; |
||||
|
|
||||
|
/** |
||||
|
* 浅出原因 |
||||
|
*/ |
||||
|
private String reason; |
||||
|
|
||||
|
/** |
||||
|
* 客户ID |
||||
|
*/ |
||||
|
private String customerId; |
||||
|
|
||||
|
/** |
||||
|
* 迁出时间 |
||||
|
*/ |
||||
|
private Date outOfTime; |
||||
|
|
||||
|
/** |
||||
|
* 身份证号 |
||||
|
*/ |
||||
|
private String idCard; |
||||
|
|
||||
|
/** |
||||
|
* 手机号 |
||||
|
*/ |
||||
|
private String mobile; |
||||
|
|
||||
|
/** |
||||
|
* epmet用户主键 |
||||
|
*/ |
||||
|
private String icUserId; |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,81 @@ |
|||||
|
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-05-09 |
||||
|
*/ |
||||
|
@Data |
||||
|
@EqualsAndHashCode(callSuper=false) |
||||
|
@TableName("pli_change_welfare") |
||||
|
public class ChangeWelfareEntity extends BaseEpmetEntity { |
||||
|
|
||||
|
private static final long serialVersionUID = 1L; |
||||
|
|
||||
|
/** |
||||
|
* epmet用户主键 |
||||
|
*/ |
||||
|
private String userId; |
||||
|
|
||||
|
/** |
||||
|
* epmet网格ID |
||||
|
*/ |
||||
|
private String gridId; |
||||
|
|
||||
|
/** |
||||
|
* 姓名 |
||||
|
*/ |
||||
|
private String name; |
||||
|
|
||||
|
/** |
||||
|
* 身份证 |
||||
|
*/ |
||||
|
private String idCard; |
||||
|
|
||||
|
/** |
||||
|
* 手机号 |
||||
|
*/ |
||||
|
private String mobile; |
||||
|
|
||||
|
/** |
||||
|
* 性别 0女 1男 |
||||
|
*/ |
||||
|
private String gender; |
||||
|
|
||||
|
/** |
||||
|
* 类型 |
||||
|
*/ |
||||
|
private String type; |
||||
|
|
||||
|
/** |
||||
|
* 加入时间 |
||||
|
*/ |
||||
|
private String joinDate; |
||||
|
|
||||
|
/** |
||||
|
* 加入原因 |
||||
|
*/ |
||||
|
private String joinReason; |
||||
|
|
||||
|
/** |
||||
|
* 移除时间 |
||||
|
*/ |
||||
|
private String removeDate; |
||||
|
|
||||
|
/** |
||||
|
* 移除原因 |
||||
|
*/ |
||||
|
private String removeReason; |
||||
|
|
||||
|
/** |
||||
|
* 客户ID |
||||
|
*/ |
||||
|
private String customerId; |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,138 @@ |
|||||
|
package com.epmet.entity; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.annotation.TableName; |
||||
|
import com.epmet.commons.mybatis.entity.BaseEpmetEntity; |
||||
|
import lombok.Data; |
||||
|
import lombok.EqualsAndHashCode; |
||||
|
|
||||
|
import java.util.Date; |
||||
|
|
||||
|
/** |
||||
|
* 迁入管理记录 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-09 |
||||
|
*/ |
||||
|
@Data |
||||
|
@EqualsAndHashCode(callSuper=false) |
||||
|
@TableName("ic_move_in_record") |
||||
|
public class IcMoveInRecordEntity extends BaseEpmetEntity { |
||||
|
|
||||
|
private static final long serialVersionUID = 1L; |
||||
|
|
||||
|
/** |
||||
|
* 客户Id customer.id |
||||
|
*/ |
||||
|
private String customerId; |
||||
|
|
||||
|
/** |
||||
|
* 组织Id |
||||
|
*/ |
||||
|
private String agencyId; |
||||
|
|
||||
|
/** |
||||
|
* 组织的pids |
||||
|
*/ |
||||
|
private String pids; |
||||
|
|
||||
|
/** |
||||
|
* 网格ID |
||||
|
*/ |
||||
|
private String gridId; |
||||
|
|
||||
|
/** |
||||
|
* 所属小区ID |
||||
|
*/ |
||||
|
private String villageId; |
||||
|
|
||||
|
/** |
||||
|
* 所属楼宇Id |
||||
|
*/ |
||||
|
private String buildId; |
||||
|
|
||||
|
/** |
||||
|
* 单元id |
||||
|
*/ |
||||
|
private String unitId; |
||||
|
|
||||
|
/** |
||||
|
* 所属家庭Id |
||||
|
*/ |
||||
|
private String homeId; |
||||
|
|
||||
|
/** |
||||
|
* 姓名 |
||||
|
*/ |
||||
|
private String name; |
||||
|
|
||||
|
/** |
||||
|
* 是否享受福利【否:0 是:1】 |
||||
|
*/ |
||||
|
private String isWeifare; |
||||
|
|
||||
|
/** |
||||
|
* 手机号 |
||||
|
*/ |
||||
|
private String mobile; |
||||
|
|
||||
|
/** |
||||
|
* 身份证号 |
||||
|
*/ |
||||
|
private String idCard; |
||||
|
|
||||
|
/** |
||||
|
* 性别(1男2女0未知) |
||||
|
*/ |
||||
|
private String gender; |
||||
|
|
||||
|
/** |
||||
|
* 年龄 |
||||
|
*/ |
||||
|
private Integer age; |
||||
|
|
||||
|
/** |
||||
|
* 迁入时间 |
||||
|
*/ |
||||
|
private Date inTime; |
||||
|
|
||||
|
/** |
||||
|
* 迁入原因 |
||||
|
*/ |
||||
|
private String inReason; |
||||
|
|
||||
|
/** |
||||
|
* 来源地区编码 |
||||
|
*/ |
||||
|
private String sourceAddressCode; |
||||
|
|
||||
|
/** |
||||
|
* 来源地区编码全路径 |
||||
|
*/ |
||||
|
private String sourceAddressPathCode; |
||||
|
|
||||
|
/** |
||||
|
* 来源地区地址 |
||||
|
*/ |
||||
|
private String sourceAddress; |
||||
|
|
||||
|
/** |
||||
|
* 详细地址 |
||||
|
*/ |
||||
|
private String address; |
||||
|
|
||||
|
/** |
||||
|
* 迁移证号码 |
||||
|
*/ |
||||
|
private String moveNumber; |
||||
|
|
||||
|
/** |
||||
|
* 户主姓名 |
||||
|
*/ |
||||
|
private String householderName; |
||||
|
|
||||
|
/** |
||||
|
* 与户主关系[字典表] |
||||
|
*/ |
||||
|
private String householderRelation; |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,72 @@ |
|||||
|
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-05-05 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class ChangeDeathExcel { |
||||
|
|
||||
|
// @Excel(name = "主键")
|
||||
|
// private String id;
|
||||
|
|
||||
|
// @Excel(name = "epmet用户主键")
|
||||
|
// private String userId;
|
||||
|
|
||||
|
@Excel(name = "姓名") |
||||
|
private String name; |
||||
|
|
||||
|
@Excel(name = "身份证") |
||||
|
private String idCard; |
||||
|
|
||||
|
@Excel(name = "手机号") |
||||
|
private String mobile; |
||||
|
|
||||
|
@Excel(name = "性别",replace = { "男_1", "女_0"} ) |
||||
|
private String gender; |
||||
|
|
||||
|
@Excel(name = "类型",replace = { "房东_1", "租客_0"} ) |
||||
|
private String type; |
||||
|
|
||||
|
@Excel(name = "加入时间") |
||||
|
private String joinDate; |
||||
|
|
||||
|
@Excel(name = "加入原因") |
||||
|
private String joinReason; |
||||
|
|
||||
|
// @Excel(name = "移除时间")
|
||||
|
// private String removeDate;
|
||||
|
//
|
||||
|
// @Excel(name = "移除原因")
|
||||
|
// private String removeReason;
|
||||
|
|
||||
|
// @Excel(name = "删除标记 0:未删除,1:已删除")
|
||||
|
// private String delFlag;
|
||||
|
//
|
||||
|
// @Excel(name = "乐观锁")
|
||||
|
// private Integer revision;
|
||||
|
//
|
||||
|
// @Excel(name = "创建人")
|
||||
|
// private String createdBy;
|
||||
|
|
||||
|
@Excel(name = "创建时间", format = "yyyy-MM-dd HH:mm:ss") |
||||
|
private Date createdTime; |
||||
|
|
||||
|
// @Excel(name = "更新人")
|
||||
|
// private String updatedBy;
|
||||
|
//
|
||||
|
// @Excel(name = "更新时间")
|
||||
|
// private Date updatedTime;
|
||||
|
|
||||
|
// @Excel(name = "客户ID")
|
||||
|
// private String customerId;
|
||||
|
|
||||
|
|
||||
|
} |
||||
@ -0,0 +1,127 @@ |
|||||
|
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-05-06 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class ChangeRelocationExcel { |
||||
|
|
||||
|
// @Excel(name = "主键")
|
||||
|
// private String id;
|
||||
|
|
||||
|
@Excel(name = "姓名") |
||||
|
private String name; |
||||
|
|
||||
|
@Excel(name = "所属网格") |
||||
|
private String agencyName; |
||||
|
|
||||
|
@Excel(name = "所属房屋") |
||||
|
private String oldAddress; |
||||
|
|
||||
|
@Excel(name = "手机号") |
||||
|
private String mobile; |
||||
|
|
||||
|
@Excel(name = "身份证号") |
||||
|
private String idCard; |
||||
|
|
||||
|
@Excel(name = "性别") |
||||
|
private String gender; |
||||
|
|
||||
|
@Excel(name = "年龄") |
||||
|
private String age; |
||||
|
|
||||
|
@Excel(name = "迁出时间", format = "yyyy-MM-dd") |
||||
|
private Date outOfTime; |
||||
|
|
||||
|
@Excel(name = "迁出原因") |
||||
|
private String reason; |
||||
|
|
||||
|
@Excel(name = "迁往何地") |
||||
|
private String address; |
||||
|
|
||||
|
@Excel(name = "户主姓名") |
||||
|
private String ownerName; |
||||
|
|
||||
|
|
||||
|
|
||||
|
// @Excel(name = "组织PID")
|
||||
|
// private String pid;
|
||||
|
|
||||
|
// @Excel(name = "组织ID")
|
||||
|
// private String agencyId;
|
||||
|
|
||||
|
|
||||
|
|
||||
|
// @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 = "操作类型",replace = { "客户外_out", "客户内_in"} )
|
||||
|
// private String type;
|
||||
|
//
|
||||
|
//
|
||||
|
//
|
||||
|
// @Excel(name = "原网格信息")
|
||||
|
// private String oldDept;
|
||||
|
//
|
||||
|
|
||||
|
|
||||
|
// @Excel(name = "原房间号")
|
||||
|
// private String oldHome;
|
||||
|
|
||||
|
|
||||
|
|
||||
|
// @Excel(name = "删除标记 0:未删除,1:已删除")
|
||||
|
// private String delFlag;
|
||||
|
//
|
||||
|
// @Excel(name = "乐观锁")
|
||||
|
// private Integer revision;
|
||||
|
//
|
||||
|
// @Excel(name = "创建人")
|
||||
|
// private String createdBy;
|
||||
|
|
||||
|
|
||||
|
|
||||
|
// @Excel(name = "创建时间", format = "yyyy-MM-dd HH:mm:ss")
|
||||
|
// private Date createdTime;
|
||||
|
|
||||
|
// @Excel(name = "更新人")
|
||||
|
// private String updatedBy;
|
||||
|
//
|
||||
|
// @Excel(name = "更新时间")
|
||||
|
// private Date updatedTime;
|
||||
|
//
|
||||
|
// @Excel(name = "客户ID")
|
||||
|
// private String customerId;
|
||||
|
|
||||
|
|
||||
|
} |
||||
@ -0,0 +1,75 @@ |
|||||
|
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-05-09 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class ChangeWelfareExcel { |
||||
|
|
||||
|
@Excel(name = "主键") |
||||
|
private String id; |
||||
|
|
||||
|
@Excel(name = "epmet用户主键") |
||||
|
private String userId; |
||||
|
|
||||
|
@Excel(name = "epmet网格ID") |
||||
|
private String gridId; |
||||
|
|
||||
|
@Excel(name = "姓名") |
||||
|
private String name; |
||||
|
|
||||
|
@Excel(name = "身份证") |
||||
|
private String idCard; |
||||
|
|
||||
|
@Excel(name = "手机号") |
||||
|
private String mobile; |
||||
|
|
||||
|
@Excel(name = "性别 0女 1男") |
||||
|
private String gender; |
||||
|
|
||||
|
@Excel(name = "类型") |
||||
|
private String type; |
||||
|
|
||||
|
@Excel(name = "加入时间") |
||||
|
private String joinDate; |
||||
|
|
||||
|
@Excel(name = "加入原因") |
||||
|
private String joinReason; |
||||
|
|
||||
|
@Excel(name = "移除时间") |
||||
|
private String removeDate; |
||||
|
|
||||
|
@Excel(name = "移除原因") |
||||
|
private String removeReason; |
||||
|
|
||||
|
@Excel(name = "删除标记 0:未删除,1:已删除") |
||||
|
private String 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; |
||||
|
|
||||
|
@Excel(name = "客户ID") |
||||
|
private String customerId; |
||||
|
|
||||
|
|
||||
|
} |
||||
@ -0,0 +1,102 @@ |
|||||
|
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-05-09 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class IcMoveInRecordExcel { |
||||
|
|
||||
|
@Excel(name = "唯一标识") |
||||
|
private String id; |
||||
|
|
||||
|
@Excel(name = "客户Id customer.id") |
||||
|
private String customerId; |
||||
|
|
||||
|
@Excel(name = "组织Id") |
||||
|
private String agencyId; |
||||
|
|
||||
|
@Excel(name = "组织的pids") |
||||
|
private String pids; |
||||
|
|
||||
|
@Excel(name = "网格ID") |
||||
|
private String gridId; |
||||
|
|
||||
|
@Excel(name = "所属小区ID") |
||||
|
private String villageId; |
||||
|
|
||||
|
@Excel(name = "所属楼宇Id") |
||||
|
private String buildId; |
||||
|
|
||||
|
@Excel(name = "单元id") |
||||
|
private String unitId; |
||||
|
|
||||
|
@Excel(name = "所属家庭Id") |
||||
|
private String homeId; |
||||
|
|
||||
|
@Excel(name = "姓名") |
||||
|
private String name; |
||||
|
|
||||
|
@Excel(name = "是否享受福利【否:0 是:1】") |
||||
|
private String isWeifare; |
||||
|
|
||||
|
@Excel(name = "手机号") |
||||
|
private String mobile; |
||||
|
|
||||
|
@Excel(name = "身份证号") |
||||
|
private String idCard; |
||||
|
|
||||
|
@Excel(name = "性别(1男2女0未知)") |
||||
|
private String gender; |
||||
|
|
||||
|
@Excel(name = "年龄") |
||||
|
private Integer age; |
||||
|
|
||||
|
@Excel(name = "迁入时间") |
||||
|
private Date inTime; |
||||
|
|
||||
|
@Excel(name = "迁入原因") |
||||
|
private String inReason; |
||||
|
|
||||
|
@Excel(name = "来源地") |
||||
|
private String source; |
||||
|
|
||||
|
@Excel(name = "详细地址") |
||||
|
private String address; |
||||
|
|
||||
|
@Excel(name = "迁移证号码") |
||||
|
private String moveNumber; |
||||
|
|
||||
|
@Excel(name = "户主姓名") |
||||
|
private String houseName; |
||||
|
|
||||
|
@Excel(name = "与户主关系[字典表]") |
||||
|
private String houseRelation; |
||||
|
|
||||
|
@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-05-05 |
||||
|
*/ |
||||
|
@Component |
||||
|
public class ChangeDeathRedis { |
||||
|
@Autowired |
||||
|
private RedisUtils redisUtils; |
||||
|
|
||||
|
public void delete(Object[] ids) { |
||||
|
|
||||
|
} |
||||
|
|
||||
|
public void set(){ |
||||
|
|
||||
|
} |
||||
|
|
||||
|
public String get(String id){ |
||||
|
return null; |
||||
|
} |
||||
|
|
||||
|
} |
||||
@ -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-05-06 |
||||
|
*/ |
||||
|
@Component |
||||
|
public class ChangeRelocationRedis { |
||||
|
@Autowired |
||||
|
private RedisUtils redisUtils; |
||||
|
|
||||
|
public void delete(Object[] ids) { |
||||
|
|
||||
|
} |
||||
|
|
||||
|
public void set(){ |
||||
|
|
||||
|
} |
||||
|
|
||||
|
public String get(String id){ |
||||
|
return null; |
||||
|
} |
||||
|
|
||||
|
} |
||||
@ -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-05-09 |
||||
|
*/ |
||||
|
@Component |
||||
|
public class ChangeWelfareRedis { |
||||
|
@Autowired |
||||
|
private RedisUtils redisUtils; |
||||
|
|
||||
|
public void delete(Object[] ids) { |
||||
|
|
||||
|
} |
||||
|
|
||||
|
public void set(){ |
||||
|
|
||||
|
} |
||||
|
|
||||
|
public String get(String id){ |
||||
|
return null; |
||||
|
} |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,79 @@ |
|||||
|
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.ChangeDeathDTO; |
||||
|
import com.epmet.entity.ChangeDeathEntity; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
/** |
||||
|
* 死亡名单表 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-05 |
||||
|
*/ |
||||
|
public interface ChangeDeathService extends BaseService<ChangeDeathEntity> { |
||||
|
|
||||
|
/** |
||||
|
* 默认分页 |
||||
|
* |
||||
|
* @param params |
||||
|
* @return PageData<ChangeDeathDTO> |
||||
|
* @author generator |
||||
|
* @date 2022-05-05 |
||||
|
*/ |
||||
|
PageData<ChangeDeathDTO> page(Map<String, Object> params); |
||||
|
|
||||
|
/** |
||||
|
* 默认查询 |
||||
|
* |
||||
|
* @param params |
||||
|
* @return java.util.List<ChangeDeathDTO> |
||||
|
* @author generator |
||||
|
* @date 2022-05-05 |
||||
|
*/ |
||||
|
List<ChangeDeathDTO> list(Map<String, Object> params); |
||||
|
|
||||
|
/** |
||||
|
* 单条查询 |
||||
|
* |
||||
|
* @param id |
||||
|
* @return ChangeDeathDTO |
||||
|
* @author generator |
||||
|
* @date 2022-05-05 |
||||
|
*/ |
||||
|
ChangeDeathDTO get(String id); |
||||
|
|
||||
|
/** |
||||
|
* 默认保存 |
||||
|
* |
||||
|
* @param dto |
||||
|
* @return void |
||||
|
* @author generator |
||||
|
* @date 2022-05-05 |
||||
|
*/ |
||||
|
Result save(ChangeDeathDTO dto); |
||||
|
|
||||
|
/** |
||||
|
* 默认更新 |
||||
|
* |
||||
|
* @param dto |
||||
|
* @return void |
||||
|
* @author generator |
||||
|
* @date 2022-05-05 |
||||
|
*/ |
||||
|
void update(ChangeDeathDTO dto); |
||||
|
|
||||
|
/** |
||||
|
* 批量删除 |
||||
|
* |
||||
|
* @param ids |
||||
|
* @return void |
||||
|
* @author generator |
||||
|
* @date 2022-05-05 |
||||
|
*/ |
||||
|
void delete(String[] ids); |
||||
|
} |
||||
@ -0,0 +1,88 @@ |
|||||
|
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.ChangeRelocationDTO; |
||||
|
import com.epmet.entity.ChangeRelocationEntity; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
/** |
||||
|
* 合同表 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-06 |
||||
|
*/ |
||||
|
public interface ChangeRelocationService extends BaseService<ChangeRelocationEntity> { |
||||
|
|
||||
|
/** |
||||
|
* 默认分页 |
||||
|
* |
||||
|
* @param params |
||||
|
* @return PageData<ChangeRelocationDTO> |
||||
|
* @author generator |
||||
|
* @date 2022-05-06 |
||||
|
*/ |
||||
|
PageData<ChangeRelocationDTO> page(Map<String, Object> params); |
||||
|
|
||||
|
/** |
||||
|
* 默认查询 |
||||
|
* |
||||
|
* @param params |
||||
|
* @return java.util.List<ChangeRelocationDTO> |
||||
|
* @author generator |
||||
|
* @date 2022-05-06 |
||||
|
*/ |
||||
|
List<ChangeRelocationDTO> list(Map<String, Object> params); |
||||
|
|
||||
|
/** |
||||
|
* 单条查询 |
||||
|
* |
||||
|
* @param id |
||||
|
* @return ChangeRelocationDTO |
||||
|
* @author generator |
||||
|
* @date 2022-05-06 |
||||
|
*/ |
||||
|
ChangeRelocationDTO get(String id); |
||||
|
|
||||
|
/** |
||||
|
* 默认保存 |
||||
|
* |
||||
|
* @param dto |
||||
|
* @return void |
||||
|
* @author generator |
||||
|
* @date 2022-05-06 |
||||
|
*/ |
||||
|
void save(ChangeRelocationDTO dto); |
||||
|
|
||||
|
/** |
||||
|
* 默认更新 |
||||
|
* |
||||
|
* @param dto |
||||
|
* @return void |
||||
|
* @author generator |
||||
|
* @date 2022-05-06 |
||||
|
*/ |
||||
|
void update(ChangeRelocationDTO dto); |
||||
|
|
||||
|
/** |
||||
|
* 批量删除 |
||||
|
* |
||||
|
* @param ids |
||||
|
* @return void |
||||
|
* @author generator |
||||
|
* @date 2022-05-06 |
||||
|
*/ |
||||
|
void delete(String[] ids); |
||||
|
|
||||
|
/** |
||||
|
* @describe: 保存迁出信息 |
||||
|
* @author wangtong |
||||
|
* @date 2022/5/7 9:49 |
||||
|
* @params [dto] |
||||
|
* @return com.epmet.commons.tools.utils.Result |
||||
|
*/ |
||||
|
Result saveOutOfInfo(ChangeRelocationDTO dto); |
||||
|
} |
||||
@ -0,0 +1,107 @@ |
|||||
|
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.ChangeWelfareDTO; |
||||
|
import com.epmet.dto.CheckWelfareByIdCardDTO; |
||||
|
import com.epmet.entity.ChangeWelfareEntity; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
/** |
||||
|
* 福利表 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-09 |
||||
|
*/ |
||||
|
public interface ChangeWelfareService extends BaseService<ChangeWelfareEntity> { |
||||
|
|
||||
|
/** |
||||
|
* 默认分页 |
||||
|
* |
||||
|
* @param params |
||||
|
* @return PageData<ChangeWelfareDTO> |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
PageData<ChangeWelfareDTO> page(Map<String, Object> params); |
||||
|
|
||||
|
/** |
||||
|
* 默认查询 |
||||
|
* |
||||
|
* @param params |
||||
|
* @return java.util.List<ChangeWelfareDTO> |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
List<ChangeWelfareDTO> list(Map<String, Object> params); |
||||
|
|
||||
|
/** |
||||
|
* 单条查询 |
||||
|
* |
||||
|
* @param id |
||||
|
* @return ChangeWelfareDTO |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
ChangeWelfareDTO get(String id); |
||||
|
|
||||
|
/** |
||||
|
* 默认保存 |
||||
|
* |
||||
|
* @param dto |
||||
|
* @return void |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
Result save(ChangeWelfareDTO dto); |
||||
|
|
||||
|
/** |
||||
|
* 默认更新 |
||||
|
* |
||||
|
* @param dto |
||||
|
* @return void |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
void update(ChangeWelfareDTO dto); |
||||
|
|
||||
|
/** |
||||
|
* 批量删除 |
||||
|
* |
||||
|
* @param ids |
||||
|
* @return void |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
void delete(String[] ids); |
||||
|
|
||||
|
/** |
||||
|
* @describe: 移除福利人员 |
||||
|
* @author wangtong |
||||
|
* @date 2022/5/9 11:11 |
||||
|
* @params [dto] |
||||
|
* @return com.epmet.commons.tools.utils.Result |
||||
|
*/ |
||||
|
Result removeWelfare(ChangeWelfareDTO dto); |
||||
|
|
||||
|
/** |
||||
|
* @describe: 通过身份证号查询是否属于福利人员,是-true,否-false |
||||
|
* @author wangtong |
||||
|
* @date 2022/5/9 13:54 |
||||
|
* @params [dto] |
||||
|
* @return java.lang.Boolean |
||||
|
*/ |
||||
|
Boolean checkWelfareByIdCard(CheckWelfareByIdCardDTO dto); |
||||
|
|
||||
|
/** |
||||
|
* @describe: 保存福利人员 |
||||
|
* @author wangtong |
||||
|
* @date 2022/5/9 14:10 |
||||
|
* @params [] |
||||
|
* @return com.epmet.commons.tools.utils.Result |
||||
|
*/ |
||||
|
Result saveWelfareInfo(ChangeWelfareDTO dto); |
||||
|
} |
||||
@ -0,0 +1,78 @@ |
|||||
|
package com.epmet.service; |
||||
|
|
||||
|
import com.epmet.commons.mybatis.service.BaseService; |
||||
|
import com.epmet.commons.tools.page.PageData; |
||||
|
import com.epmet.dto.IcMoveInRecordDTO; |
||||
|
import com.epmet.entity.IcMoveInRecordEntity; |
||||
|
|
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
/** |
||||
|
* 迁入管理记录 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-09 |
||||
|
*/ |
||||
|
public interface IcMoveInRecordService extends BaseService<IcMoveInRecordEntity> { |
||||
|
|
||||
|
/** |
||||
|
* 默认分页 |
||||
|
* |
||||
|
* @param params |
||||
|
* @return PageData<IcMoveInRecordDTO> |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
PageData<IcMoveInRecordDTO> page(Map<String, Object> params); |
||||
|
|
||||
|
/** |
||||
|
* 默认查询 |
||||
|
* |
||||
|
* @param params |
||||
|
* @return java.util.List<IcMoveInRecordDTO> |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
List<IcMoveInRecordDTO> list(Map<String, Object> params); |
||||
|
|
||||
|
/** |
||||
|
* 单条查询 |
||||
|
* |
||||
|
* @param id |
||||
|
* @return IcMoveInRecordDTO |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
IcMoveInRecordDTO get(String id); |
||||
|
|
||||
|
/** |
||||
|
* 默认保存 |
||||
|
* |
||||
|
* @param dto |
||||
|
* @return void |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
void save(IcMoveInRecordDTO dto); |
||||
|
|
||||
|
/** |
||||
|
* 默认更新 |
||||
|
* |
||||
|
* @param dto |
||||
|
* @return void |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
void update(IcMoveInRecordDTO dto); |
||||
|
|
||||
|
/** |
||||
|
* 批量删除 |
||||
|
* |
||||
|
* @param ids |
||||
|
* @return void |
||||
|
* @author generator |
||||
|
* @date 2022-05-09 |
||||
|
*/ |
||||
|
void delete(String[] ids); |
||||
|
} |
||||
@ -0,0 +1,177 @@ |
|||||
|
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.page.PageData; |
||||
|
import com.epmet.commons.tools.security.user.LoginUserUtil; |
||||
|
import com.epmet.commons.tools.utils.ConvertUtils; |
||||
|
import com.epmet.commons.tools.utils.DateUtils; |
||||
|
import com.epmet.commons.tools.utils.Result; |
||||
|
import com.epmet.commons.tools.utils.SpringContextUtils; |
||||
|
import com.epmet.commons.tools.validator.ValidatorUtils; |
||||
|
import com.epmet.commons.tools.validator.group.DefaultGroup; |
||||
|
import com.epmet.commons.tools.validator.group.UpdateGroup; |
||||
|
import com.epmet.dao.ChangeDeathDao; |
||||
|
import com.epmet.dto.ChangeDeathDTO; |
||||
|
import com.epmet.dto.ChangeWelfareDTO; |
||||
|
import com.epmet.dto.form.IcResiUserTransferFormDTO; |
||||
|
import com.epmet.dto.form.RentTenantDataFormDTO; |
||||
|
import com.epmet.dto.result.RentTenantDataResultDTO; |
||||
|
import com.epmet.entity.ChangeDeathEntity; |
||||
|
import com.epmet.entity.IcResiUserEntity; |
||||
|
import com.epmet.redis.ChangeDeathRedis; |
||||
|
import com.epmet.service.ChangeDeathService; |
||||
|
import com.epmet.service.ChangeWelfareService; |
||||
|
import com.epmet.service.IcResiUserService; |
||||
|
import com.epmet.service.IcUserTransferRecordService; |
||||
|
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.*; |
||||
|
|
||||
|
/** |
||||
|
* 死亡名单表 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-05 |
||||
|
*/ |
||||
|
@Service |
||||
|
public class ChangeDeathServiceImpl extends BaseServiceImpl<ChangeDeathDao, ChangeDeathEntity> implements ChangeDeathService { |
||||
|
|
||||
|
@Autowired |
||||
|
private ChangeDeathRedis changeDeathRedis; |
||||
|
|
||||
|
@Autowired |
||||
|
private IcResiUserServiceImpl icResiUserServiceImpl; |
||||
|
|
||||
|
@Autowired |
||||
|
LoginUserUtil loginUserUtil; |
||||
|
|
||||
|
@Autowired |
||||
|
private ChangeWelfareService changeWelfareService; |
||||
|
|
||||
|
@Autowired |
||||
|
private IcResiUserService icResiUserService; |
||||
|
|
||||
|
@Autowired |
||||
|
private ChangeRelocationServiceImpl changeRelocationServiceImpl; |
||||
|
|
||||
|
@Override |
||||
|
public PageData<ChangeDeathDTO> page(Map<String, Object> params) { |
||||
|
IPage<ChangeDeathEntity> page = baseDao.selectPage( |
||||
|
getPage(params, FieldConstant.CREATED_TIME, false), |
||||
|
getWrapper(params) |
||||
|
); |
||||
|
return getPageData(page, ChangeDeathDTO.class); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
public List<ChangeDeathDTO> list(Map<String, Object> params) { |
||||
|
List<ChangeDeathEntity> entityList = baseDao.selectList(getWrapper(params)); |
||||
|
|
||||
|
return ConvertUtils.sourceToTarget(entityList, ChangeDeathDTO.class); |
||||
|
} |
||||
|
|
||||
|
private QueryWrapper<ChangeDeathEntity> getWrapper(Map<String, Object> params){ |
||||
|
String id = (String) params.get(FieldConstant.ID_HUMP); |
||||
|
String name = (String) params.get("name"); |
||||
|
String idCard = (String) params.get("idCard"); |
||||
|
String mobile = (String) params.get("mobile"); |
||||
|
String startTime = (String) params.get("startTime"); |
||||
|
String endTime = (String) params.get("endTime"); |
||||
|
|
||||
|
QueryWrapper<ChangeDeathEntity> wrapper = new QueryWrapper<>(); |
||||
|
wrapper.eq(StringUtils.isNotBlank(id), FieldConstant.ID, id); |
||||
|
wrapper.eq(StringUtils.isNotBlank(name), "NAME", name); |
||||
|
wrapper.eq(StringUtils.isNotBlank(idCard), "ID_CARD", idCard); |
||||
|
wrapper.eq(StringUtils.isNotBlank(mobile), "MOBILE", mobile); |
||||
|
wrapper.ge(StringUtils.isNotBlank(startTime), "JOIN_DATE", startTime); |
||||
|
wrapper.le(StringUtils.isNotBlank(endTime), "JOIN_DATE", endTime); |
||||
|
|
||||
|
return wrapper; |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
public ChangeDeathDTO get(String id) { |
||||
|
ChangeDeathEntity entity = baseDao.selectById(id); |
||||
|
return ConvertUtils.sourceToTarget(entity, ChangeDeathDTO.class); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
@Transactional(rollbackFor = Exception.class) |
||||
|
public Result save(ChangeDeathDTO dto) { |
||||
|
RentTenantDataFormDTO formDTO = new RentTenantDataFormDTO(); |
||||
|
formDTO.setUserId(dto.getUserId()); |
||||
|
formDTO.setCustomerId(loginUserUtil.getLoginUserCustomerId()); |
||||
|
ValidatorUtils.validateEntity(formDTO, UpdateGroup.class, DefaultGroup.class); |
||||
|
RentTenantDataResultDTO result = icResiUserServiceImpl.getRentResiUserInfo(formDTO); |
||||
|
|
||||
|
dto.setIdCard(result.getIdCard()); |
||||
|
dto.setMobile(result.getMobile()); |
||||
|
dto.setGridId(result.getGridId()); |
||||
|
Map<String, Object> params = new HashMap<>(4); |
||||
|
params.put("idCard", dto.getIdCard()); |
||||
|
if (!list(params).isEmpty()) { |
||||
|
return new Result().error("该人员已经迁入死亡人口"); |
||||
|
} |
||||
|
|
||||
|
dto.setJoinDate(DateUtils.format(new Date())); |
||||
|
ChangeDeathEntity entity = ConvertUtils.sourceToTarget(dto, ChangeDeathEntity.class); |
||||
|
entity.setCustomerId(loginUserUtil.getLoginUserCustomerId()); |
||||
|
insert(entity); |
||||
|
|
||||
|
if(dto.getWelfareFlag() != null && dto.getWelfareFlag()){ |
||||
|
ChangeWelfareDTO formDto = new ChangeWelfareDTO(); |
||||
|
formDto.setUserId(dto.getUserId()); |
||||
|
formDto.setName(dto.getName()); |
||||
|
formDto.setIdCard(result.getIdCard()); |
||||
|
formDto.setMobile(result.getMobile()); |
||||
|
formDto.setGridId(result.getGridId()); |
||||
|
formDto.setGender(dto.getGender()); |
||||
|
formDto.setJoinReason("迁入死亡人口选定"); |
||||
|
formDto.setCustomerId(dto.getCustomerId()); |
||||
|
formDto.setCustomerId(formDTO.getCustomerId()); |
||||
|
changeWelfareService.saveWelfareInfo(formDto); |
||||
|
} |
||||
|
//更新epmet用户状态
|
||||
|
IcResiUserEntity userEntity = new IcResiUserEntity(); |
||||
|
userEntity.setId(dto.getUserId()); |
||||
|
userEntity.setStatus("2");//死亡
|
||||
|
userEntity.setSubStatus("21");//死亡
|
||||
|
icResiUserService.updateById(userEntity); |
||||
|
//变更主表、变更明细表
|
||||
|
IcResiUserTransferFormDTO icResiUserTransferFormDTO=new IcResiUserTransferFormDTO(); |
||||
|
icResiUserTransferFormDTO.setIcUserId(dto.getUserId()); |
||||
|
icResiUserTransferFormDTO.setType("out"); |
||||
|
icResiUserTransferFormDTO.setCustomerId(dto.getCustomerId()); |
||||
|
icResiUserTransferFormDTO.setStaffId(dto.getStaffId()); |
||||
|
//死亡日期即为取当前时间,视作变更时间 todo 待确认
|
||||
|
icResiUserTransferFormDTO.setTransferTime(new Date()); |
||||
|
icResiUserTransferFormDTO.setMoveType("died"); |
||||
|
//死亡原因
|
||||
|
icResiUserTransferFormDTO.setReason(dto.getJoinReason()); |
||||
|
SpringContextUtils.getBean(IcUserTransferRecordService.class).moveOutResi(icResiUserTransferFormDTO); |
||||
|
//推送MQ事件
|
||||
|
changeRelocationServiceImpl.editResiMq(formDTO.getCustomerId(), dto.getUserId()); |
||||
|
return new Result(); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
@Transactional(rollbackFor = Exception.class) |
||||
|
public void update(ChangeDeathDTO dto) { |
||||
|
ChangeDeathEntity entity = ConvertUtils.sourceToTarget(dto, ChangeDeathEntity.class); |
||||
|
updateById(entity); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
@Transactional(rollbackFor = Exception.class) |
||||
|
public void delete(String[] ids) { |
||||
|
// 逻辑删除(@TableLogic 注解)
|
||||
|
baseDao.deleteBatchIds(Arrays.asList(ids)); |
||||
|
} |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,222 @@ |
|||||
|
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.rocketmq.messages.IcResiUserAddMQMsg; |
||||
|
import com.epmet.commons.tools.constant.FieldConstant; |
||||
|
import com.epmet.commons.tools.enums.IcResiUserSubStatusEnum; |
||||
|
import com.epmet.commons.tools.page.PageData; |
||||
|
import com.epmet.commons.tools.security.user.LoginUserUtil; |
||||
|
import com.epmet.commons.tools.utils.ConvertUtils; |
||||
|
import com.epmet.commons.tools.utils.Result; |
||||
|
import com.epmet.commons.tools.utils.SpringContextUtils; |
||||
|
import com.epmet.commons.tools.validator.IdCardNoValidatorUtils; |
||||
|
import com.epmet.commons.tools.validator.ValidatorUtils; |
||||
|
import com.epmet.commons.tools.validator.group.DefaultGroup; |
||||
|
import com.epmet.commons.tools.validator.group.UpdateGroup; |
||||
|
import com.epmet.constant.SystemMessageType; |
||||
|
import com.epmet.dao.ChangeRelocationDao; |
||||
|
import com.epmet.dto.ChangeRelocationDTO; |
||||
|
import com.epmet.dto.ChangeWelfareDTO; |
||||
|
import com.epmet.dto.form.IcResiUserTransferFormDTO; |
||||
|
import com.epmet.dto.form.RentTenantDataFormDTO; |
||||
|
import com.epmet.dto.form.SystemMsgFormDTO; |
||||
|
import com.epmet.dto.result.RentTenantDataResultDTO; |
||||
|
import com.epmet.entity.ChangeRelocationEntity; |
||||
|
import com.epmet.entity.IcResiUserEntity; |
||||
|
import com.epmet.feign.EpmetMessageOpenFeignClient; |
||||
|
import com.epmet.redis.ChangeRelocationRedis; |
||||
|
import com.epmet.service.ChangeRelocationService; |
||||
|
import com.epmet.service.ChangeWelfareService; |
||||
|
import com.epmet.service.IcResiUserService; |
||||
|
import com.epmet.service.IcUserTransferRecordService; |
||||
|
import lombok.extern.slf4j.Slf4j; |
||||
|
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.Arrays; |
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
/** |
||||
|
* 合同表 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-06 |
||||
|
*/ |
||||
|
@Slf4j |
||||
|
@Service |
||||
|
public class ChangeRelocationServiceImpl extends BaseServiceImpl<ChangeRelocationDao, ChangeRelocationEntity> implements ChangeRelocationService { |
||||
|
|
||||
|
@Autowired |
||||
|
private ChangeRelocationRedis changeRelocationRedis; |
||||
|
|
||||
|
@Autowired |
||||
|
LoginUserUtil loginUserUtil; |
||||
|
|
||||
|
@Autowired |
||||
|
private IcResiUserServiceImpl icResiUserServiceImpl; |
||||
|
|
||||
|
@Autowired |
||||
|
private ChangeWelfareService changeWelfareService; |
||||
|
|
||||
|
@Autowired |
||||
|
private EpmetMessageOpenFeignClient epmetMessageOpenFeignClient; |
||||
|
|
||||
|
@Autowired |
||||
|
private IcResiUserService icResiUserService; |
||||
|
|
||||
|
|
||||
|
|
||||
|
@Override |
||||
|
public PageData<ChangeRelocationDTO> page(Map<String, Object> params) { |
||||
|
IPage<ChangeRelocationEntity> page = baseDao.selectPage( |
||||
|
getPage(params, FieldConstant.CREATED_TIME, false), |
||||
|
getWrapper(params) |
||||
|
); |
||||
|
return getPageData(page, ChangeRelocationDTO.class); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
public List<ChangeRelocationDTO> list(Map<String, Object> params) { |
||||
|
List<ChangeRelocationEntity> entityList = baseDao.selectList(getWrapper(params)); |
||||
|
|
||||
|
return ConvertUtils.sourceToTarget(entityList, ChangeRelocationDTO.class); |
||||
|
} |
||||
|
|
||||
|
private QueryWrapper<ChangeRelocationEntity> getWrapper(Map<String, Object> params){ |
||||
|
String id = (String)params.get(FieldConstant.ID_HUMP); |
||||
|
String name = (String) params.get("name"); |
||||
|
String idCard = (String) params.get("idCard"); |
||||
|
String mobile = (String) params.get("mobile"); |
||||
|
String startTime = (String) params.get("startTime"); |
||||
|
String endTime = (String) params.get("endTime"); |
||||
|
|
||||
|
String gridId = (String) params.get("gridId"); |
||||
|
String villageId = (String) params.get("villageId"); |
||||
|
String buildId = (String) params.get("buildId"); |
||||
|
String unitId = (String) params.get("unitId"); |
||||
|
String homeId = (String) params.get("homeId"); |
||||
|
|
||||
|
|
||||
|
QueryWrapper<ChangeRelocationEntity> wrapper = new QueryWrapper<>(); |
||||
|
wrapper.eq(StringUtils.isNotBlank(id), FieldConstant.ID, id); |
||||
|
wrapper.eq(StringUtils.isNotBlank(name), "NAME", name); |
||||
|
wrapper.eq(StringUtils.isNotBlank(idCard), "ID_CARD", idCard); |
||||
|
wrapper.eq(StringUtils.isNotBlank(mobile), "MOBILE", mobile); |
||||
|
wrapper.ge(StringUtils.isNotBlank(startTime), "OUT_OF_TIME", startTime); |
||||
|
wrapper.le(StringUtils.isNotBlank(endTime), "OUT_OF_TIME", endTime); |
||||
|
|
||||
|
wrapper.eq(StringUtils.isNotBlank(gridId), "AGENCY_ID", gridId); |
||||
|
wrapper.eq(StringUtils.isNotBlank(villageId), "VILLAGE_ID", villageId); |
||||
|
wrapper.eq(StringUtils.isNotBlank(buildId), "BUILD_ID", buildId); |
||||
|
wrapper.eq(StringUtils.isNotBlank(unitId), "UNIT_ID", unitId); |
||||
|
wrapper.eq(StringUtils.isNotBlank(homeId), "HOME_ID", homeId); |
||||
|
|
||||
|
return wrapper; |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
public ChangeRelocationDTO get(String id) { |
||||
|
ChangeRelocationEntity entity = baseDao.selectById(id); |
||||
|
return ConvertUtils.sourceToTarget(entity, ChangeRelocationDTO.class); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
@Transactional(rollbackFor = Exception.class) |
||||
|
public void save(ChangeRelocationDTO dto) { |
||||
|
ChangeRelocationEntity entity = ConvertUtils.sourceToTarget(dto, ChangeRelocationEntity.class); |
||||
|
insert(entity); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
@Transactional(rollbackFor = Exception.class) |
||||
|
public void update(ChangeRelocationDTO dto) { |
||||
|
ChangeRelocationEntity entity = ConvertUtils.sourceToTarget(dto, ChangeRelocationEntity.class); |
||||
|
updateById(entity); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
@Transactional(rollbackFor = Exception.class) |
||||
|
public void delete(String[] ids) { |
||||
|
// 逻辑删除(@TableLogic 注解)
|
||||
|
baseDao.deleteBatchIds(Arrays.asList(ids)); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
public Result saveOutOfInfo(ChangeRelocationDTO dto) { |
||||
|
RentTenantDataFormDTO formDTO = new RentTenantDataFormDTO(); |
||||
|
formDTO.setUserId(dto.getIcUserId()); |
||||
|
formDTO.setCustomerId(loginUserUtil.getLoginUserCustomerId()); |
||||
|
ValidatorUtils.validateEntity(formDTO, UpdateGroup.class, DefaultGroup.class); |
||||
|
//当前居民信息
|
||||
|
RentTenantDataResultDTO result = icResiUserServiceImpl.getRentResiUserInfo(formDTO); |
||||
|
|
||||
|
dto.setIdCard(result.getIdCard()); |
||||
|
dto.setMobile(result.getMobile()); |
||||
|
|
||||
|
ChangeRelocationEntity entity = ConvertUtils.sourceToTarget(dto, ChangeRelocationEntity.class); |
||||
|
entity.setPid(dto.getAgencyId()); |
||||
|
entity.setAgencyId(dto.getGridId()); |
||||
|
entity.setAgencyName(dto.getGridName()); |
||||
|
entity.setAge(IdCardNoValidatorUtils.getAge(result.getIdCard()).toString()); |
||||
|
entity.setAddress(dto.getVillageName()+dto.getBuildName()+dto.getUnitName()+dto.getHomeName()); |
||||
|
insert(entity); |
||||
|
|
||||
|
//享受福利
|
||||
|
if(dto.getWelfareFlag() != null && dto.getWelfareFlag()){ |
||||
|
ChangeWelfareDTO formDto = new ChangeWelfareDTO(); |
||||
|
formDto.setUserId(dto.getIcUserId()); |
||||
|
formDto.setName(dto.getName()); |
||||
|
formDto.setIdCard(result.getIdCard()); |
||||
|
formDto.setMobile(result.getMobile()); |
||||
|
formDto.setGridId(result.getGridId()); |
||||
|
if(StringUtils.isNotBlank(dto.getGender())){ |
||||
|
if("女".equals(dto.getGender())){ |
||||
|
formDto.setGender("0"); |
||||
|
}else if("男".equals(dto.getGender())){ |
||||
|
formDto.setGender("1"); |
||||
|
} |
||||
|
} |
||||
|
formDto.setJoinReason("迁出人员选定"); |
||||
|
formDto.setCustomerId(dto.getCustomerId()); |
||||
|
formDto.setCustomerId(formDTO.getCustomerId()); |
||||
|
changeWelfareService.saveWelfareInfo(formDto); |
||||
|
} |
||||
|
//更新epmet用户状态
|
||||
|
IcResiUserEntity userEntity = new IcResiUserEntity(); |
||||
|
userEntity.setId(dto.getIcUserId()); |
||||
|
userEntity.setStatus("1");//转出(迁出)
|
||||
|
userEntity.setSubStatus(IcResiUserSubStatusEnum.MOVE_OUT.getSubStatus());//迁出
|
||||
|
icResiUserService.updateById(userEntity); |
||||
|
//插入一条调动(迁出)记录、变更主表、变更明细表
|
||||
|
IcResiUserTransferFormDTO icResiUserTransferFormDTO=ConvertUtils.sourceToTarget(dto,IcResiUserTransferFormDTO.class); |
||||
|
icResiUserTransferFormDTO.setNewAgencyId(dto.getAgencyId()); |
||||
|
icResiUserTransferFormDTO.setNewGridId(dto.getGridId()); |
||||
|
icResiUserTransferFormDTO.setNewNeighborHoodId(dto.getVillageId()); |
||||
|
icResiUserTransferFormDTO.setNewBuildingId(dto.getBuildId()); |
||||
|
icResiUserTransferFormDTO.setNewBuildingUnitId(dto.getUnitId()); |
||||
|
icResiUserTransferFormDTO.setNewHouseId(dto.getHomeId()); |
||||
|
icResiUserTransferFormDTO.setMoveType("out"); |
||||
|
SpringContextUtils.getBean(IcUserTransferRecordService.class).moveOutResi(icResiUserTransferFormDTO); |
||||
|
//推送MQ事件
|
||||
|
editResiMq(dto.getCustomerId(), dto.getIcUserId()); |
||||
|
return new Result(); |
||||
|
} |
||||
|
|
||||
|
public void editResiMq(String customerId, String userId) { |
||||
|
//推送MQ事件
|
||||
|
IcResiUserAddMQMsg mqMsg = new IcResiUserAddMQMsg(); |
||||
|
mqMsg.setCustomerId(customerId); |
||||
|
log.info("customer id is {}", customerId); |
||||
|
mqMsg.setIcResiUser(userId); |
||||
|
SystemMsgFormDTO form = new SystemMsgFormDTO(); |
||||
|
form.setMessageType(SystemMessageType.IC_RESI_USER_EDIT); |
||||
|
form.setContent(mqMsg); |
||||
|
epmetMessageOpenFeignClient.sendSystemMsgByMQ(form); |
||||
|
} |
||||
|
|
||||
|
} |
||||
@ -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.page.PageData; |
||||
|
import com.epmet.commons.tools.security.user.LoginUserUtil; |
||||
|
import com.epmet.commons.tools.utils.ConvertUtils; |
||||
|
import com.epmet.commons.tools.utils.DateUtils; |
||||
|
import com.epmet.commons.tools.utils.Result; |
||||
|
import com.epmet.commons.tools.validator.ValidatorUtils; |
||||
|
import com.epmet.commons.tools.validator.group.DefaultGroup; |
||||
|
import com.epmet.commons.tools.validator.group.UpdateGroup; |
||||
|
import com.epmet.dao.ChangeWelfareDao; |
||||
|
import com.epmet.dto.ChangeWelfareDTO; |
||||
|
import com.epmet.dto.CheckWelfareByIdCardDTO; |
||||
|
import com.epmet.dto.form.RentTenantDataFormDTO; |
||||
|
import com.epmet.dto.result.RentTenantDataResultDTO; |
||||
|
import com.epmet.entity.ChangeWelfareEntity; |
||||
|
import com.epmet.redis.ChangeWelfareRedis; |
||||
|
import com.epmet.service.ChangeWelfareService; |
||||
|
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.*; |
||||
|
|
||||
|
/** |
||||
|
* 福利表 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-09 |
||||
|
*/ |
||||
|
@Service |
||||
|
public class ChangeWelfareServiceImpl extends BaseServiceImpl<ChangeWelfareDao, ChangeWelfareEntity> implements ChangeWelfareService { |
||||
|
|
||||
|
@Autowired |
||||
|
private ChangeWelfareRedis changeWelfareRedis; |
||||
|
|
||||
|
@Autowired |
||||
|
LoginUserUtil loginUserUtil; |
||||
|
|
||||
|
@Autowired |
||||
|
private IcResiUserServiceImpl icResiUserServiceImpl; |
||||
|
|
||||
|
@Override |
||||
|
public PageData<ChangeWelfareDTO> page(Map<String, Object> params) { |
||||
|
IPage<ChangeWelfareEntity> page = baseDao.selectPage( |
||||
|
getPage(params, FieldConstant.CREATED_TIME, false), |
||||
|
getWrapper(params) |
||||
|
); |
||||
|
return getPageData(page, ChangeWelfareDTO.class); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
public List<ChangeWelfareDTO> list(Map<String, Object> params) { |
||||
|
List<ChangeWelfareEntity> entityList = baseDao.selectList(getWrapper(params)); |
||||
|
|
||||
|
return ConvertUtils.sourceToTarget(entityList, ChangeWelfareDTO.class); |
||||
|
} |
||||
|
|
||||
|
private QueryWrapper<ChangeWelfareEntity> getWrapper(Map<String, Object> params){ |
||||
|
String id = (String) params.get(FieldConstant.ID_HUMP); |
||||
|
String name = (String) params.get("name"); |
||||
|
String idCard = (String) params.get("idCard"); |
||||
|
String mobile = (String) params.get("mobile"); |
||||
|
String startTime = (String) params.get("startTime"); |
||||
|
String endTime = (String) params.get("endTime"); |
||||
|
|
||||
|
QueryWrapper<ChangeWelfareEntity> wrapper = new QueryWrapper<>(); |
||||
|
wrapper.eq(StringUtils.isNotBlank(id), FieldConstant.ID, id); |
||||
|
wrapper.eq(StringUtils.isNotBlank(name), "NAME", name); |
||||
|
wrapper.eq(StringUtils.isNotBlank(idCard), "ID_CARD", idCard); |
||||
|
wrapper.eq(StringUtils.isNotBlank(mobile), "MOBILE", mobile); |
||||
|
wrapper.ge(StringUtils.isNotBlank(startTime), "JOIN_DATE", startTime); |
||||
|
wrapper.le(StringUtils.isNotBlank(endTime), "JOIN_DATE", endTime); |
||||
|
|
||||
|
return wrapper; |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
public ChangeWelfareDTO get(String id) { |
||||
|
ChangeWelfareEntity entity = baseDao.selectById(id); |
||||
|
return ConvertUtils.sourceToTarget(entity, ChangeWelfareDTO.class); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
@Transactional(rollbackFor = Exception.class) |
||||
|
public Result save(ChangeWelfareDTO dto) { |
||||
|
|
||||
|
|
||||
|
RentTenantDataFormDTO formDTO = new RentTenantDataFormDTO(); |
||||
|
formDTO.setUserId(dto.getUserId()); |
||||
|
formDTO.setCustomerId(loginUserUtil.getLoginUserCustomerId()); |
||||
|
ValidatorUtils.validateEntity(formDTO, UpdateGroup.class, DefaultGroup.class); |
||||
|
RentTenantDataResultDTO result = icResiUserServiceImpl.getRentResiUserInfo(formDTO); |
||||
|
|
||||
|
dto.setIdCard(result.getIdCard()); |
||||
|
dto.setMobile(result.getMobile()); |
||||
|
dto.setGridId(result.getGridId()); |
||||
|
Map<String, Object> params = new HashMap<>(4); |
||||
|
params.put("idCard", dto.getIdCard()); |
||||
|
if (!list(params).isEmpty()) { |
||||
|
return new Result().error("该人员已经迁入福利人口"); |
||||
|
} |
||||
|
dto.setJoinDate(DateUtils.format(new Date())); |
||||
|
ChangeWelfareEntity entity = ConvertUtils.sourceToTarget(dto, ChangeWelfareEntity.class); |
||||
|
entity.setCustomerId(loginUserUtil.getLoginUserCustomerId()); |
||||
|
insert(entity); |
||||
|
return new Result(); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
@Transactional(rollbackFor = Exception.class) |
||||
|
public void update(ChangeWelfareDTO dto) { |
||||
|
ChangeWelfareEntity entity = ConvertUtils.sourceToTarget(dto, ChangeWelfareEntity.class); |
||||
|
updateById(entity); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
@Transactional(rollbackFor = Exception.class) |
||||
|
public void delete(String[] ids) { |
||||
|
// 逻辑删除(@TableLogic 注解)
|
||||
|
baseDao.deleteBatchIds(Arrays.asList(ids)); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
public Result removeWelfare(ChangeWelfareDTO dto) { |
||||
|
if(StringUtils.isBlank(dto.getId())){ |
||||
|
return new Result().error("id不可为空"); |
||||
|
} |
||||
|
dto.setRemoveDate(DateUtils.format(new Date())); |
||||
|
baseDao.removeWelfare(dto); |
||||
|
return new Result().ok("移除成功"); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
public Boolean checkWelfareByIdCard(CheckWelfareByIdCardDTO dto) { |
||||
|
ChangeWelfareEntity entity = baseDao.selectByIdCard(dto.getIdCard()); |
||||
|
return entity == null? false: true; |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
public Result saveWelfareInfo(ChangeWelfareDTO dto) { |
||||
|
Map<String, Object> params = new HashMap<>(4); |
||||
|
params.put("idCard", dto.getIdCard()); |
||||
|
if (!list(params).isEmpty()) { |
||||
|
return new Result().error("该人员已经迁入福利人口"); |
||||
|
} |
||||
|
dto.setJoinDate(DateUtils.format(new Date())); |
||||
|
ChangeWelfareEntity entity = ConvertUtils.sourceToTarget(dto, ChangeWelfareEntity.class); |
||||
|
insert(entity); |
||||
|
return new Result(); |
||||
|
} |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,83 @@ |
|||||
|
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.page.PageData; |
||||
|
import com.epmet.commons.tools.utils.ConvertUtils; |
||||
|
import com.epmet.dao.IcMoveInRecordDao; |
||||
|
import com.epmet.dto.IcMoveInRecordDTO; |
||||
|
import com.epmet.entity.IcMoveInRecordEntity; |
||||
|
import com.epmet.service.IcMoveInRecordService; |
||||
|
import org.apache.commons.lang3.StringUtils; |
||||
|
import org.springframework.stereotype.Service; |
||||
|
import org.springframework.transaction.annotation.Transactional; |
||||
|
|
||||
|
import java.util.Arrays; |
||||
|
import java.util.List; |
||||
|
import java.util.Map; |
||||
|
|
||||
|
/** |
||||
|
* 迁入管理记录 |
||||
|
* |
||||
|
* @author generator generator@elink-cn.com |
||||
|
* @since v1.0.0 2022-05-09 |
||||
|
*/ |
||||
|
@Service |
||||
|
public class IcMoveInRecordServiceImpl extends BaseServiceImpl<IcMoveInRecordDao, IcMoveInRecordEntity> implements IcMoveInRecordService { |
||||
|
|
||||
|
|
||||
|
@Override |
||||
|
public PageData<IcMoveInRecordDTO> page(Map<String, Object> params) { |
||||
|
IPage<IcMoveInRecordEntity> page = baseDao.selectPage( |
||||
|
getPage(params, FieldConstant.CREATED_TIME, false), |
||||
|
getWrapper(params) |
||||
|
); |
||||
|
return getPageData(page, IcMoveInRecordDTO.class); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
public List<IcMoveInRecordDTO> list(Map<String, Object> params) { |
||||
|
List<IcMoveInRecordEntity> entityList = baseDao.selectList(getWrapper(params)); |
||||
|
|
||||
|
return ConvertUtils.sourceToTarget(entityList, IcMoveInRecordDTO.class); |
||||
|
} |
||||
|
|
||||
|
private QueryWrapper<IcMoveInRecordEntity> getWrapper(Map<String, Object> params){ |
||||
|
String id = (String)params.get(FieldConstant.ID_HUMP); |
||||
|
|
||||
|
QueryWrapper<IcMoveInRecordEntity> wrapper = new QueryWrapper<>(); |
||||
|
wrapper.eq(StringUtils.isNotBlank(id), FieldConstant.ID, id); |
||||
|
|
||||
|
return wrapper; |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
public IcMoveInRecordDTO get(String id) { |
||||
|
IcMoveInRecordEntity entity = baseDao.selectById(id); |
||||
|
return ConvertUtils.sourceToTarget(entity, IcMoveInRecordDTO.class); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
@Transactional(rollbackFor = Exception.class) |
||||
|
public void save(IcMoveInRecordDTO dto) { |
||||
|
IcMoveInRecordEntity entity = ConvertUtils.sourceToTarget(dto, IcMoveInRecordEntity.class); |
||||
|
insert(entity); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
@Transactional(rollbackFor = Exception.class) |
||||
|
public void update(IcMoveInRecordDTO dto) { |
||||
|
IcMoveInRecordEntity entity = ConvertUtils.sourceToTarget(dto, IcMoveInRecordEntity.class); |
||||
|
updateById(entity); |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
@Transactional(rollbackFor = Exception.class) |
||||
|
public void delete(String[] ids) { |
||||
|
// 逻辑删除(@TableLogic 注解)
|
||||
|
baseDao.deleteBatchIds(Arrays.asList(ids)); |
||||
|
} |
||||
|
|
||||
|
} |
||||
@ -0,0 +1,12 @@ |
|||||
|
-- 变更记录表:增加 原因一列,增加操作类型 |
||||
|
alter table ic_user_change_record add COLUMN REASON VARCHAR(255) DEFAULT '' COMMENT '原因(迁入原因/迁出原因等)' after CHANGE_TIME; |
||||
|
alter table ic_user_change_record MODIFY COLUMN `TYPE` varchar(64) NOT NULL COMMENT '操作类型【add:新增 category:类别 transfer:调动;logout注销】'; |
||||
|
alter table ic_user_change_record MODIFY COLUMN `TYPE_NAME` varchar(64) NOT NULL COMMENT '操作类型名称【add:新增 category:类别 transfer:调动;logout注销】'; |
||||
|
-- 变更明细表,增加操作类型 |
||||
|
alter table ic_user_change_detailed MODIFY COLUMN `TYPE` varchar(255) NOT NULL COMMENT '操作类型【add:新增 category:类别 in:迁入 out:迁出;死亡:die】'; |
||||
|
alter table ic_user_change_detailed MODIFY COLUMN `TYPE_NAME` varchar(255) NOT NULL COMMENT '操作类型名称【add:新增 category:类别 in:迁入 out:迁出;死亡:die】'; |
||||
|
-- 居民信息表:增加一种状态;添加一列详细状态 |
||||
|
alter table ic_resi_user MODIFY COLUMN `STATUS` varchar(1) DEFAULT '0' COMMENT '用户状态【0:正常;1:迁出;2:注销】'; |
||||
|
|
||||
|
-- 01:新增、02:导入、03:迁入、04:新生、11:迁出、21死亡....; |
||||
|
alter table ic_resi_user ADD COLUMN `SUB_STATUS` varchar(10) DEFAULT NULL COMMENT '用户详细状态:01:新增、02:导入、03:迁入、04:新生、11:迁出、21死亡' AFTER `STATUS`; |
||||
@ -0,0 +1,85 @@ |
|||||
|
CREATE TABLE `pli_change_death` ( |
||||
|
`ID` varchar(32) NOT NULL COMMENT '主键', |
||||
|
`USER_ID` varchar(32) NOT NULL COMMENT 'epmet用户主键', |
||||
|
`GRID_ID` varchar(32) DEFAULT NULL COMMENT 'epmet网格ID', |
||||
|
`NAME` varchar(32) DEFAULT NULL COMMENT '姓名', |
||||
|
`ID_CARD` varchar(32) NOT NULL COMMENT '身份证', |
||||
|
`MOBILE` varchar(32) DEFAULT NULL COMMENT '手机号', |
||||
|
`GENDER` varchar(2) DEFAULT NULL COMMENT '性别 0女 1男', |
||||
|
`TYPE` varchar(2) DEFAULT NULL COMMENT '类型 0 租客 1 房东', |
||||
|
`JOIN_DATE` varchar(32) DEFAULT NULL COMMENT '加入时间', |
||||
|
`JOIN_REASON` varchar(255) DEFAULT NULL COMMENT '加入原因', |
||||
|
`REMOVE_DATE` varchar(32) DEFAULT NULL COMMENT '移除时间', |
||||
|
`REMOVE_REASON` varchar(255) DEFAULT NULL COMMENT '移除原因', |
||||
|
`DEL_FLAG` varchar(1) DEFAULT NULL COMMENT '删除标记 0:未删除,1:已删除', |
||||
|
`REVISION` int(11) DEFAULT NULL COMMENT '乐观锁', |
||||
|
`CREATED_BY` varchar(32) DEFAULT NULL COMMENT '创建人', |
||||
|
`CREATED_TIME` datetime DEFAULT NULL COMMENT '创建时间', |
||||
|
`UPDATED_BY` varchar(32) DEFAULT NULL COMMENT '更新人', |
||||
|
`UPDATED_TIME` datetime DEFAULT NULL COMMENT '更新时间', |
||||
|
`CUSTOMER_ID` varchar(64) NOT NULL COMMENT '客户ID', |
||||
|
PRIMARY KEY (`ID`) USING BTREE, |
||||
|
KEY `epdc_master_topic_USER_ID_IDX` (`USER_ID`) USING BTREE |
||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='死亡名单表'; |
||||
|
|
||||
|
CREATE TABLE `pli_change_relocation` ( |
||||
|
`ID` varchar(32) NOT NULL COMMENT '主键', |
||||
|
`NAME` varchar(32) DEFAULT NULL COMMENT '姓名', |
||||
|
`ID_CARD` varchar(32) DEFAULT NULL COMMENT '身份证号', |
||||
|
`GENDER` varchar(32) DEFAULT NULL COMMENT '性别 0女 1男', |
||||
|
`AGE` varchar(32) DEFAULT NULL COMMENT '年龄', |
||||
|
`MOBILE` varchar(32) DEFAULT NULL COMMENT '手机号', |
||||
|
`PID` varchar(32) DEFAULT NULL COMMENT '组织PID', |
||||
|
`AGENCY_ID` varchar(32) DEFAULT NULL COMMENT '组织ID', |
||||
|
`AGENCY_NAME` varchar(32) DEFAULT NULL COMMENT '组织名', |
||||
|
`VILLAGE_ID` varchar(32) DEFAULT NULL COMMENT '房屋小区ID', |
||||
|
`VILLAGE_NAME` varchar(32) DEFAULT NULL COMMENT '房屋小区', |
||||
|
`BUILD_ID` varchar(32) DEFAULT NULL COMMENT '楼号ID', |
||||
|
`BUILD_NAME` varchar(32) DEFAULT NULL COMMENT '楼号', |
||||
|
`UNIT_ID` varchar(32) DEFAULT NULL COMMENT '单元ID', |
||||
|
`UNIT_NAME` varchar(32) DEFAULT NULL COMMENT '单元', |
||||
|
`HOME_ID` varchar(32) DEFAULT NULL COMMENT '房屋ID', |
||||
|
`HOME_NAME` varchar(32) DEFAULT NULL COMMENT '房屋', |
||||
|
`ADDRESS` varchar(32) DEFAULT NULL COMMENT '外迁详细地址', |
||||
|
`TYPE` varchar(5) DEFAULT '0' COMMENT '操作类型【客户外out,客户内in】', |
||||
|
`OWNER_NAME` varchar(32) DEFAULT NULL COMMENT '原房主姓名', |
||||
|
`OLD_DEPT` varchar(32) DEFAULT NULL COMMENT '原网格信息', |
||||
|
`OLD_ADDRESS` varchar(32) DEFAULT NULL COMMENT '原房屋信息', |
||||
|
`OLD_HOME` varchar(32) DEFAULT NULL COMMENT '原房间号', |
||||
|
`REASON` varchar(32) DEFAULT NULL COMMENT '迁出原因', |
||||
|
`DEL_FLAG` varchar(1) DEFAULT NULL COMMENT '删除标记 0:未删除,1:已删除', |
||||
|
`REVISION` int(11) DEFAULT NULL COMMENT '乐观锁', |
||||
|
`CREATED_BY` varchar(32) DEFAULT NULL COMMENT '创建人', |
||||
|
`CREATED_TIME` datetime DEFAULT NULL COMMENT '创建时间', |
||||
|
`UPDATED_BY` varchar(32) DEFAULT NULL COMMENT '更新人', |
||||
|
`UPDATED_TIME` datetime DEFAULT NULL COMMENT '更新时间', |
||||
|
`CUSTOMER_ID` varchar(64) NOT NULL COMMENT '客户ID', |
||||
|
`OUT_OF_TIME` date DEFAULT NULL COMMENT '迁出时间', |
||||
|
`IC_USER_ID` varchar(64) DEFAULT NULL COMMENT 'epmet用户主键', |
||||
|
PRIMARY KEY (`ID`) USING BTREE, |
||||
|
KEY `epdc_master_topic_USER_ID_IDX` (`HOME_NAME`) USING BTREE |
||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='迁出表'; |
||||
|
|
||||
|
CREATE TABLE `pli_change_welfare` ( |
||||
|
`ID` varchar(32) NOT NULL COMMENT '主键', |
||||
|
`USER_ID` varchar(32) NOT NULL COMMENT 'epmet用户主键', |
||||
|
`GRID_ID` varchar(32) DEFAULT NULL COMMENT 'epmet网格ID', |
||||
|
`NAME` varchar(32) DEFAULT NULL COMMENT '姓名', |
||||
|
`ID_CARD` varchar(32) NOT NULL COMMENT '身份证', |
||||
|
`MOBILE` varchar(32) DEFAULT NULL COMMENT '手机号', |
||||
|
`GENDER` varchar(2) DEFAULT NULL COMMENT '性别 0女 1男', |
||||
|
`TYPE` varchar(2) DEFAULT NULL COMMENT '类型', |
||||
|
`JOIN_DATE` varchar(32) DEFAULT NULL COMMENT '加入时间', |
||||
|
`JOIN_REASON` varchar(255) DEFAULT NULL COMMENT '加入原因', |
||||
|
`REMOVE_DATE` varchar(32) DEFAULT NULL COMMENT '移除时间', |
||||
|
`REMOVE_REASON` varchar(255) DEFAULT NULL COMMENT '移除原因', |
||||
|
`DEL_FLAG` varchar(1) DEFAULT NULL COMMENT '删除标记 0:未删除,1:已删除', |
||||
|
`REVISION` int(11) DEFAULT NULL COMMENT '乐观锁', |
||||
|
`CREATED_BY` varchar(32) DEFAULT NULL COMMENT '创建人', |
||||
|
`CREATED_TIME` datetime DEFAULT NULL COMMENT '创建时间', |
||||
|
`UPDATED_BY` varchar(32) DEFAULT NULL COMMENT '更新人', |
||||
|
`UPDATED_TIME` datetime DEFAULT NULL COMMENT '更新时间', |
||||
|
`CUSTOMER_ID` varchar(64) NOT NULL COMMENT '客户ID', |
||||
|
PRIMARY KEY (`ID`) USING BTREE, |
||||
|
KEY `epdc_master_topic_USER_ID_IDX` (`USER_ID`) USING BTREE |
||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='福利表'; |
||||
@ -0,0 +1,28 @@ |
|||||
|
<?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.ChangeDeathDao"> |
||||
|
|
||||
|
<resultMap type="com.epmet.entity.ChangeDeathEntity" id="rentDeathMap"> |
||||
|
<result property="id" column="ID"/> |
||||
|
<result property="userId" column="USER_ID"/> |
||||
|
<result property="name" column="NAME"/> |
||||
|
<result property="idCard" column="ID_CARD"/> |
||||
|
<result property="mobile" column="MOBILE"/> |
||||
|
<result property="gender" column="GENDER"/> |
||||
|
<result property="type" column="TYPE"/> |
||||
|
<result property="joinDate" column="JOIN_DATE"/> |
||||
|
<result property="joinReason" column="JOIN_REASON"/> |
||||
|
<result property="removeDate" column="REMOVE_DATE"/> |
||||
|
<result property="removeReason" column="REMOVE_REASON"/> |
||||
|
<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"/> |
||||
|
<result property="customerId" column="CUSTOMER_ID"/> |
||||
|
</resultMap> |
||||
|
|
||||
|
|
||||
|
</mapper> |
||||
@ -0,0 +1,39 @@ |
|||||
|
<?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.ChangeRelocationDao"> |
||||
|
|
||||
|
<resultMap type="com.epmet.entity.ChangeRelocationEntity" id="changeRelocationMap"> |
||||
|
<result property="id" column="ID"/> |
||||
|
<result property="name" column="NAME"/> |
||||
|
<result property="gender" column="GENDER"/> |
||||
|
<result property="age" column="AGE"/> |
||||
|
<result property="pid" column="PID"/> |
||||
|
<result property="agencyId" column="AGENCY_ID"/> |
||||
|
<result property="agencyName" column="AGENCY_NAME"/> |
||||
|
<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="address" column="ADDRESS"/> |
||||
|
<result property="type" column="TYPE"/> |
||||
|
<result property="ownerName" column="OWNER_NAME"/> |
||||
|
<result property="oldDept" column="OLD_DEPT"/> |
||||
|
<result property="oldAddress" column="OLD_ADDRESS"/> |
||||
|
<result property="oldHome" column="OLD_HOME"/> |
||||
|
<result property="reason" column="REASON"/> |
||||
|
<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"/> |
||||
|
<result property="customerId" column="CUSTOMER_ID"/> |
||||
|
</resultMap> |
||||
|
|
||||
|
|
||||
|
</mapper> |
||||
@ -0,0 +1,41 @@ |
|||||
|
<?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.ChangeWelfareDao"> |
||||
|
|
||||
|
<resultMap type="com.epmet.entity.ChangeWelfareEntity" id="changeWelfareMap"> |
||||
|
<result property="id" column="ID"/> |
||||
|
<result property="userId" column="USER_ID"/> |
||||
|
<result property="gridId" column="GRID_ID"/> |
||||
|
<result property="name" column="NAME"/> |
||||
|
<result property="idCard" column="ID_CARD"/> |
||||
|
<result property="mobile" column="MOBILE"/> |
||||
|
<result property="gender" column="GENDER"/> |
||||
|
<result property="type" column="TYPE"/> |
||||
|
<result property="joinDate" column="JOIN_DATE"/> |
||||
|
<result property="joinReason" column="JOIN_REASON"/> |
||||
|
<result property="removeDate" column="REMOVE_DATE"/> |
||||
|
<result property="removeReason" column="REMOVE_REASON"/> |
||||
|
<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"/> |
||||
|
<result property="customerId" column="CUSTOMER_ID"/> |
||||
|
</resultMap> |
||||
|
<select id="selectByIdCard" resultType="com.epmet.entity.ChangeWelfareEntity"> |
||||
|
select * from pli_change_welfare |
||||
|
where ID_CARD=#{idCard} |
||||
|
and del_flag='0' |
||||
|
</select> |
||||
|
<update id="removeWelfare"> |
||||
|
update pli_change_welfare |
||||
|
set REMOVE_DATE=#{removeDate}, |
||||
|
REMOVE_REASON=#{removeReason}, |
||||
|
del_flag='1' |
||||
|
where id=#{id} |
||||
|
</update> |
||||
|
|
||||
|
|
||||
|
</mapper> |
||||
@ -0,0 +1,8 @@ |
|||||
|
<?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.IcMoveInRecordDao"> |
||||
|
|
||||
|
|
||||
|
|
||||
|
</mapper> |
||||
Loading…
Reference in new issue