export const packageTypeOptions = [
  { label: '体验课', value: 'EXPERIENCE', elTagType: 'warning' },
  { label: '课包', value: 'PACKAGE', elTagType: 'primary' },
  { label: '单课时', value: 'SINGLE', elTagType: 'info' },
  { label: '全期课程', value: 'COURSE', elTagType: 'success' },
  { label: '升学服务包', value: 'SERVICE', elTagType: 'danger' }
];

export const packageStatusOptions = [
  { label: '上架', value: '0', elTagType: 'success' },
  { label: '下架', value: '1', elTagType: 'danger' }
];

export const strategyTypeOptions = [
  { label: '打折', value: 'DISCOUNT' },
  { label: '减现', value: 'REDUCE' },
  { label: '加赠', value: 'GIFT' },
  { label: '返现', value: 'CASHBACK' }
];

export interface StrategyVO {
  id: number | string;
  packageId: number | string;
  strategyName: string;
  strategyType: string;
  conditionType: string;
  conditionValue: number;
  discountRate: number;
  reduceAmount: number;
  giftHours: number;
  cashbackAmount: number;
  priority: number;
  startAt: string;
  endAt: string;
  status: string;
  remark: string;
}

export interface StrategyForm {
  id?: number | string;
  strategyName: string;
  strategyType: string;
  conditionType: string;
  conditionValue: number;
  discountRate: number;
  reduceAmount: number;
  giftHours: number;
  cashbackAmount: number;
  priority: number;
  startAt: string;
  endAt: string;
  status: string;
  remark: string;
}

export interface PackageVO extends BaseEntity {
  id: number | string;
  packageCode: string;
  packageName: string;
  packageType: string;
  subject: string;
  grade: string;
  totalHours: number;
  lessonCount: number;
  validDays: number;
  maxStudents: number;
  listPrice: number;
  salePrice: number;
  costPrice: number;
  giftHours: number;
  hoursPerLesson: number;
  description: string;
  coverUrl: string;
  isHot: string;
  isGift: string;
  billingType: string;
  serviceCategory: string;
  status: string;
  saleStartAt: string;
  saleEndAt: string;
  remark: string;
  strategies: StrategyVO[];
}

export interface PackageForm {
  id: number | string | undefined;
  packageCode: string;
  packageName: string;
  packageType: string;
  subject: string;
  grade: string;
  totalHours: number;
  lessonCount: number;
  validDays: number;
  maxStudents: number;
  listPrice: number;
  salePrice: number;
  costPrice: number;
  giftHours: number;
  hoursPerLesson: number;
  description: string;
  coverUrl: string;
  isHot: string;
  isGift: string;
  billingType: string;
  serviceCategory: string;
  status: string;
  saleStartAt: string;
  saleEndAt: string;
  remark: string;
  strategies: StrategyForm[];
}

export interface PackageQuery extends PageQuery {
  packageCode: string;
  packageName: string;
  packageType: string;
  subject: string;
  grade: string;
  status: string;
  isHot: string;
}
