Files
2022-02-10 11:36:47 +08:00

26 lines
557 B
Go
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

package event
import (
"SciencesServer/app/common/model"
"SciencesServer/serve/logger"
)
type ActivityJoin struct{}
// Handle 活动参与
func (*ActivityJoin) Handle(arg ...interface{}) {
err := model.Create(&model.ActivityJoin{
ActivityID: arg[0].(uint64),
UID: arg[1].(uint64),
Identity: arg[2].(int),
Status: model.ActivityJoinStatusForSuccess,
})
if err != nil {
logger.ErrorF("Event 用户【%v - %v】加入活动错误%v", err, arg[1], arg[2])
}
}
func NewActivityJoin() *ActivityJoin {
return &ActivityJoin{}
}