没有分割数据的Segmentation,从二维进入MPR时,会显示3个
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
parent
0dbd74270d
commit
b3ae801fe9
|
|
@ -7,7 +7,7 @@ import {
|
|||
extractSliceThicknessFromDataset,
|
||||
} from "@/utils/extractPositioningFromDataset";
|
||||
import getNumberValues from "@/utils/getNumberValues";
|
||||
|
||||
import isNMReconstructable from "@/utils/isNMReconstructable";
|
||||
function getSpacingBetweenSlices(dataSet) {
|
||||
if (dataSet?.elements?.x00180088) {
|
||||
return dataSet.floatString("x00180088");
|
||||
|
|
|
|||
|
|
@ -351,7 +351,8 @@ export default {
|
|||
statsKey: [],
|
||||
drawing: false, // 是否正在分割
|
||||
isDel: false,
|
||||
digitPlaces: 2
|
||||
digitPlaces: 2,
|
||||
isloaded: false
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
|
|
@ -367,6 +368,8 @@ export default {
|
|||
this.series = series
|
||||
})
|
||||
DicomEvent.$on('isloaded', (data) => {
|
||||
if (this.isloaded) return false
|
||||
this.isloaded = true
|
||||
let { segment } = data
|
||||
this.delAllSegment()
|
||||
this.getSegmentationList(segment)
|
||||
|
|
@ -1429,43 +1432,49 @@ export default {
|
|||
let res = await getSegmentationList(data);
|
||||
this.loading = false;
|
||||
if (res.IsSuccess) {
|
||||
this.segmentList = []
|
||||
// this.segmentList = []
|
||||
let list = res.Result.CurrentPageData;
|
||||
for (let i = 0; i < list.length; i++) {
|
||||
let item = list[i]
|
||||
let obj = {
|
||||
segmentationId: item.Id,
|
||||
name: item.SegmentationName,
|
||||
view: true,
|
||||
segUrl: item.SEGUrl,
|
||||
segments: []
|
||||
}
|
||||
this.segmentList.push(obj)
|
||||
if (item.SEGUrl) {
|
||||
await this.readSegmentation(obj)
|
||||
} else {
|
||||
await this.createSegmentation(obj.segmentationId)
|
||||
this.createSegmentationRepresentation(obj.segmentationId)
|
||||
let obj = this.segmentList.find(i => i.segmentationId === item.Id)
|
||||
if (!obj) {
|
||||
obj = {
|
||||
segmentationId: item.Id,
|
||||
name: item.SegmentationName,
|
||||
view: true,
|
||||
segUrl: item.SEGUrl,
|
||||
segments: []
|
||||
}
|
||||
this.segmentList.push(obj)
|
||||
if (item.SEGUrl) {
|
||||
await this.readSegmentation(obj)
|
||||
} else {
|
||||
await this.createSegmentation(obj.segmentationId)
|
||||
this.createSegmentationRepresentation(obj.segmentationId)
|
||||
}
|
||||
}
|
||||
let segments = await this.getSegmentList(item.Id)
|
||||
segments.forEach((s, index) => {
|
||||
let SegmentJson = s.SegmentJson ? JSON.parse(s.SegmentJson) : {};
|
||||
let o = {
|
||||
segmentIndex: s.SegmentMumber,
|
||||
segmentationId: s.SegmentationId,
|
||||
SegmentLabel: s.SegmentName,
|
||||
color: s.ColorRgb,
|
||||
stats: SegmentJson.stats,
|
||||
bidirectional: SegmentJson.bidirectional,
|
||||
bidirectionalView: true,
|
||||
view: true,
|
||||
lock: item.locked,
|
||||
id: s.Id
|
||||
let o = obj.segments.find(i => i.id === s.Id)
|
||||
if (!o) {
|
||||
o = {
|
||||
segmentIndex: s.SegmentMumber,
|
||||
segmentationId: s.SegmentationId,
|
||||
SegmentLabel: s.SegmentName,
|
||||
color: s.ColorRgb,
|
||||
stats: SegmentJson.stats,
|
||||
bidirectional: SegmentJson.bidirectional,
|
||||
bidirectionalView: true,
|
||||
view: true,
|
||||
lock: item.locked,
|
||||
id: s.Id
|
||||
}
|
||||
obj.segments.push(o)
|
||||
this.selectSegment(o)
|
||||
this.changeColor(s.ColorRgb, o)
|
||||
this.lockSegment(o, true)
|
||||
}
|
||||
obj.segments.push(o)
|
||||
this.selectSegment(o)
|
||||
this.changeColor(s.ColorRgb, o)
|
||||
this.lockSegment(o, true)
|
||||
})
|
||||
this.$nextTick(() => {
|
||||
if (SEGMENT) {
|
||||
|
|
@ -1475,6 +1484,7 @@ export default {
|
|||
this.getBidirectional(obj.segments)
|
||||
})
|
||||
}
|
||||
this.isloaded = false
|
||||
}
|
||||
} catch (err) {
|
||||
this.loading = false
|
||||
|
|
|
|||
Loading…
Reference in New Issue