From 890910a763f7ad9fd438fe8cb9cbb3683bf73d81 Mon Sep 17 00:00:00 2001 From: wangxiaoshuang <825034831@qq.com> Date: Fri, 17 Apr 2026 11:17:25 +0800 Subject: [PATCH 1/4] =?UTF-8?q?=E5=88=86=E5=89=B2=E9=83=A8=E5=88=86?= =?UTF-8?q?=E9=97=AE=E9=A2=98=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../reading/dicoms3D/components/ReadPage.vue | 1 + .../dicoms3D/components/Segmentations.vue | 17 ++++++++++------- .../dicoms3D/components/VolumeViewport.vue | 8 +++++--- 3 files changed, 16 insertions(+), 10 deletions(-) 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 546d70e8..dd4f680d 100644 --- a/src/views/trials/trials-panel/reading/dicoms3D/components/ReadPage.vue +++ b/src/views/trials/trials-panel/reading/dicoms3D/components/ReadPage.vue @@ -2864,6 +2864,7 @@ export default { this.rows = 1 this.cols = 1 this.activeViewportIndex = 0 + series.curIndex = index if (typeof series === 'object') { seriesArr.push(series) } 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 994adb93..b1da534b 100644 --- a/src/views/trials/trials-panel/reading/dicoms3D/components/Segmentations.vue +++ b/src/views/trials/trials-panel/reading/dicoms3D/components/Segmentations.vue @@ -123,13 +123,14 @@ {{ $t('trials:reading:Segmentations:title:InactiveSegmentationsShow') - }} + }}
{{ index + 1 }}
@@ -392,7 +393,8 @@ export default { digitPlaces: 2, isloaded: false, popoverId: null, - saveLoading: false + saveLoading: false, + popoverVisible: false } }, mounted() { @@ -731,6 +733,7 @@ export default { }, async addSegmentGroup() { // let segmentationId = this.$guid(); + this.popoverVisible = false let obj = { name: this.getSegmentationName(), view: true, @@ -826,15 +829,15 @@ export default { segmentIndex: segmentIndex, segmentationId: this.segmentationId, SegmentLabel: this.getSegmentName(item.segments), - color: item.segments.length >= this.colors.length ? this.colors[0] : this.colors[item.segments.length], + color: segmentIndex >= this.colors.length ? this.colors[0] : this.colors[segmentIndex], stats: null, bidirectional: null, bidirectionalView: true, view: true, lock: false } - if (item.segments.length >= this.colors.length) { - let index = item.segments.length % this.colors.length + if (segmentIndex >= this.colors.length) { + let index = segmentIndex % this.colors.length let color = this.randomNearColor(this.colors[index], 4) obj.color = color } diff --git a/src/views/trials/trials-panel/reading/dicoms3D/components/VolumeViewport.vue b/src/views/trials/trials-panel/reading/dicoms3D/components/VolumeViewport.vue index 436b6b4b..d732e1a1 100644 --- a/src/views/trials/trials-panel/reading/dicoms3D/components/VolumeViewport.vue +++ b/src/views/trials/trials-panel/reading/dicoms3D/components/VolumeViewport.vue @@ -59,10 +59,10 @@
Location: {{ `${Number(imageInfo.location).toFixed(digitPlaces)} mm` - }}
+ }}
Slice Thickness: {{ `${Number(imageInfo.sliceThickness).toFixed(digitPlaces)} mm` - }}
+ }}
WW/WL: {{ imageInfo.wwwc }}
@@ -384,7 +384,7 @@ export default { }, stackNewImage(e) { const { detail } = e - + delete this.series.segment this.series.SliceIndex = detail.imageIndex this.sliderInfo.height = detail.imageIndex * 100 / detail.numberOfSlices const renderingEngine = getRenderingEngine(this.renderingEngineId) @@ -687,6 +687,8 @@ export default { } await renderSegmentation(this.series, this.series.TaskInfo, this.viewportId, this.SegmentConfig, this.renderingEngineId, data.segment, this.actionConfiguration) DicomEvent.$emit('SegmentationLoading', this.viewportId) + console.log(data.segment, 'data.segment') + if (data.segment) return false if (this.series.hasOwnProperty('curIndex')) return this.setFullScreen(this.series.curIndex) this.setFullScreen(Math.ceil((res.volume._imageIds.length - 1) / 2) - 1) } catch (e) { From 398ec90fae884cbc0021d0e829c8426af8004a9a Mon Sep 17 00:00:00 2001 From: wangxiaoshuang <825034831@qq.com> Date: Fri, 17 Apr 2026 11:28:34 +0800 Subject: [PATCH 2/4] =?UTF-8?q?=E5=88=86=E5=89=B2=E9=97=AE=E9=A2=98?= =?UTF-8?q?=E6=9F=A5=E7=9C=8B=E3=80=81=E6=9B=B4=E6=94=B9=E6=8C=89=E9=92=AE?= =?UTF-8?q?=E4=BD=8D=E7=BD=AE=E5=8F=98=E6=9B=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dicoms3D/components/customize/QuestionFormItem.vue | 10 +++++----- .../components/customize/QuestionTableFormItem.vue | 10 +++++----- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/views/trials/trials-panel/reading/dicoms3D/components/customize/QuestionFormItem.vue b/src/views/trials/trials-panel/reading/dicoms3D/components/customize/QuestionFormItem.vue index 30039696..d5dd4d56 100644 --- a/src/views/trials/trials-panel/reading/dicoms3D/components/customize/QuestionFormItem.vue +++ b/src/views/trials/trials-panel/reading/dicoms3D/components/customize/QuestionFormItem.vue @@ -210,16 +210,16 @@ @click="operateImageMarker({ operateStateEnum: 21, question })"> {{ $t('dicom3D:CustomizeQuestionFormItem:button:bind') }} - - - {{ $t('dicom3D:CustomizeQuestionFormItem:button:edit') }} - {{ $t('dicom3D:CustomizeQuestionFormItem:button:view') }} + + + {{ $t('dicom3D:CustomizeQuestionFormItem:button:edit') }} + diff --git a/src/views/trials/trials-panel/reading/dicoms3D/components/customize/QuestionTableFormItem.vue b/src/views/trials/trials-panel/reading/dicoms3D/components/customize/QuestionTableFormItem.vue index 4ac87da8..10a48e54 100644 --- a/src/views/trials/trials-panel/reading/dicoms3D/components/customize/QuestionTableFormItem.vue +++ b/src/views/trials/trials-panel/reading/dicoms3D/components/customize/QuestionTableFormItem.vue @@ -135,17 +135,17 @@ size="mini" type="text" @click="operateImageMarker({ operateStateEnum: 21, question })"> {{ $t('dicom3D:CustomizeQuestionFormItem:button:bind') }} + + + {{ $t('dicom3D:CustomizeQuestionFormItem:button:view') }} + {{ $t('dicom3D:CustomizeQuestionFormItem:button:edit') }} - - - {{ $t('dicom3D:CustomizeQuestionFormItem:button:view') }} - Date: Fri, 17 Apr 2026 11:33:35 +0800 Subject: [PATCH 3/4] =?UTF-8?q?=E5=88=86=E6=AE=B5=E6=98=BE=E9=9A=90?= =?UTF-8?q?=E6=97=B6=E5=AF=B9=E5=BA=94=E9=95=BF=E7=9F=AD=E5=BE=84=E6=A0=87?= =?UTF-8?q?=E8=AE=B0=E5=90=8C=E6=AD=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../reading/dicoms3D/components/Segmentations.vue | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) 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 b1da534b..77345c99 100644 --- a/src/views/trials/trials-panel/reading/dicoms3D/components/Segmentations.vue +++ b/src/views/trials/trials-panel/reading/dicoms3D/components/Segmentations.vue @@ -123,7 +123,7 @@ {{ $t('trials:reading:Segmentations:title:InactiveSegmentationsShow') - }} + }}
{{ index + 1 }}
@@ -676,6 +676,7 @@ export default { // this.viewBidirectional(item.segments, view) }, viewSegment(item, view) { + item.bidirectionalView = view item.view = view this.$emit('setToolsPassive') DicomEvent.$emit('viewSegment', item) From 74c5d032fb469bc6e3e5a05cfe0306c6d8961796 Mon Sep 17 00:00:00 2001 From: wangxiaoshuang <825034831@qq.com> Date: Fri, 17 Apr 2026 11:49:00 +0800 Subject: [PATCH 4/4] =?UTF-8?q?=E5=88=86=E5=89=B2=E6=B8=85=E9=99=A4?= =?UTF-8?q?=E5=86=85=E5=AD=98=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../reading/dicoms3D/components/Segmentations.vue | 12 +++++++++--- .../dicoms3D/components/helpers/segmentations.js | 1 + 2 files changed, 10 insertions(+), 3 deletions(-) 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 77345c99..65f9f40b 100644 --- a/src/views/trials/trials-panel/reading/dicoms3D/components/Segmentations.vue +++ b/src/views/trials/trials-panel/reading/dicoms3D/components/Segmentations.vue @@ -123,7 +123,7 @@ {{ $t('trials:reading:Segmentations:title:InactiveSegmentationsShow') - }} + }}
{{ index + 1 }}
@@ -402,6 +402,7 @@ export default { this.statsKey = getCustomizeStandardsSegmentDicomTools('Labelmap')[0].props.filter(item => item !== 'width' && item !== 'length') // console.log(segmentation, 'segmentation') // console.log(annotation, 'annotation') + console.log(cache, 'cache') eventTarget.addEventListener( 'CORNERSTONE_TOOLS_SEGMENTATION_DATA_MODIFIED', this.segmentationModifiedCallback @@ -885,6 +886,11 @@ export default { if (!res) return false segmentation.removeSegmentation(this.segmentationId) segmentation.state.removeSegmentation(this.segmentationId) + let volume = cache.getVolume(this.segmentationId) + // 1. 销毁 Volume 实例 + volume.destroy(); + // 2. 从缓存中移除 + volume.removeFromCache(); let groupIndex = this.segmentList.findIndex(item => item.segmentationId === this.segmentationId) this.segmentList.splice(groupIndex, 1) let annotations = annotation.state.getAllAnnotations().filter(item => item.metadata.segmentationId === this.segmentationId); @@ -895,7 +901,7 @@ export default { this.segmentationId = this.segmentList[0].segmentationId; this.selectSegmentGroup() } else { - this.segmentationId = '' + this.segmentationId = null } // this.readingSegmentByConfig() this.resetViewport() diff --git a/src/views/trials/trials-panel/reading/dicoms3D/components/helpers/segmentations.js b/src/views/trials/trials-panel/reading/dicoms3D/components/helpers/segmentations.js index 9bea809e..594a53c8 100644 --- a/src/views/trials/trials-panel/reading/dicoms3D/components/helpers/segmentations.js +++ b/src/views/trials/trials-panel/reading/dicoms3D/components/helpers/segmentations.js @@ -229,6 +229,7 @@ function selectSegmentation(viewportId, segmentationId) { segmentation.activeSegmentation.setActiveSegmentation(viewportId, segmentationId) } function selectSegment(viewportId, segmentationId, segmentIndex) { + if (!segmentIndex) return false selectSegmentation(viewportId, segmentationId) segmentation.segmentIndex.setActiveSegmentIndex(segmentationId, segmentIndex); }