forked from rongchao/epmet-cloud-rizhao
4 changed files with 130 additions and 4 deletions
@ -0,0 +1,52 @@ |
|||||
|
package com.epmet.model; |
||||
|
|
||||
|
import com.alibaba.excel.annotation.ExcelProperty; |
||||
|
import lombok.Data; |
||||
|
import org.hibernate.validator.constraints.Length; |
||||
|
|
||||
|
/** |
||||
|
* @Author zxc |
||||
|
* @DateTime 2022/2/13 1:26 下午 |
||||
|
* @DESC |
||||
|
*/ |
||||
|
@Data |
||||
|
public class HouseInfoModel { |
||||
|
|
||||
|
@ExcelProperty(value = "所属组织") |
||||
|
private String agencyName; |
||||
|
|
||||
|
@ExcelProperty(value = "所属网格") |
||||
|
private String gridName; |
||||
|
|
||||
|
@ExcelProperty(value = "所属小区") |
||||
|
@Length(max=50,message = "不能超过50个字") |
||||
|
private String neighborHoodName; |
||||
|
|
||||
|
@ExcelProperty(value = "所属楼栋") |
||||
|
private String buildingName; |
||||
|
|
||||
|
@ExcelProperty(value = "单元号") |
||||
|
private Integer buildingUnit; |
||||
|
|
||||
|
@ExcelProperty(value = "门牌号") |
||||
|
private String doorName; |
||||
|
|
||||
|
@ExcelProperty(value = "房屋类型") |
||||
|
private String houseType; |
||||
|
|
||||
|
@ExcelProperty(value = "房屋用途") |
||||
|
private String purpose; |
||||
|
|
||||
|
@ExcelProperty(value = "出租") |
||||
|
private String rentFlag; |
||||
|
|
||||
|
@ExcelProperty(value = "房主姓名") |
||||
|
private String ownerName; |
||||
|
|
||||
|
@ExcelProperty(value = "房主电话") |
||||
|
private String ownerPhone; |
||||
|
|
||||
|
@ExcelProperty(value = "房主身份证") |
||||
|
private String ownerIdCard; |
||||
|
|
||||
|
} |
@ -0,0 +1,33 @@ |
|||||
|
package com.epmet.model; |
||||
|
|
||||
|
import com.alibaba.excel.context.AnalysisContext; |
||||
|
import com.alibaba.excel.event.AnalysisEventListener; |
||||
|
import com.epmet.dto.form.ImportInfoFormDTO; |
||||
|
|
||||
|
/** |
||||
|
* @Author zxc |
||||
|
* @DateTime 2022/2/13 1:25 下午 |
||||
|
* @DESC |
||||
|
*/ |
||||
|
public class ImportHouseInfoListener extends AnalysisEventListener<HouseInfoModel> { |
||||
|
|
||||
|
private ImportInfoFormDTO formDTO; |
||||
|
|
||||
|
public ImportHouseInfoListener(ImportInfoFormDTO formDTO){ |
||||
|
this.formDTO = formDTO; |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
public void invoke(HouseInfoModel data, AnalysisContext context) { |
||||
|
System.out.println("aaa"); |
||||
|
if (null == data){ |
||||
|
return; |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
@Override |
||||
|
public void doAfterAllAnalysed(AnalysisContext context) { |
||||
|
|
||||
|
} |
||||
|
|
||||
|
} |
Loading…
Reference in new issue