cczg-lottery-activity/api/api.js

43 lines
1.3 KiB
JavaScript
Raw Normal View History

2024-05-30 11:04:54 +08:00
// api.js页面
import request from '../util/request.js' //引入request.js
const api = request
const imgUrl = "http://47.109.21.59/"
export default {
imgUrl,
getcodes: data => {
return api.request('/front/loginSendSms', 'POST', data) //接口地址
},
login: data => {
return api.request('/front/loginBySms', 'POST', data) //接口地址
},
logout:data=>{
return api.request('/front/logout','GET')
},
getAccountInfo: data => {
return api.request('/front/getAccountInfo', 'GET', data) //接口地址
},
getproducts: data => {
return api.request('/front/homeData', 'GET', data) //接口地址
},
getorderlist: data => {
return api.request('/front/order/list', 'GET', data) //接口地址
},
getquestionlist: id => {
return api.request('/front/question/list/'+id, 'GET') //接口地址
},
getprizeinfo: id => {
return api.request('/front/activity/prize/info/'+id, 'GET') //接口地址
},
createorder: data => {
return api.request('/front/order/create','POST',data) //接口地址
},
answerFinished: (data) => {
return api.request('/front/activity/answerFinished', 'PUT', data) //接口地址
},
lottery: data => {
return api.request('/front/activity/draw/lottery/' + data.id, 'GET') //接口地址
},
create: data => {
return api.request('/front/userWhite/create', 'POST',data) //接口地址
},
}