REQ-3284: 荣耀设置消息类型

This commit is contained in:
yanglin 2024-12-03 16:39:45 +08:00
parent bda9cfa1bd
commit f355dcced4

View File

@ -1,6 +1,7 @@
package cn.axzo.msg.center.nimpush.payload;
import cn.axzo.msg.center.nimpush.PushContent;
import cn.axzo.msg.center.nimpush.PushMessageTye;
import cn.axzo.msg.center.nimpush.payload.intent.UriIntent;
import com.alibaba.fastjson.JSONObject;
import org.springframework.stereotype.Component;
@ -30,6 +31,8 @@ class RYPushPayloadBuilder extends AndroidPushPayloadBuilder<UriIntent> {
notification.put("title", content.getTitle());
notification.put("body", content.getContent());
notification.put("clickAction", clickAction);
notification.put("importance",
content.getMessageTye() == PushMessageTye.OP ? "LOW" : "NORMAL");
JSONObject honorField = new JSONObject();
honorField.put("notification", notification);