|
@@ -62,15 +62,14 @@ func (l *AppLetterPushLogic) AppLetterPush(in *message.WxTmplMsgRequest) (*messa
|
|
|
userData = *rData
|
|
|
}
|
|
|
}
|
|
|
-
|
|
|
- AppPushMsg(userData, pushConfig.Switch, in.Url, in.Title, in.Detail)
|
|
|
+ AppPushMsg(userData, pushConfig.Switch, in.Url, in.Title)
|
|
|
}
|
|
|
return &message.SendMsgResponse{
|
|
|
Total: 1,
|
|
|
}, nil
|
|
|
}
|
|
|
|
|
|
-func AppPushMsg(userInfo map[string]interface{}, stm, appPushUrl, title string, detail string) {
|
|
|
+func AppPushMsg(userInfo map[string]interface{}, stm, appPushUrl, title string) {
|
|
|
userId := mongodb.BsonIdToSId(userInfo["_id"])
|
|
|
if pushSetMap := qutil.ObjToMap(userInfo["o_pushset"]); pushSetMap != nil && len(*pushSetMap) > 0 {
|
|
|
if pushKeyMap := qutil.ObjToMap((*pushSetMap)[stm]); pushKeyMap != nil && len(*pushKeyMap) > 0 {
|
|
@@ -86,13 +85,12 @@ func AppPushMsg(userInfo map[string]interface{}, stm, appPushUrl, title string,
|
|
|
dt := map[string]interface{}{
|
|
|
"receiveUserId": userId,
|
|
|
"receiveName": name,
|
|
|
- //"sendName": loginUserName,
|
|
|
- "title": title,
|
|
|
- "content": detail,
|
|
|
- "msgType": "messagecenter",
|
|
|
- "link": appPushUrl,
|
|
|
- "appid": "10000",
|
|
|
- "menuName": "message",
|
|
|
+ "title": "剑鱼标讯",
|
|
|
+ "content": fmt.Sprintf("您收到一条来自%s私信", title),
|
|
|
+ "msgType": "messagecenter",
|
|
|
+ "link": appPushUrl,
|
|
|
+ "appid": "10000",
|
|
|
+ "menuName": "message",
|
|
|
}
|
|
|
//推送消息
|
|
|
if appVersion > "3.0.3" {
|
|
@@ -102,7 +100,6 @@ func AppPushMsg(userInfo map[string]interface{}, stm, appPushUrl, title string,
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
- //log.Println("用户未打开app推送", msgType, userId)
|
|
|
}
|
|
|
|
|
|
func AppGrpcPush(pushData map[string]interface{}, otherPushId, jgPushId, phoneType, appPushUrl string) {
|