package cn.axzo.workflow.common.enums;

import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * 审批人所在范围枚举
 *
 * @author wangli
 * @since 2023/11/16 10:14
 */
@Getter
@AllArgsConstructor
public enum ApproverScopeEnum {
    entWorkspace("entWorkspace", "企业工作台", "entWorkspaceSelector"),
    projectWorkspace("projectWorkspace", "项目工作台","projectWorkspaceSelector"),
    preTaskUser("preTaskUser", "上节点审批人所在单位","preTaskUserSelector"),
    preTaskSpecified("preTaskSpecified", "上节点审批人指定","preTaskUserSelector"),
    ;
    private String type;
    private String desc;
    private String processor;

    ApproverScopeEnum(String type, String desc) {
        this.type = type;
        this.desc = desc;
    }

    public String getType() {
        return type;
    }

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

    public String getDesc() {
        return desc;
    }

    public void setDesc(String desc) {
        this.desc = desc;
    }

    public boolean selectWorkspace() {
        return this == ApproverScopeEnum.projectWorkspace;
    }
}
