|
[插件使用]
meiQiaPlus模块 安卓闪退
[复制链接]
本帖最后由 子熹. 于 2024-5-7 15:04 编辑
辛苦看下 这个问题是缺少什么插件嘛,之前发的帖子没有回复,重发一下
使用的是meiQiaPlus模块最新版本1.1.3
安卓闪退,报错如图
//创建美洽
var meiQia = api.require('meiQiaPlus');
//初始化美洽
meiQia.initMeiQia(param, function (ret, err) {
// alert(JSON.stringify(ret))
// alert(JSON.stringify(err))
if (ret) {
//初始化成功
meiQia.setTitleColor({
color: "#333"
});
meiQia.setTitleBarColor({
color: "#F4F4F4"
});
meiQia.setLoginCustomizedId({
id: ret.ClientId
});
if (api.systemType == 'ios') {
meiQia.configChat({
backConfig: {
img: 'widget://image/new/new_arrow_grey.png',
w: 25, //数字类型;(可选项) back键的宽;
h: 25, //数字类型;(可选项) back键的高;
}
});
var infoParam = {
name: 111,
avatar: '',
tel: 13152790698,
email: '',
age: '',
tags: ["付费用户", "使用疑问"]
};
meiQia.setClientInfo(infoParam);
meiQia.show({
showAvatar: true, //是否显示用户头像
showTitle: true, //是否显示title
enableSendImage: true,
enableSendEmoji: true,
enableCamera: true,
enableSendVoice: true,
updateClientInfo: true,
});
} else {
meiQia.configChat({
backConfig: {
img: 'widget://image/new/new_arrow_grey.png',
w: 25, //数字类型;(可选项) back键的宽;
h: 25, //数字类型;(可选项) back键的高;
}
});
var infoParam = {
name: 111,
avatar: '',
tel: 13152790698,
email: '',
age: '',
tags: ["付费用户", "使用疑问"]
};
meiQia.setClientInfo(infoParam);
setTimeout(() => {
meiQia.show({
showAvatar: true, //是否显示用户头像
showTitle: true, //是否显示title
enableSendImage: true,
enableSendEmoji: true,
enableCamera: true,
enableSendVoice: true,
updateClientInfo: true,
});
}, 300);
}
meiQia.addChatViewListener(function (ret) {
if (ret) {
if (ret.event == 'back') {
meiQia.setClientOffline();
}
}
});
} else {
//初始化失败
}
})
|
|