From cb14bbf9c77a1fed3d8559f1891070516aa61c1e Mon Sep 17 00:00:00 2001 From: lijianbin <513837235@.qq.com> Date: Tue, 9 Nov 2021 11:36:33 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B6=88=E6=81=AF=E6=8F=90=E9=80=81=E5=A2=9E?= =?UTF-8?q?=E5=8A=A0=E9=A2=9D=E5=A4=96=E5=8F=82=E6=95=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- client.go | 6 ++++-- common.go | 3 ++- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/client.go b/client.go index 4cb4dea..5bba0a0 100644 --- a/client.go +++ b/client.go @@ -71,7 +71,8 @@ func SendMsg(site_id, dbname, business_id, domainname, msg_type, order_sn, memo } -func SendNotcie(site_id, dbname, manager_id, thumb string, template_Data map[string]string, url ...string) (bool, error) { +// target_type:目标类型,商品或文章 target_id:目标ID +func SendNotcie(site_id, dbname, manager_id, target_type, target_id string, template_Data map[string]string, url ...string) (bool, error) { if dbname == "" || dbname == "" || manager_id == "" { return false, errors.New("参数错误") } @@ -87,7 +88,8 @@ func SendNotcie(site_id, dbname, manager_id, thumb string, template_Data map[str arg.SiteId = site_id arg.Dbname = dbname arg.ManagerId = manager_id - arg.Thumb = thumb + arg.TargetType = target_type + arg.TargetId = target_id arg.TemplateData = template_Data data_json, err := json.Marshal(arg) diff --git a/common.go b/common.go index efccdf3..cf4b016 100644 --- a/common.go +++ b/common.go @@ -25,7 +25,8 @@ type MsgSend struct { type NoticeSend struct { Req ManagerId string - Thumb string + TargetType string + TargetId string TemplateData map[string]string }