|
|
@ -17,6 +17,20 @@ type LotteryDrawCtl struct { |
|
|
|
controllers.AuthorCtl |
|
|
|
} |
|
|
|
|
|
|
|
// 屏蔽
|
|
|
|
func (t *LotteryDrawCtl) Block() { |
|
|
|
activityId := t.MustGetInt("activity_id") |
|
|
|
status := t.MustGet("status") |
|
|
|
|
|
|
|
module, exist, err := activity_service.GetModuleService(define.MODULE_LOTTERY, activityId) |
|
|
|
t.CheckErr(err) |
|
|
|
t.Assert(exist, code.MSG_MODULE_NOT_EXIST, "模块不存在") |
|
|
|
module.BesideRepeat = status |
|
|
|
_, err = models.Update(module.Id, module, "beside_repeat") |
|
|
|
t.CheckErr(err) |
|
|
|
t.SUCCESS("操作成功") |
|
|
|
} |
|
|
|
|
|
|
|
//开始抽奖
|
|
|
|
func (t *LotteryDrawCtl) Start() { |
|
|
|
ladderId := t.MustGetInt("lottery_draw_ladder_id") |
|
|
|