From 4ea73a455e2fb9f28466006ca5e94404bba9c48d Mon Sep 17 00:00:00 2001 From: caiyiling <1321909229@qq.com> Date: Fri, 31 May 2024 10:35:19 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8F=97=E8=AF=95=E8=80=85=E6=97=A0=E5=BA=8F?= =?UTF-8?q?=E9=98=85=E7=89=87=E5=88=87=E6=8D=A2=E4=BB=BB=E5=8A=A1=E4=B8=8D?= =?UTF-8?q?=E5=88=87=E6=8D=A2=E8=A1=A8=E5=8D=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/store/modules/reading.js | 7 ++++++- .../trials-panel/reading/dicoms/components/DicomViewer.vue | 6 +++++- src/views/trials/trials-panel/reading/dicoms/index.vue | 1 + 3 files changed, 12 insertions(+), 2 deletions(-) diff --git a/src/store/modules/reading.js b/src/store/modules/reading.js index 5a13663e..e2c5a5e4 100644 --- a/src/store/modules/reading.js +++ b/src/store/modules/reading.js @@ -891,7 +891,12 @@ const actions = { }, setLastCanvasTaskId({ state }, taskId) { return new Promise(resolve => { - state.lastCanvasTaskId = taskId + var isReadingTaskViewInOrder = localStorage.getItem('isReadingTaskViewInOrder') + if (parseInt(isReadingTaskViewInOrder) === 2) { + if (!state.lastCanvasTaskId) state.lastCanvasTaskId = taskId + } else { + state.lastCanvasTaskId = taskId + } resolve() }) }, diff --git a/src/views/trials/trials-panel/reading/dicoms/components/DicomViewer.vue b/src/views/trials/trials-panel/reading/dicoms/components/DicomViewer.vue index 68450171..eb3bdb53 100644 --- a/src/views/trials/trials-panel/reading/dicoms/components/DicomViewer.vue +++ b/src/views/trials/trials-panel/reading/dicoms/components/DicomViewer.vue @@ -1045,7 +1045,11 @@ export default { if (this.petctWindow) { this.petctWindow.close() } - window.removeEventListener('beforeunload') + window.removeEventListener('beforeunload', () => { + if (this.petctWindow) { + this.petctWindow.close() + } + }) }, methods: { getWwcTpl() { diff --git a/src/views/trials/trials-panel/reading/dicoms/index.vue b/src/views/trials/trials-panel/reading/dicoms/index.vue index 32978b6d..4dd7ebd7 100644 --- a/src/views/trials/trials-panel/reading/dicoms/index.vue +++ b/src/views/trials/trials-panel/reading/dicoms/index.vue @@ -265,6 +265,7 @@ export default { this.readingTool = this.$router.currentRoute.query.readingTool this.TrialReadingCriterionId = this.$router.currentRoute.query.TrialReadingCriterionId this.isNewSubject = this.$router.currentRoute.query.isNewSubject + localStorage.setItem('isReadingTaskViewInOrder', this.isReadingTaskViewInOrder) if (this.isNewSubject && this.isReadingTaskViewInOrder !== 0) { // 已开始受试者${this.subjectCode}阅片任务 var msg = this.$t('trials:reading:warnning:msg1')