塔罗牌公屏消息
This commit is contained in:
@@ -292,7 +292,7 @@ public class XChatConstants {
|
||||
/**
|
||||
* Referer (DEBUG)
|
||||
*/
|
||||
public static final String KEY_REFERER_DEBUG = "http://120.79.211.243/";
|
||||
public static final String KEY_REFERER_DEBUG = "http://api.uat.zhongjialx.com/";
|
||||
|
||||
/**
|
||||
* Referer (RELEASE)
|
||||
|
@@ -726,7 +726,8 @@ public final class IMNetEaseManager {
|
||||
|| customAttachment.getFirst() == CustomAttachment.CUSTOM_MSG_HEADER_TYPE_FOLLOW_ROOM
|
||||
|| customAttachment.getFirst() == CustomAttachment.CUSTOM_MSG_HEADER_TYPE_SEND_MAGIC
|
||||
|| customAttachment.getFirst() == CustomAttachment.CUSTOM_MSG_HEADER_TYPE_MULTI_GIFT
|
||||
|| customAttachment.getFirst() == CUSTOM_MSG_HEADER_TYPE_KICK_MIC
|
||||
|| customAttachment.getFirst() == CustomAttachment.CUSTOM_MSG_HEADER_TYPE_KICK_MIC
|
||||
|| customAttachment.getFirst() == CustomAttachment.CUSTOM_MESS_TAROT
|
||||
|| customAttachment.getFirst() == CustomAttachment.CUSTOM_MSG_HEADER_TYPE_MONSTER_HUNTING
|
||||
|| customAttachment.getFirst() == CustomAttachment.CUSTOM_MSG_MINI_WORLD) {
|
||||
addMessages(msg);
|
||||
|
@@ -534,6 +534,10 @@ public class CustomAttachParser implements MsgAttachmentParser {
|
||||
}
|
||||
break;
|
||||
|
||||
case CustomAttachment.CUSTOM_MESS_TAROT:
|
||||
attachment = new TarotAttachment(CustomAttachment.CUSTOM_MESS_TAROT, CustomAttachment.CUSTOM_MESS_TAROT_SUCCESS);
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
@@ -366,8 +366,9 @@ public class CustomAttachment implements MsgAttachment {
|
||||
//推送消息
|
||||
public static final int CUSTOM_MSG_PUSH_NOTIFIFICATION = 70;
|
||||
public static final int CUSTOM_MSG_SUB_PUSH_NOTIFICATION_IN_ROOM = 701;// 推送进入房间
|
||||
// public static final int CUSTOM_MSG_SUB_PUSH_NOTIFICATION_IN_CHAT_ROOM = 702;// 推送进入聊天页
|
||||
// public static final int CUSTOM_MSG_SUB_PUSH_NOTIFICATION_IN_DYNAMIC_MSG = 703;// 推送进入动态消息
|
||||
|
||||
public static final int CUSTOM_MESS_TAROT = 71; //塔罗牌充值消息
|
||||
public static final int CUSTOM_MESS_TAROT_SUCCESS = 711; //塔罗牌充值中奖消息
|
||||
|
||||
public CustomAttachment() {
|
||||
|
||||
|
@@ -0,0 +1,37 @@
|
||||
package com.yizhuan.xchat_android_core.im.custom.bean;
|
||||
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.google.gson.Gson;
|
||||
|
||||
public class TarotAttachment extends CustomAttachment {
|
||||
private TarotMsgBean tarotMsgBean;
|
||||
|
||||
public TarotAttachment(int first, int second) {
|
||||
super(first, second);
|
||||
}
|
||||
|
||||
public TarotMsgBean getTarotMsgBean() {
|
||||
return tarotMsgBean;
|
||||
}
|
||||
|
||||
public void setTarotMsgBean(TarotMsgBean tarotMsgBean) {
|
||||
this.tarotMsgBean = tarotMsgBean;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void parseData(JSONObject data) {
|
||||
tarotMsgBean = new Gson().fromJson(data.toJSONString(), TarotMsgBean.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected JSONObject packData() {
|
||||
JSONObject jsonObject = new JSONObject();
|
||||
jsonObject.put("chargeProdId", tarotMsgBean.getChargeProdId());
|
||||
jsonObject.put("chargeProdName", tarotMsgBean.getChargeProdName());
|
||||
jsonObject.put("drawGoldNum", tarotMsgBean.getDrawGoldNum());
|
||||
jsonObject.put("nick", tarotMsgBean.getNick());
|
||||
jsonObject.put("roomUid", tarotMsgBean.getRoomUid());
|
||||
jsonObject.put("uid", tarotMsgBean.getUid());
|
||||
return jsonObject;
|
||||
}
|
||||
}
|
@@ -0,0 +1,31 @@
|
||||
package com.yizhuan.xchat_android_core.im.custom.bean;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
@Data
|
||||
public class TarotMsgBean {
|
||||
/**
|
||||
* 中奖用户uid
|
||||
**/
|
||||
private long uid;
|
||||
/**
|
||||
* 中奖用户昵称
|
||||
**/
|
||||
private String nick;
|
||||
/**
|
||||
* 中奖的房间uid
|
||||
**/
|
||||
private long roomUid;
|
||||
/**
|
||||
* 中奖的产品ID
|
||||
**/
|
||||
private String chargeProdId;
|
||||
/**
|
||||
* 中奖的产品名称
|
||||
**/
|
||||
private String chargeProdName;
|
||||
/**
|
||||
* 中奖的金币数量
|
||||
**/
|
||||
private long drawGoldNum;
|
||||
}
|
Reference in New Issue
Block a user