package com.yh.saas.plugin.yiliangyiyun.constant;

import lombok.Getter;

/**
 * 单据状态
 *
 * @author gdc
 */
public enum StatusEnum {

    //合同状态
    CONTRACT_WAIT("0", "待执行", "wait implementation"),
    CONTRACT_DO("1", "执行中", "Under implementation"),
    END_OF_SHIPMENT("2", "发运结束", "End of shipment"),
    CONTRACT_COMPLETED("3", "已完成", "Completed"),

    // 仓库显示标识
    HIDE("0","隐藏",""),
    SHOW("1","显示",""),


    // 出入库记录
    TEMPORARILY_STORED("1", "已暂存", "Temporarily stored"),
    SUBMITTED("3", "已提交", "Submitted"),

    //司机禁用标识
    DISABLED("1","已禁用","disabled"),
    NOT_DISABLE("0","未禁用","not_disable"),


    //调度状态
    PROCESS_DO("1", "执行中", "Under implementation"),
    PROCESS_COMPLETED("3", "已完成", "Completed"),


    //汽运状态
    NOT_DELIVERED("1","未送达",""),
    NOT_LOADED("2","未装车","not_loaded"),
    LOADED("3","已装车","loaded"),
    DELIVERED("5","已送达","delivered"),

    //运输管理状态
    TRAN_DO("1", "执行中", "Under implementation"),
    TRAN_COMPLETED("3", "已完成", "Completed"),

    //清仓状态
    NOT_CLEARED("1", "未清仓", "not_cleared"),
    CLEARED("3", "已清仓", "cleared"),

    //反馈状态
    FEEDBACK_DO("1", "执行中", "Under implementation"),
    FEEDBACK_COMPLETED("3", "已完货", "Completed"),

    //签订合同状态
    NOT_SIGNED("1", "未签合同", "not_signed"),
    SIGNED("3", "已签合同", "signed"),

    //出入库任务状态
    TASK_REVIEWED("1", "待审核", "reviewed"),
    TASK_RETURN("3", "已驳回", "return"),
    TASK_DO("5", "执行中", "Under implementation"),
    TASK_COMPLETED("7", "已完成", "Completed"),

    // 采购计划显示标识
    PURCHASE_HIDE("0","隐藏",""),
    PURCHASE_SHOW("1","显示",""),

    //采购/销售计划状态
    ORDER_REVIEWED("1", "待审核", "reviewed"),
    ORDER_PASSED("3", "已通过", "passed"),
    ORDER_REJECTED("4", "已驳回", "rejected"),
    ORDER_DEALED("5", "已成交", "dealed"),
    ORDER_COMPLETED("7", "已完成", "Completed"),

    //身份认证状态
    IDENTITY_REVIEWED("1", "审核中", "reviewed"),
    IDENTITY_FAILED("3", "未通过", "passed"),
    IDENTITY_COMPLETED("7", "已认证", "Completed"),

    //确认卸货状态
    NOT_CONFIRM("1", "未确认", "not_confirmed"),
    CONFIRM("3", "已确认", "confirmed"),

    // 采购入库统计,采购平仓统计
    PUR_REVIEWED("1", "待审核", ""),
    PUR_PAY("3", "部分付款", ""),
    PUR_PAYaLL("5", "全部付款", ""),
    PUR_RETURN("7", "已驳回", ""),

    // 采购平仓统计
    PUR_COLLECT("4", "部分收款", ""),
    PUR_COLLECTaLL("6", "全部收款", ""),
    TO_BE_RECEIVED("8", "待收款", ""),

    // 点价确认单附件状态
    Not_UPLOADED("0", "未上传", ""),
    UPLOADED("1", "已上传", ""),

    // 报表状态
    FORM_REVIEWED("1", "未审核", "reviewed"),
    STATISTICAL_AUDIT("2", "统计已审核", "Statistical audit"),
    FINANCIAL_AUDIT("7", "财务已审核", "Financial audit"),
    FINANCIAL_REJECTION("8", "财务已驳回", "Financial rejection"),
    MAKER_AUDIT("9", "决策人已审核", "Maker audit"),
    MAKER_REJECTION("11", "决策人已驳回", "Maker rejection"),

    // 收款状态
    NOT_COLLECTION("1", "待回款", ""),
    COLLECTION("3", "已回款", ""),
    // 收款状态
    NOT_COLLECTION_PAY("1", "待付款", ""),
//    COLLECTION("3", "已回款", ""),

    // 入驻公司状态
    TO_BE_REVIEWED("1", "待审核", ""),
    PASSED_COMP("3", "已通过", ""),
    FAIL_COMP("5", "未通过", ""),

    //收购价格状态
    PURCHASE_REVIEWED("1", "审核中", "reviewed"),
    PURCHASE_COMPLETED("3", "已通过", "passed"),
    PURCHASE_FAILED("4", "已驳回", "failed"),

    //质检检斤管理状态
    FIRST_INSPECTED("0", "已初检", "first inspected"),
    INSPECTED("1", "已质检", "inspected"),
    COMPLEX_INSPECTED("2", "已复检", "complex inspected"),
    WEIGHED_GROSS_WEIGHT("3", "已称毛重", "weighedgrossweight"),
    TARED("5", "已称皮重", "tared"),

    //付款管理状态
    TO_BE_SETTLED("1", "待结算", "to_be_settled"),

    //贸易仓单状态
    TO_BE_TRADERETURN("3", "待还款", "to_be_tradereturn"),
    RETURN_TRADE_WAREHOUSE_RECEIPT("0", "已驳回", "return_trade_warehouse_receipt"),

    //收购信息状态
    GRAIN_REVIEWED("5", "待审核", "grain_reviewed"),
    GRAIN_REJECT("7", "已驳回", "grain_reject"),
    GRAIN_ADOPT("9", "已通过", "grain_adopt"),
    //合同费用状态
    RECEIVED("1", "已收款", "received"),
    PENDING_PAYMENT("3", "待付款", "pending_payment"),
    PAID("5", "已付款", "paid"),


    ;
    @Getter
    private String flag;

    @Getter
    private String name;

    @Getter
    private String nameEn;

    @Getter
    private String description;

    private StatusEnum(String flag, String name, String nameEn) {
        this.flag = flag;
        this.name = name;
        this.nameEn = nameEn;
    }

    private StatusEnum(String flag, String name, String nameEn, String description) {
        this.flag = flag;
        this.name = name;
        this.nameEn = nameEn;
        this.description = description;
    }

    @Override
    public String toString() {
        return "[" + this.flag + "]" + this.name + "_" + this.nameEn;
    }
}
