瀏覽代碼

增加模版消息发送日志

xiexiaoyuan 2 年之前
父節點
當前提交
c37ad192e9
共有 2 個文件被更改,包括 2 次插入0 次删除
  1. 1 0
      models/user_template_record.go
  2. 1 0
      services/wechat_send_msg.go

+ 1 - 0
models/user_template_record.go

@@ -16,6 +16,7 @@ type UserTemplateRecord struct {
 	SendStatus int
 	SendType   int
 	UniqueCode string
+	WxAppId    string
 }
 
 //添加banner

+ 1 - 0
services/wechat_send_msg.go

@@ -218,6 +218,7 @@ func toSendTemplateMsg(wxAppId string, data []byte, resource string, sendType in
 		}
 		tr.UniqueCode = uniqueCode
 		tr.SendType = sendType
+		tr.WxAppId = wxAppId
 		go func() {
 			err = models.AddUserTemplateRecord(tr)
 			if err != nil {