package com.chushang.task.enums;

import com.baomidou.mybatisplus.annotation.IEnum;
import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * @auther: zhao
 * @date: 2024/6/12 16:34
 */
@Getter
@AllArgsConstructor
public enum TaskStatusEnum implements IEnum<Integer> {
    CREATE(0,"新建"),
    DISPATCH(1, "已下发"),
    EXECUTING(2, "执行中"),

    EXECUTE_FAIL(3, "执行失败"),
    EXECUTE_SUCCESS(4, "执行成功"),

    CANCEL(5, "已取消"),
    ;
    private final Integer code;
    private final String desc;

    @Override
    public Integer getValue() {
        return code;
    }
}
