CaseExcelData.java 1.94 KB
package com.ash.excelData;

import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.ColumnWidth;
import com.alibaba.excel.annotation.write.style.ContentRowHeight;
import com.alibaba.excel.annotation.write.style.ContentStyle;
import com.alibaba.excel.annotation.write.style.HeadRowHeight;
import com.ash.base.excelOpt.ExcelCheck;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;
import java.util.Date;

@Data
@ContentRowHeight(15)
@HeadRowHeight(20)
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class CaseExcelData  implements Serializable {
    private static final long serialVersionUID = 1L;

    @ExcelCheck(canEmpty = false, canRepeat = false)
    @ExcelProperty(value = "案件标识", index = 0)
    @ContentStyle(dataFormat = 49)
    @ColumnWidth(25)
    private String mark;

    @ExcelCheck(canEmpty = false, canRepeat = false)
    @ExcelProperty(value = "案件编号", index = 1)
    @ContentStyle(dataFormat = 49)
    @ColumnWidth(25)
    private String code;

    @ExcelCheck(canEmpty = false)
    @ExcelProperty(value = "案件名称", index = 2)
    @ContentStyle(dataFormat = 49)
    @ColumnWidth(25)
    private String name;

    @ExcelCheck(canEmpty = false)
    @ExcelProperty(value = "案件详情", index = 3)
    @ContentStyle(dataFormat = 49)
    @ColumnWidth(25)
    private String caseDetail;

    @ExcelCheck(canEmpty = false)
    @ExcelProperty(value = "接警时间", index = 4)
    @ContentStyle(dataFormat = 49)
    @ColumnWidth(25)
    private Date alarmDate;

    @ExcelCheck(canEmpty = false)
    @ExcelProperty(value = "立案时间", index = 5)
    @ContentStyle(dataFormat = 49)
    @ColumnWidth(25)
    private Date filingDate;

    @ExcelCheck(canEmpty = false)
    @ExcelProperty(value = "立案单位", index = 6)
    @ContentStyle(dataFormat = 49)
    @ColumnWidth(25)
    private String filingUnit;
}