package com.sckw.fleet.model.dto;

import com.alibaba.excel.annotation.ExcelProperty;
import com.sckw.excel.annotation.ExcelContext;
import lombok.Data;
import lombok.experimental.Accessors;

/**
 * @author zk
 * @desc 司机信息导出
 * @date 2023/7/11 0011
 */
@Data
@Accessors(chain = true)
@ExcelContext(fileName = "司机信息", sheetName = "司机信息")
public class KwfDriverExport {

    @ExcelProperty(value = "司机姓名", index = 0)
    private String name;

    /**
     * 电话
     */
    @ExcelProperty(value = "电话", index = 1)
    private String phone;

    /**
     * 身份证号
     */
    @ExcelProperty(value = "身份证号", index = 2)
    private String idcard;

    /**
     * 身份证有效时间
     */
    @ExcelProperty(value = "身份证有效时间", index = 3)
    private String idcardExpireTime;

    /**
     * 身份证住址
     */
    @ExcelProperty(value = "身份证住址", index = 4)
    private String address;

    /**
     * 驾驶证编号
     */
    @ExcelProperty(value = "驾驶证编号", index = 5)
    private String driverNo;

    /**
     * 准驾车型
     */
    @ExcelProperty(value = "准驾车型", index = 6)
    private String licenseType;

    /**
     * 驾驶证有效期至
     */
    @ExcelProperty(value = "驾驶证有效期至", index = 7)
    private String licenseExpireTime;

    /**
     * 驾驶证发证机关
     */
    @ExcelProperty(value = "驾驶证发证机关", index = 8)
    private String licenseGrantUnit;

    /**
     * 从业资格证号
     */
    @ExcelProperty(value = "从业资格证号", index = 9)
    private String qualiNo;

    /**
     * 企业名称
     */
    @ExcelProperty(value = "企业名称", index = 10)
    private String firmName;

    /**
     * 车队班组
     */
    @ExcelProperty(value = "车队班组", index = 11)
    private String fleetName;

    /**
     * 车牌号
     */
    @ExcelProperty(value = "车牌号", index = 12)
    private String truckNo;

    /**
     * 创建人
     */
    @ExcelProperty(value = "创建人", index = 13)
    private String createByName;

    /**
     * 创建时间
     */
    @ExcelProperty(value = "创建时间", index = 14)
    private String createTime;

    /**
     * 更新时间
     */
    @ExcelProperty(value = "更新时间", index = 15)
    private String updateTime;

    /**
     * 备注
     */
    @ExcelProperty(value = "备注", index = 16)
    private String remark;

    /**
     * 状态
     */
    @ExcelProperty(value = "状态", index = 17)
    private String statusName;

    /**
     * 状态
     */
    private int status;

    public String getStatusName() {
        return status == 1 ? "已认证" : status == 2 ? "临时" : "异常";
    }
}
