import http from '@/http/http.js'

//  获取弹窗信息
export const announcement = (data) => {
	return http.request({
		url: '/announcement',
		data
	})
}
//  获取公告
export const messageselectMessage = (data) => {
	return http.request({
		url: '/message/selectMessage',
		data: {
			page: 1,
			limit: 5,
			state: 1
		}
	})
}
//  获取推荐视频
export const courseselectCourse = (data) => {
	return http.request({
		url: '/course/selectCourse',
		data
	})
}
// 兑换
export const userPrizeExchangeexchange = (data) => {
	return http.request({
		url: '/userPrizeExchange/exchange',
		data,
		method:'post'
	})
}
// 搜索	 
export const selectCourseTitles = (data) => {
	return http.request({
		url: '/course/selectCourseTitles',
		data
	})
}

// 抽奖列表
export const selectDiscSpinning = (data) => {
	return http.request({
		url: '/discSpinning/selectDiscSpinning',
		data
	})
}
// 抽奖
export const discSpinningdraw = (data) => {
	return http.request({
		url: '/discSpinning/draw',
		data
	})
}


export const selectUserMoney = (data) => {
	return http.request({
		url: '/moneyDetails/selectUserMoney',
		data
	})
}
export const drawCount = (data) => {
	return http.request({
		url: '/discSpinning/drawCount',
		data
	})
}
// 获取记录
export const selectDiscSpinningRecord = (data) => {
	return http.request({
		url: '/discSpinningRecord/selectDiscSpinningRecord',
		data
	})
}
// 兑换记录
export const userPrizeExchange = (data) => {
	return http.request({
		url: '/userPrizeExchange/page',
		data
	})
}

//记录支付跳转
export const insertuserisopen = (data) => {
	return http.request({
		url: 'order/insertuserisopen',
		data
	})
}