acdr-ui/dist/dev/mp-weixin/modules/mall/sheep/api/promotion/seckill.js

30 lines
999 B
JavaScript
Raw Normal View History

2024-09-19 07:20:14 +08:00
"use strict";
2024-10-01 09:15:35 +08:00
const modules_mall_sheep_request_index = require("../../request/index.js");
2024-09-19 07:20:14 +08:00
const SeckillApi = {
// 获得秒杀时间段列表
getSeckillConfigList: () => {
2024-10-01 09:15:35 +08:00
return modules_mall_sheep_request_index.request({ url: "promotion/seckill-config/list", method: "GET" });
2024-09-19 07:20:14 +08:00
},
// 获得当前秒杀活动
getNowSeckillActivity: () => {
2024-10-01 09:15:35 +08:00
return modules_mall_sheep_request_index.request({ url: "promotion/seckill-activity/get-now", method: "GET" });
2024-09-19 07:20:14 +08:00
},
// 获得秒杀活动分页
getSeckillActivityPage: (params) => {
2024-10-01 09:15:35 +08:00
return modules_mall_sheep_request_index.request({ url: "promotion/seckill-activity/page", method: "GET", params });
2024-09-19 07:20:14 +08:00
},
/**
* 获得秒杀活动明细
* @param {number} id 秒杀活动编号
* @return {*}
*/
getSeckillActivity: (id) => {
2024-10-01 09:15:35 +08:00
return modules_mall_sheep_request_index.request({
2024-09-19 07:20:14 +08:00
url: "promotion/seckill-activity/get-detail",
method: "GET",
params: { id }
});
}
};
exports.SeckillApi = SeckillApi;