后台:运营活动后台

This commit is contained in:
luying
2021-05-19 16:24:27 +08:00
parent 0c39b9ebb7
commit 91af65259c
14 changed files with 178 additions and 6 deletions

View File

@@ -0,0 +1,24 @@
import { Controller } from 'egg';
export default class ActivityController extends Controller {
public async getActivityList() {
const { ctx } = this;
const { page, pageSize, type, serverId, current, activityId } = ctx.request.body;
ctx.body = await ctx.service.activity.getActivityList(page, pageSize, type, serverId, current, activityId);
return
}
public async updateActivity() {
const { ctx } = this;
const { activityId, serverId, beginTime, endTime, type, data } = ctx.request.body;
ctx.body = await ctx.service.activity.updateActivity(activityId, serverId, beginTime, endTime, type, data);
}
public async deleteActivity() {
const { ctx } = this;
const { activityId } = ctx.request.body;
ctx.body = await ctx.service.activity.deleteActivity(activityId);
}
}