package com.bonus.canteen.core.order.common.constants;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

//public enum CheckStateEnum implements LeExcelFieldEnum<CheckStateEnum> {
public enum CheckStateEnum {
   WAIT(1, "审核中"),
   PASS(2, "退款成功"),
   UN_PASS(3, "审核未通过"),
   REFUNDING(4, "退款中"),
   REFUND_FAIL(5, "退款失败");

   private final Integer key;
   private final String desc;

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

   public static String getDesc(Integer key) {
      CheckStateEnum[] var1 = values();
      int var2 = var1.length;

      for(int var3 = 0; var3 < var2; ++var3) {
         CheckStateEnum temp = var1[var3];
         if (temp.getKey().equals(key)) {
            return temp.getDesc();
         }
      }

      return "";
   }

   public static List<Map<String, Object>> getAllEnumsList() {
      CheckStateEnum[] enums = values();
      List<Map<String, Object>> list = new ArrayList();
      CheckStateEnum[] var2 = enums;
      int var3 = enums.length;

      for(int var4 = 0; var4 < var3; ++var4) {
         CheckStateEnum stateEnum = var2[var4];
         Map<String, Object> map = new HashMap();
         map.put("key", stateEnum.getKey());
         map.put("value", stateEnum.getDesc());
         list.add(map);
      }

      return list;
   }

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

   public String getDesc() {
      return this.desc;
   }

   // $FF: synthetic method
   private static CheckStateEnum[] $values() {
      return new CheckStateEnum[]{WAIT, PASS, UN_PASS, REFUNDING, REFUND_FAIL};
   }

//   public static class ExcelConvertor extends LeExcelFieldConvertor<CheckStateEnum> {
//      public ExcelConvertor() {
//         super(CheckStateEnum.class);
//      }
//   }
}
