Browse Source

新冠病毒疫苗接种人员信息台账

master
wanggongfeng 3 years ago
parent
commit
7c958d6fd9
  1. 14
      epmet-user/epmet-user-server/src/main/java/com/epmet/controller/IcVaccinePrarmeterController.java
  2. 41
      epmet-user/epmet-user-server/src/main/java/com/epmet/excel/IcVaccinePrarmeterExcel.java
  3. BIN
      epmet-user/epmet-user-server/src/main/resources/excel/ic_vaccine_prarmeter_excel.xls

14
epmet-user/epmet-user-server/src/main/java/com/epmet/controller/IcVaccinePrarmeterController.java

@ -1,10 +1,12 @@
package com.epmet.controller; package com.epmet.controller;
import cn.afterturn.easypoi.excel.entity.TemplateExportParams;
import com.epmet.commons.tools.annotation.LoginUser; import com.epmet.commons.tools.annotation.LoginUser;
import com.epmet.commons.tools.aop.NoRepeatSubmit; import com.epmet.commons.tools.aop.NoRepeatSubmit;
import com.epmet.commons.tools.dto.form.PageFormDTO; import com.epmet.commons.tools.dto.form.PageFormDTO;
import com.epmet.commons.tools.page.PageData; import com.epmet.commons.tools.page.PageData;
import com.epmet.commons.tools.security.dto.TokenDto; import com.epmet.commons.tools.security.dto.TokenDto;
import com.epmet.commons.tools.utils.ExcelPoiUtils;
import com.epmet.commons.tools.utils.ExcelUtils; import com.epmet.commons.tools.utils.ExcelUtils;
import com.epmet.commons.tools.utils.Result; import com.epmet.commons.tools.utils.Result;
import com.epmet.commons.tools.validator.AssertUtils; import com.epmet.commons.tools.validator.AssertUtils;
@ -24,6 +26,7 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpServletResponse;
import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
@ -104,6 +107,17 @@ public class IcVaccinePrarmeterController {
} }
/**
* 导出模板
* @param response
* @throws Exception
*/
@PostMapping("exporttemplate")
public void exportTemplate( HttpServletResponse response) throws Exception {
TemplateExportParams templatePath = new TemplateExportParams("excel/ic_vaccine_prarmeter_excel.xls");
ExcelPoiUtils.exportExcel(templatePath ,new HashMap<>(),"新冠病毒疫苗接种人员信息台账",response);
}
} }

41
epmet-user/epmet-user-server/src/main/java/com/epmet/excel/IcVaccinePrarmeterExcel.java

@ -14,49 +14,32 @@ import java.util.Date;
@Data @Data
public class IcVaccinePrarmeterExcel { public class IcVaccinePrarmeterExcel {
@Excel(name = "主键")
private String id;
@Excel(name = "客户Id customer.id")
private String customerId;
@Excel(name = "网格ID")
private String gridId;
@Excel(name = "网格名称") @Excel(name = "网格名称")
private String gridName; private String gridName;
@Excel(name = "组织Id")
private String agencyId;
@Excel(name = "组织的pids") @Excel(name = "组织的pids")
private String pids; private String pids;
@Excel(name = "所属小区ID;")
private String villageId;
@Excel(name = "所属小区名称") @Excel(name = "所属小区名称")
private String villageName; private String villageName;
@Excel(name = "所属楼宇Id")
private String buildId;
@Excel(name = "所属楼宇名称") @Excel(name = "所属楼宇名称")
private String buildName; private String buildName;
@Excel(name = "单元id")
private String unitId;
@Excel(name = "单元名") @Excel(name = "单元名")
private String unitName; private String unitName;
@Excel(name = "所属家庭Id")
private String homeId;
@Excel(name = "房间名") @Excel(name = "房间名")
private String homeName; private String homeName;
@Excel(name = "户口性质:0户籍 1外来") @Excel(name = "户口性质", replace = {"户籍_0","外来_1"})
private String householdType; private String householdType;
@Excel(name = "姓名") @Excel(name = "姓名")
@ -89,29 +72,11 @@ public class IcVaccinePrarmeterExcel {
@Excel(name = "第三次接种地点") @Excel(name = "第三次接种地点")
private String thirdVacSite; private String thirdVacSite;
@Excel(name = "原因:禁忌症/拒绝接种/其他原因") @Excel(name = "原因")
private String reason; private String reason;
@Excel(name = "备注") @Excel(name = "备注")
private String note; private String note;
@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;
} }

BIN
epmet-user/epmet-user-server/src/main/resources/excel/ic_vaccine_prarmeter_excel.xls

Binary file not shown.
Loading…
Cancel
Save