package com.bonus.canteen.core.pay.constants;

public enum PayStateEnum {
   UN_PAY(1, "未支付"),
   PAY_INPROCESS(2, "支付中"),
   PAY_SUCC(3, "支付成功"),
   PAY_FAIL(4, "支付失败"),
   PAY_CLOSE(5, "支付关闭"),
   PART_PAY(6, "部分支付");

   private final Integer key;
   private final String desc;


   private PayStateEnum(Integer key, String desc) {
      this.key = key;
      this.desc = desc;
   }

   public Integer getKey() {
      return this.key;
   }

   public String getDesc() {
      return this.desc;
   }
   public static boolean isUnPay(Integer key) {
      return !UN_PAY.getKey().equals(key);
   }

}
