import {
	yghttp
} from '@/request/index.js';


// 获取活动详细信息
export const getActivity = (activityId) => {
	return yghttp.get(`/activity/info/${activityId}`)
}


// 获取活动奖品列表
export const getActivityPrize = (activityId) => {
	return yghttp.get(`/activity/prize/list/${activityId}`)
}


// 抽奖
export const getActivityLottery = (param) => {
	return yghttp.post(`/activity/lottery`, param)
}


// 我的中奖记录
export const getMyWinning = () => {
	return yghttp.get('/activity/myWinning')
}

// 补充信息
export const setSupplement = (param) => {
	return yghttp.post('/activity/supplement', param)
}

// 获取活动人的信息
export const getActivityUserInfo = (activityId) => {
	return yghttp.get(`/activity/userInfo/${activityId}`)
}

// 最新中奖记录
export const getWinningRecords = (activityId) => {
	return yghttp.get(`/activity/winning/records/${activityId}`)
}


// 新增活动总uv
export const setActivityViewVolume = (param) => {
	return yghttp.post(`/activity/activityViewVolume/save`, param)
}
// 查询活动商品列表
export const getActivityGoods = (param) => {
	return yghttp.get(`/activityGoods/page`, param)
}

// 新增活动分享
export const setShareRecord = (param) => {
	return yghttp.post(`/activity/activityShareRecord/add`, param)
}
