diff --git a/im-ui/src/App.vue b/im-ui/src/App.vue index cf15607..11f715d 100644 --- a/im-ui/src/App.vue +++ b/im-ui/src/App.vue @@ -26,4 +26,8 @@ export default { height: 100%; width: 100%; } + +.el-message { + z-index: 99999999 !important; +} diff --git a/im-ui/src/components/chat/ChatPrivateVideo.vue b/im-ui/src/components/chat/ChatPrivateVideo.vue index 524814c..19dc951 100644 --- a/im-ui/src/components/chat/ChatPrivateVideo.vue +++ b/im-ui/src/components/chat/ChatPrivateVideo.vue @@ -67,7 +67,7 @@ methods: { init() { if (!this.hasUserMedia() || !this.hasRTCPeerConnection()) { - this.$message.error("您的浏览器不支持WebRTC"); + this.$message.error("初始化失败,原因可能是: 1.未部署ssl证书 2.您的浏览器不支持WebRTC"); if (!this.master) { this.sendFailed("对方浏览器不支持WebRTC") } diff --git a/im-ui/src/components/common/RightMenu.vue b/im-ui/src/components/common/RightMenu.vue index e7107f8..c2f4062 100644 --- a/im-ui/src/components/common/RightMenu.vue +++ b/im-ui/src/components/common/RightMenu.vue @@ -3,7 +3,7 @@
+ @click.native.stop="onSelectMenu(item)"> {{item.name}} @@ -33,6 +33,7 @@ }, onSelectMenu(item) { this.$emit("select", item); + this.close(); } } } diff --git a/im-ui/src/components/group/AddGroupMember.vue b/im-ui/src/components/group/AddGroupMember.vue index bcf21ee..5518181 100644 --- a/im-ui/src/components/group/AddGroupMember.vue +++ b/im-ui/src/components/group/AddGroupMember.vue @@ -1,27 +1,29 @@ @@ -57,21 +57,6 @@ chatStore() { return this.$store.state.chatStore; }, - activeChat() { - let index = this.chatStore.activeIndex; - let chats = this.chatStore.chats - if (index >= 0 && chats.length > 0) { - return chats[index]; - } - // 当没有激活任何会话时,创建一个空会话,不然控制台会有很多报错 - let emptyChat = { - targetId: -1, - showName: "", - headImage: "", - messages: [] - } - return emptyChat; - }, loading(){ return this.chatStore.loadingGroupMsg || this.chatStore.loadingPrivateMsg } diff --git a/im-ui/src/view/Friend.vue b/im-ui/src/view/Friend.vue index b7efdaf..3f32c50 100644 --- a/im-ui/src/view/Friend.vue +++ b/im-ui/src/view/Friend.vue @@ -15,7 +15,7 @@
@@ -46,7 +46,7 @@
发送消息 加为好友 - 删除好友 + 删除好友
@@ -74,6 +74,7 @@ return { searchText: "", showAddFriend: false, + activeIdx: -1, userInfo: {} } }, @@ -84,11 +85,12 @@ onCloseAddFriend() { this.showAddFriend = false; }, - onActiveItem(friend, index) { - this.$store.commit("activeFriend", index); - this.loadUserInfo(friend, index); + onActiveItem(friend, idx) { + this.$store.commit("activeFriend", idx); + this.activeIdx = idx + this.loadUserInfo(friend, idx); }, - onDelItem(friend, index) { + onDelItem(friend, idx) { this.$confirm(`确认要解除与 '${friend.nickName}'的好友关系吗?`, '确认解除?', { confirmButtonText: '确定', cancelButtonText: '取消', @@ -99,7 +101,7 @@ method: 'delete' }).then((data) => { this.$message.success("删除好友成功"); - this.$store.commit("removeFriend", index); + this.$store.commit("removeFriend", idx); this.$store.commit("removePrivateChat", friend.id); }) }) @@ -173,14 +175,7 @@ isFriend(){ return this.friendStore.friends.find((f)=>f.id==this.userInfo.id); } - }, - mounted() { - if (this.friendStore.activeIndex >= 0) { - let friend = this.friendStore.friends[this.friendStore.activeIndex]; - this.loadUserInfo(friend, this.friendStore.activeIndex); - } } - } diff --git a/im-ui/src/view/Group.vue b/im-ui/src/view/Group.vue index c86513e..f843df8 100644 --- a/im-ui/src/view/Group.vue +++ b/im-ui/src/view/Group.vue @@ -13,7 +13,7 @@
+ :active="group === groupStore.activeGroup" @click.native="onActiveItem(group,index)">
@@ -269,15 +269,6 @@ imageAction() { return `/image/upload`; } - }, - mounted() { - if (this.groupStore.activeIndex >= 0) { - let activeGroup = this.groupStore.groups[this.groupStore.activeIndex]; - // store数据不能直接修改,所以深拷贝一份内存 - this.activeGroup = JSON.parse(JSON.stringify(activeGroup)); - // 加载群成员 - this.loadGroupMembers(); - } } } diff --git a/im-ui/src/view/Register.vue b/im-ui/src/view/Register.vue index 9b10f74..1c2c6e8 100644 --- a/im-ui/src/view/Register.vue +++ b/im-ui/src/view/Register.vue @@ -56,7 +56,6 @@ }; var checkConfirmPassword = (rule, value, callback) => { - console.log("checkConfirmPassword"); if (value === '') { return callback(new Error('请输入密码')); }