🐞 fix(消息): 消息推送去除子游戏id

This commit is contained in:
luying
2023-03-22 16:52:37 +08:00
parent e31bd2bb30
commit 3cfa5b42a1
3 changed files with 7 additions and 7 deletions
@@ -220,10 +220,10 @@ export class ChatHandler {
async debugPushMessage(msg: { uid: number }, session: BackendSession) { async debugPushMessage(msg: { uid: number }, session: BackendSession) {
let dic = gameData.dicPushMessage.get(SDK_PUSH_MSG_TYPE.GUILD_ACTIVITY_START); let dic = gameData.dicPushMessage.get(SDK_PUSH_MSG_TYPE.GUILD_ACTIVITY_START);
if(!dic) return resResult(STATUS.WRONG_PARMS); if(!dic) return resResult(STATUS.WRONG_PARMS);
// let result = await pushMsg37(Date.now(), dic, SDK_PUSH_TARGET_TYPE.SINGLE, `${msg.uid}`); let result = await pushMsg37(Date.now(), dic, SDK_PUSH_TARGET_TYPE.SINGLE, `${msg.uid}`);
await pushClientMsg(SDK_PUSH_MSG_TYPE.AFK_ATTENTION); // await pushClientMsg(SDK_PUSH_MSG_TYPE.AFK_ATTENTION);
return resResult(STATUS.SUCCESS); return resResult(STATUS.SUCCESS, result);
} }
} }
+2 -2
View File
@@ -384,7 +384,7 @@ export class IOSRefundParam {
export class PushMsg37Param { export class PushMsg37Param {
notify_id: string; // 消息唯一标号,毫秒时间戳 notify_id: string; // 消息唯一标号,毫秒时间戳
game_id: number; // 游戏id game_id: number; // 游戏id
c_game_id: number; // 子游戏id // c_game_id: number; // 子游戏id
title: string; // 消息标题 title: string; // 消息标题
text: string; // 消息正文 text: string; // 消息正文
target: SDK_PUSH_TARGET_TYPE; // 推送目标类型 target: SDK_PUSH_TARGET_TYPE; // 推送目标类型
@@ -400,7 +400,7 @@ export class PushMsg37Param {
constructor(time: number) { constructor(time: number) {
this.notify_id = time.toString(); this.notify_id = time.toString();
this.game_id = SDK_37_CONST.PUSH_GAME_ID; this.game_id = SDK_37_CONST.PUSH_GAME_ID;
this.c_game_id = SDK_37_CONST.FX_C_GAME_ID; // this.c_game_id = SDK_37_CONST.FX_C_GAME_ID;
this.time = Math.floor(time/1000).toString(); this.time = Math.floor(time/1000).toString();
this.source = 0; // 0: 游戏内 this.source = 0; // 0: 游戏内
} }
+2 -2
View File
@@ -58,8 +58,8 @@ export function get37CheckChatMd5Sign(body: Chat37Params, key: string) {
} }
export function get37PushMsgMd5Sign(body: PushMsg37Param, key: string) { export function get37PushMsgMd5Sign(body: PushMsg37Param, key: string) {
let { notify_id = '', game_id = '', c_game_id = '', title = '', text = '', target = '', click_type = '', time = '' } = body; let { notify_id = '', game_id = '', title = '', text = '', target = '', click_type = '', time = '' } = body;
let str = encodeUtf8(`${notify_id}${game_id}${c_game_id}${title}${text}${target}${click_type}${key}${time}`); let str = encodeUtf8(`${notify_id}${game_id}${title}${text}${target}${click_type}${key}${time}`);
let sign = md5(str); let sign = md5(str);
console.log('** origin str', body, str, sign); console.log('** origin str', body, str, sign);
return sign; return sign;