import request from '@/config/axios'

export interface CurrencyRechargePackageVO {
  id: number
  name: string
  payPrice: number
  bonusPrice: number
  status: number
}

// 查询套餐充值列表
export const getCurrencyRechargePackagePage = async (params) => {
  return await request.get({ url: '/pay/currency-recharge-package/page', params })
}

// 查询套餐充值详情
export const getCurrencyRechargePackage = async (id: number) => {
  return await request.get({ url: '/pay/currency-recharge-package/get?id=' + id })
}

// 新增套餐充值
export const createCurrencyRechargePackage = async (data: CurrencyRechargePackageVO) => {
  return await request.post({ url: '/pay/currency-recharge-package/create', data })
}

// 修改套餐充值
export const updateCurrencyRechargePackage = async (data: CurrencyRechargePackageVO) => {
  return await request.put({ url: '/pay/currency-recharge-package/update', data })
}

// 删除套餐充值
export const deleteCurrencyRechargePackage = async (id: number) => {
  return await request.delete({ url: '/pay/currency-recharge-package/delete?id=' + id })
}
