Commit 2ff5eb44 authored by fangxinjiang's avatar fangxinjiang

不良记录导入

parent 4016e023
...@@ -16,6 +16,7 @@ ...@@ -16,6 +16,7 @@
*/ */
package com.yifu.cloud.plus.v1.yifu.archives.entity; package com.yifu.cloud.plus.v1.yifu.archives.entity;
import com.alibaba.excel.annotation.format.DateTimeFormat;
import com.baomidou.mybatisplus.annotation.*; import com.baomidou.mybatisplus.annotation.*;
import com.yifu.cloud.plus.v1.yifu.common.mybatis.base.BaseEntity; import com.yifu.cloud.plus.v1.yifu.common.mybatis.base.BaseEntity;
import io.swagger.v3.oas.annotations.media.Schema; import io.swagger.v3.oas.annotations.media.Schema;
...@@ -74,6 +75,7 @@ public class TEmpEducation extends BaseEntity { ...@@ -74,6 +75,7 @@ public class TEmpEducation extends BaseEntity {
/** /**
* 入学时间 * 入学时间
*/ */
@DateTimeFormat("yyyy-MM-dd hh:mm:ss")
@Schema(description = "入学时间") @Schema(description = "入学时间")
private LocalDate entryDate; private LocalDate entryDate;
...@@ -87,6 +89,7 @@ public class TEmpEducation extends BaseEntity { ...@@ -87,6 +89,7 @@ public class TEmpEducation extends BaseEntity {
/** /**
* 结业日期 * 结业日期
*/ */
@DateTimeFormat("yyyy-MM-dd hh:mm:ss")
@Schema(description = "结业日期") @Schema(description = "结业日期")
private LocalDate gradutionDate; private LocalDate gradutionDate;
......
...@@ -241,14 +241,15 @@ public class TEmpBadRecordServiceImpl extends ServiceImpl<TEmpBadRecordMapper, T ...@@ -241,14 +241,15 @@ public class TEmpBadRecordServiceImpl extends ServiceImpl<TEmpBadRecordMapper, T
list.clear(); list.clear();
} }
} }
excelWriter.finish();
}else { }else {
WriteSheet writeSheet = EasyExcel.writerSheet("不良记录"+index).build(); WriteSheet writeSheet = EasyExcel.writerSheet("不良记录"+index).build();
excelWriter.write(list,writeSheet); excelWriter.write(list,writeSheet);
excelWriter.finish();
} }
if (Common.isNotNull(list)){ if (Common.isNotNull(list)){
list.clear(); list.clear();
} }
excelWriter.finish();
out.flush(); out.flush();
}catch (Exception e){ }catch (Exception e){
log.error("执行异常" ,e); log.error("执行异常" ,e);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment