From 09f5cca94870530f53090415098caf4dc81f17aa Mon Sep 17 00:00:00 2001 From: kuaifan Date: Tue, 3 Jun 2025 15:17:43 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=E5=B7=B2=E7=BB=8F?= =?UTF-8?q?=E5=9C=A8=E6=B6=88=E6=81=AF=E4=B8=AD=E6=89=93=E5=BC=80=E9=A1=B9?= =?UTF-8?q?=E7=9B=AE=E5=AF=B9=E8=AF=9D=E6=97=B6=E6=97=A0=E6=B3=95=E5=9C=A8?= =?UTF-8?q?=E5=85=B6=E4=BB=96=E5=9C=B0=E6=96=B9=E6=89=93=E5=BC=80=E9=A1=B9?= =?UTF-8?q?=E7=9B=AE=E6=B2=9F=E9=80=9A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../assets/js/pages/manage/components/DialogModal.vue | 1 + resources/assets/js/store/actions.js | 8 ++++++-- resources/assets/js/store/state.js | 1 + 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/resources/assets/js/pages/manage/components/DialogModal.vue b/resources/assets/js/pages/manage/components/DialogModal.vue index 0c1591060..81da0ce84 100644 --- a/resources/assets/js/pages/manage/components/DialogModal.vue +++ b/resources/assets/js/pages/manage/components/DialogModal.vue @@ -93,6 +93,7 @@ export default { }, show(v) { + this.$store.state.dialogModalShow = v; $A.eeuiAppSetScrollDisabled(v && this.windowPortrait) } }, diff --git a/resources/assets/js/store/actions.js b/resources/assets/js/store/actions.js index 4a4d47b65..8153a0a2a 100644 --- a/resources/assets/js/store/actions.js +++ b/resources/assets/js/store/actions.js @@ -3156,8 +3156,12 @@ export default { return } // - if (state.dialogId) { - emitter.emit('handleMoveTop', 'dialogModal'); // 已打开对话时将对话窗口置顶 + if (state.dialogModalShow) { + // 已打开对话时将对话窗口置顶 + emitter.emit('handleMoveTop', 'dialogModal'); + } else if (state.dialogId === dialogId) { + // 如果对话窗口未打开,则清除当前对话ID(避免类此:已经在消息中打开项目对话时无法在其他地方打开项目对话) + state.dialogId = 0; } // requestAnimationFrame(_ => { diff --git a/resources/assets/js/store/state.js b/resources/assets/js/store/state.js index 5986ae413..54a0de7d6 100644 --- a/resources/assets/js/store/state.js +++ b/resources/assets/js/store/state.js @@ -143,6 +143,7 @@ export default { dialogSseList: [], dialogDroupWordChain: {}, dialogGroupVote: {}, + dialogModalShow: false, // 搜索关键词(主要用于移动端判断滑动返回) messengerSearchKey: {dialog: '', contacts: ''},