From 416f87f4bb963008b5fca8d3d0fd5074ee7b3f0c Mon Sep 17 00:00:00 2001 From: wangchuxiao Date: Tue, 29 Mar 2022 15:50:20 +0800 Subject: [PATCH] tag --- internal/rpc/office/office.go | 6 +++--- pkg/common/db/mongoModel.go | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/internal/rpc/office/office.go b/internal/rpc/office/office.go index ebb1de2a2..508d0c04c 100644 --- a/internal/rpc/office/office.go +++ b/internal/rpc/office/office.go @@ -166,9 +166,9 @@ func (s *officeServer) SendMsg2Tag(_ context.Context, req *pbOffice.SendMsg2TagR groupUserIDList = append(groupUserIDList, userIDList...) } var userIDList []string - userIDList = append(groupUserIDList, tagUserIDList...) - userIDList = append(groupUserIDList, groupUserIDList...) - userIDList = append(groupUserIDList, req.UserList...) + userIDList = append(userIDList, tagUserIDList...) + userIDList = append(userIDList, groupUserIDList...) + userIDList = append(userIDList, req.UserList...) userIDList = utils.RemoveUserIDRepByMap(userIDList) for i, userID := range userIDList { if userID == req.SendID { diff --git a/pkg/common/db/mongoModel.go b/pkg/common/db/mongoModel.go index 36550e50c..bcc05a295 100644 --- a/pkg/common/db/mongoModel.go +++ b/pkg/common/db/mongoModel.go @@ -568,7 +568,7 @@ func (d *DataBases) GetTagSendLogs(userID string, showNumber, pageNumber int32) } func generateTagID(tagName, userID string) string { - return utils.Md5(tagName + userID + strconv.Itoa(rand.Int())) + return utils.Md5(tagName + userID + strconv.Itoa(rand.Int()) + time.Now().String()) } func getCurrentTimestampByMill() int64 {