You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

101 lines
2.1 KiB
JavaScript

6 years ago
/**
* 登录 server层
* @author yuankai
* @date 2020/05/19
*/
5 years ago
import http from '../CommonHttp'
6 years ago
/**
* 活动池列表
* @param params 参数
* @param call 成功的回调
* @returns {Promise<any>} 返回Promise对象
*/
export function getActivityList(params, call) {
5 years ago
return http.get('/activity/schedule/list/all', params).then(call)
6 years ago
}
/**
* 新增或修改活动池
*/
export function addOreditActivity(params, call) {
5 years ago
return http.post('/activity/schedule/save', params).then(call)
6 years ago
}
/**
* 获取活动池详情
*/
export function getActivityInfo(params, call) {
5 years ago
return http.get('/activity/schedule/detail', params).then(call)
6 years ago
}
/**
* 上传图片
*/
export function uploadImg(params, call) {
5 years ago
return http.post('/upload', params).then(call)
6 years ago
}
/**
* 获取零售公司
*/
export function getCompany(params, call) {
5 years ago
return http.get('/retail/company', params).then(call)
}
/**
* 获取店铺
*/
export function getShop(params, call) {
5 years ago
return http.post('poi/store/user/shopDTO', params).then(call)
}
6 years ago
/**
* 根据活动池新建/编辑实例
*/
export function saveActivityData(params, call) {
5 years ago
return http.post('activity/instance/save', params).then(call)
6 years ago
}
6 years ago
/**
* 活动实例分页列表
*/
export function getActivityTableData(params, call) {
5 years ago
return http.get('activity/instance/list', params).then(call)
6 years ago
}
5 years ago
/**
* 活动实例终止
*/
export function instanceTerminate(params, call) {
5 years ago
return http.post('activity/instance/terminate', params).then(call)
5 years ago
}
/**
* 活动实例详情
*/
export function instanceDetail(params, call) {
5 years ago
return http.post('activity/instance/detail', params).then(call)
}
export function activityCodeList(params, call) {
return http.get('activity/instance/StoreCode', params).then(call)
}
export function guideCodeList(params, call) {
return http.get('activity/instance/GuideCode', params).then(call)
5 years ago
}
6 years ago
export default {
getActivityList,
addOreditActivity,
getActivityInfo,
uploadImg,
getCompany,
6 years ago
getShop,
6 years ago
getActivityTableData,
5 years ago
saveActivityData,
5 years ago
instanceTerminate,
instanceDetail,
5 years ago
activityCodeList,
guideCodeList,
}