DengBiao 1 anno fa
parent
commit
96fd32971a
2 ha cambiato i file con 8 aggiunte e 7 eliminazioni
  1. +2
    -2
      internal/logic/domain/message/service/app_push.go
  2. +6
    -5
      internal/logic/domain/message/service/message_service.go

+ 2
- 2
internal/logic/domain/message/service/app_push.go Vedi File

@@ -16,8 +16,8 @@ func getChangeContent(args md3.PushParams, Content string) string {
Content = strings.Replace(Content, "[MasterId]", args.MasterId, -1)
Content = strings.Replace(Content, "[消息发送者-会员昵称]", args.SendUserNickname, -1)
Content = strings.Replace(Content, "[消息发送者-会员头像]", args.SendUserAvatarUrl, -1)
Content = strings.Replace(Content, "[消息类型]", args.MessageType, -1)
Content = strings.Replace(Content, "[备注]", args.Memo, -1)
//Content = strings.Replace(Content, "[消息类型]", args.MessageType, -1)
//Content = strings.Replace(Content, "[备注]", args.Memo, -1)
Content = strings.Replace(Content, "[时间]", args.Times, -1)
return Content
}


+ 6
- 5
internal/logic/domain/message/service/message_service.go Vedi File

@@ -174,11 +174,12 @@ func (*messageService) SendToUser(ctx context.Context, sender *pb.Sender, toUser
}
//TODO::接收者类型为`user`, 进行极光推送
CommAddPush(md.PushParams{
MasterId: masterId,
Uid: uid,
PushAlia: alia,
Title: "新消息提醒",
Content: "您收到一条新消息,来自会员\"[消息发送者-会员昵称]\",发送时间\"[时间]\",消息类型\"[消息类型]\",备注\"[备注]\"",
MasterId: masterId,
Uid: uid,
PushAlia: alia,
Title: "新消息提醒",
Content: "您收到一条新消息,来自会员\"[消息发送者-会员昵称]\",发送时间\"[时间]\"",
//Content: "您收到一条新消息,来自会员\"[消息发送者-会员昵称]\",发送时间\"[时间]\",消息类型\"[消息类型]\",备注\"[备注]\"",
PushType: "zhi_ying_gim",
MessageType: req.MessageType.String(),
SendUserNickname: sender.Nickname,


Caricamento…
Annulla
Salva