package common import ( "hudongzhuanjia/controllers" "hudongzhuanjia/libs/im" im_service "hudongzhuanjia/services/im" "time" ) type ImTestCtl struct { controllers.BaseCtl } func (t *ImTestCtl) SendNotice() { activityId := t.MustGetInt64("activity_id") status := t.MustGetInt("status") im_service.SendGroupCustomMessage(activityId, im.NoticeStatus(status), map[string]interface{}{ "customer_id": 1, "shake_red_envelope_rule_id": 2, "timestamp": time.Now().Unix(), }) t.SUCCESS("发送成功") }