export const isVipOptions: statusOptions[] = [
  { label: "全部", value: "" },
  { label: "非会员", value: "0" },
  { label: "会员", value: "1" },

];

export type optionsType = "isVip";

export function returnOptions(type: optionsType) {
  if (type === "isVip") {
    return isVipOptions;
  }
}

export function returnOptionsLabel(optionsType: optionsType, value: string | number) {
  const options = returnOptions(optionsType);
  if (!options) {
    return "";
  }
  const option = options.find((item) => item.value === value);
  return option ? option.label : "";
}

export interface options {
  label: string;
  value: string | number;
  [property: string]: any;
}
export interface statusOptions extends options {
}

export type payTypeValue =
  | ""
  | "cash"
  | "bank"
  | "scanCode"
  | "deposit"
  | "vipPay"
  | "arrears"
  | "virtual"
  | "arrears";

export interface payTypeOptions extends options {
  value: payTypeValue;
}
