From 06f52f4f242a828d2c3456e250fdd51445b095b7 Mon Sep 17 00:00:00 2001 From: wangxiaoshuang <825034831@qq.com> Date: Wed, 29 Apr 2026 13:42:16 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=86=E5=89=B2=E6=95=B0=E6=8D=AE=E4=B8=8D?= =?UTF-8?q?=E4=B8=80=E8=87=B4=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/reading.js | 8 ++++ .../reading/dicoms3D/components/ReadPage.vue | 40 +++++++++++++++-- .../dicoms3D/components/Segmentations.vue | 43 ++++++++++++++----- .../components/helpers/segmentations.js | 2 +- 4 files changed, 79 insertions(+), 14 deletions(-) diff --git a/src/api/reading.js b/src/api/reading.js index 53cdedae..e686f326 100644 --- a/src/api/reading.js +++ b/src/api/reading.js @@ -408,6 +408,14 @@ export function changeSegmentationSavedStatus(data) { data }) } +// 修改分割片段锁定状态 +export function lockOrUnLockSegment(data) { + return request({ + url: `/Segmentation/lockOrUnLockSegment`, + method: 'post', + data + }) +} // 图像数据匿名 export function studyMaskImage(data) { return request({ diff --git a/src/views/trials/trials-panel/reading/dicoms3D/components/ReadPage.vue b/src/views/trials/trials-panel/reading/dicoms3D/components/ReadPage.vue index 7c79d450..50dcca3a 100644 --- a/src/views/trials/trials-panel/reading/dicoms3D/components/ReadPage.vue +++ b/src/views/trials/trials-panel/reading/dicoms3D/components/ReadPage.vue @@ -1003,6 +1003,24 @@ export default { this.getSystemInfoReading(); }, methods: { + changeScreenSave() { + return new Promise(async (reslove, reject) => { + if (this.$refs.Segmentations.readingTaskState < 2) { + let isSaved = this.$refs.Segmentations.segmentList.some(item => !item.isSaved) + if (isSaved) { + let confirm = await this.$confirm(this.$t("trials:reading:Segmentations:confirm:changeScreenSave")) + if (!confirm) reslove(true) + this.$refs.Segmentations.saveSegmentGroup(null, true, () => { + reslove(true) + }) + } else { + reslove(true) + } + } else { + reslove(true) + } + }) + }, resetHistogram() { if (!this.histogramVisible) return false if (this.timer['histogram']) { @@ -3042,6 +3060,10 @@ export default { }, // 更改视图布局 async changeLayout(v) { + if (this.readingTool === 3) { + let res = await this.changeScreenSave() + if (!res) return false + } this.setToolsPassive() this.fullScreenIndex = null this.layout = v @@ -3355,9 +3377,12 @@ export default { }, time) }, // 切换全屏 - toggleFullScreen(e, index) { + async toggleFullScreen(e, index) { if (this.isDelay && (this.readingTool === 3 || this.isMPR)) return false - + if (this.readingTool === 3) { + let res = await this.changeScreenSave() + if (!res) return false + } this.fullScreenIndex = this.fullScreenIndex === index ? null : index this.activeViewportIndex = index if (this.readingTool === 3 || this.isMPR) { @@ -3515,8 +3540,12 @@ export default { this.setToolsPassive() }, // 激活视口 - activeViewport(index) { + async activeViewport(index) { if (this.activeViewportIndex === index) return + if (this.readingTool === 3) { + let res = await this.changeScreenSave() + if (!res) return false + } this.activeViewportIndex = index // 切换检查列表 const series = this.$refs[`${this.viewportKey}-${this.activeViewportIndex}`][0].series @@ -4173,6 +4202,11 @@ export default { if (!data) return resolve(false) let viewportSeries = this.$refs[`viewport-MPR-0`][0].series if (data && viewportSeries.SeriesInstanceUid === data.SeriesInstanceUid) return resolve(true) + } else { + if (this.readingTool === 3) { + let res = await this.changeScreenSave() + if (!res) return false + } } if (!data) { let { imageOrientationPatient, imagePositionPatient } = this.$refs[`viewport-${this.activeViewportIndex}`][0].imageInfo diff --git a/src/views/trials/trials-panel/reading/dicoms3D/components/Segmentations.vue b/src/views/trials/trials-panel/reading/dicoms3D/components/Segmentations.vue index abc852fc..03bd9f6e 100644 --- a/src/views/trials/trials-panel/reading/dicoms3D/components/Segmentations.vue +++ b/src/views/trials/trials-panel/reading/dicoms3D/components/Segmentations.vue @@ -133,8 +133,8 @@ -
- +
+ {{ $t("trials:reading:Segmentations:button:saveAll") }}