diff --git a/src/components/chat/GroupChatPanel.vue b/src/components/chat/GroupChatPanel.vue index 975df4b..f599372 100644 --- a/src/components/chat/GroupChatPanel.vue +++ b/src/components/chat/GroupChatPanel.vue @@ -648,6 +648,16 @@ async function saveAnnouncement() { watch(() => props.roomId, loadData, { immediate: true }) +// 监听群通知,自动刷新成员列表 +watch(() => chatStore.lastGroupNotification, (notif) => { + if (notif && notif.room_id === props.roomId) { + // 延迟刷新,确保后端数据已更新 + setTimeout(() => { + loadData() + }, 300) + } +}, { deep: true }) + onMounted(() => { if (chatStore.contacts.length === 0) { contactApi.getContacts().then(res => chatStore.setContacts(res)) diff --git a/src/components/chat/MessageInput.vue b/src/components/chat/MessageInput.vue index 5657881..2407616 100644 --- a/src/components/chat/MessageInput.vue +++ b/src/components/chat/MessageInput.vue @@ -15,32 +15,49 @@
无法在此群聊中发送消息
+ + +您已被禁言
+{{ muteCountdown }}
+无法在此群聊中发送消息
+