package com.qmth.sop.business.entity;

import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import com.qmth.sop.common.enums.JobStatusEnum;
import com.qmth.sop.common.enums.JobTypeEnum;
import com.qmth.sop.common.enums.JobUnitEnum;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import java.io.Serializable;

/**
 * <p>
 * 系统任务表
 * </p>
 *
 * @author wangliang
 * @since 2023-08-01
 */
@ApiModel(value = "SysJob对象", description = "系统任务表")
public class SysJob implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "主键")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long id;

    @ApiModelProperty(value = "crm单号")
    private String crmNo;

    @ApiModelProperty(value = "sop单号")
    private String sopNo;

    @ApiModelProperty(value = "服务单元id")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long serviceId;

    @ApiModelProperty(value = "责任人id")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long userId;

    @ApiModelProperty(value = "任务时间")
    private Long jobTime;

    @ApiModelProperty(value = "类型，BEFORE：任务前提醒，AFTER：任务后提醒")
    private JobTypeEnum type;

    @ApiModelProperty(value = "单位，HOUR：小时，MINUTE：分钟")
    private JobUnitEnum unit;

    @ApiModelProperty(value = "状态，NOT_EXEC：未执行，EXEC：已执行")
    private JobStatusEnum status;

    @ApiModelProperty(value = "执行时间")
    private Long execTime;

    @ApiModelProperty(value = "创建时间")
    private Long createTime;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getCrmNo() {
        return crmNo;
    }

    public void setCrmNo(String crmNo) {
        this.crmNo = crmNo;
    }

    public String getSopNo() {
        return sopNo;
    }

    public void setSopNo(String sopNo) {
        this.sopNo = sopNo;
    }

    public Long getServiceId() {
        return serviceId;
    }

    public void setServiceId(Long serviceId) {
        this.serviceId = serviceId;
    }

    public Long getUserId() {
        return userId;
    }

    public void setUserId(Long userId) {
        this.userId = userId;
    }

    public Long getJobTime() {
        return jobTime;
    }

    public void setJobTime(Long jobTime) {
        this.jobTime = jobTime;
    }

    public JobTypeEnum getType() {
        return type;
    }

    public void setType(JobTypeEnum type) {
        this.type = type;
    }

    public JobUnitEnum getUnit() {
        return unit;
    }

    public void setUnit(JobUnitEnum unit) {
        this.unit = unit;
    }

    public JobStatusEnum getStatus() {
        return status;
    }

    public void setStatus(JobStatusEnum status) {
        this.status = status;
    }

    public Long getExecTime() {
        return execTime;
    }

    public void setExecTime(Long execTime) {
        this.execTime = execTime;
    }

    public Long getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Long createTime) {
        this.createTime = createTime;
    }
}
