import { ResPage, StoreUser } from "@/api/interface/index";
import { PORT_NONE } from "@/api/config/servicePort";
import http from "@/api";

export const getThaliList = params => {
  return http.post<ResPage<StoreUser.ResStoreUserList>>(PORT_NONE + `/couponPlatform/getCouponList`, params);
};
export const delThaliById = (params: { id: string }) => {
  return http.get(PORT_NONE + `/couponPlatform/deleteCoupon`, params);
};
export const updateStatus = params => {
  return http.get(PORT_NONE + `/couponPlatform/updateCoupon`, params);
};
export const updateNum = params => {
  return http.get(PORT_NONE + `/couponPlatform/updateCouponSingleQty`, params);
};
export const addOrUpdateCoupon = params => {
  return http.post(PORT_NONE + `/couponPlatform/addOrUpdateCoupon`, params);
};
export const getVoucherDetail = params => {
  return http.get(PORT_NONE + `/couponPlatform/getCouponDetail`, params);
};
export const getHolidayList = (params: any) => {
  return http.get<StoreUser.ResStoreUserList>(PORT_NONE + `/couponPlatform/getHolidayList`, params);
};
