|
@@ -2409,16 +2409,7 @@ export default {
|
|
|
}
|
|
|
console.log(TAG_NAME, '_loginIM', params)
|
|
|
var that=this;
|
|
|
- setTimeout(function(){
|
|
|
- that.sendGroupCustomMessage({
|
|
|
- roomID: Number(that.config.roomID), // 房间 ID
|
|
|
- payload: {
|
|
|
- data: 'genxin',
|
|
|
- description: 'genxin',
|
|
|
- extension: 'genxin'
|
|
|
- }
|
|
|
- })
|
|
|
- },2000)
|
|
|
+
|
|
|
return this.tim.login({
|
|
|
userID: params.userID,
|
|
|
userSig: params.userSig,
|
|
@@ -2528,6 +2519,7 @@ export default {
|
|
|
if (!this.tim) {
|
|
|
return
|
|
|
}
|
|
|
+ var that=this;
|
|
|
console.log(TAG_NAME, '_joinGroup', params)
|
|
|
const promise = this.tim.joinGroup({ groupID: params.roomID + '', type: IM_GROUP_TYPE })
|
|
|
promise.then((imResponse) => {
|
|
@@ -2540,6 +2532,18 @@ export default {
|
|
|
// wx.showToast({
|
|
|
// title: '进群成功',
|
|
|
// })
|
|
|
+ var data={"test":"test"}
|
|
|
+ that._emitter.emit(EVENT.IM_READY, data)
|
|
|
+ setTimeout(function(){
|
|
|
+ that.sendGroupCustomMessage({
|
|
|
+ roomID: Number(that.config.roomID), // 房间 ID
|
|
|
+ payload: {
|
|
|
+ data: 'genxin',
|
|
|
+ description: 'genxin',
|
|
|
+ extension: 'genxin'
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },2000)
|
|
|
console.log(TAG_NAME, '_joinGroup success', imResponse)
|
|
|
break
|
|
|
default:
|