OCT标准更改
parent
ccf3b823d8
commit
8831847850
|
@ -51,15 +51,31 @@ function getQuestions(questions) {
|
|||
// ivus
|
||||
answerObj.area1 = getQuestionAnswer(item.TableQuestions.Questions, 1001, answerObj)
|
||||
answerObj.area2 = getQuestionAnswer(item.TableQuestions.Questions, 1002, answerObj)
|
||||
var v = getQuestionAnswer(item.TableQuestions.Questions, 1003, answerObj)
|
||||
const v = getQuestionAnswer(item.TableQuestions.Questions, 1003, answerObj)
|
||||
answerObj.diff = v
|
||||
answerObj.saveTypeEnum = isNaN(parseFloat(v)) ? 1 : 2
|
||||
} else if (criterionType === 20) {
|
||||
// oct
|
||||
if (item.LesionType === 101) {
|
||||
answerObj.l1 = getQuestionAnswer(item.TableQuestions.Questions, 1011, answerObj)
|
||||
answerObj.l2 = getQuestionAnswer(item.TableQuestions.Questions, 1012, answerObj)
|
||||
answerObj.l3 = getQuestionAnswer(item.TableQuestions.Questions, 1013, answerObj)
|
||||
const min = getQuestionAnswer(item.TableQuestions.Questions, 1014, answerObj)
|
||||
answerObj.min = min
|
||||
const mean = getQuestionAnswer(item.TableQuestions.Questions, 1015, answerObj)
|
||||
answerObj.mean = mean
|
||||
answerObj.saveTypeEnum = (isNaN(parseFloat(min)) || isNaN(parseFloat(mean))) ? 1 : 2
|
||||
} else if (item.LesionType === 103) {
|
||||
const angle = getQuestionAnswer(item.TableQuestions.Questions, 1016, answerObj)
|
||||
answerObj.angle = angle
|
||||
answerObj.saveTypeEnum = isNaN(parseFloat(angle)) ? 1 : 2
|
||||
}
|
||||
} else {
|
||||
answerObj.lesionPart = getQuestionAnswer(item.TableQuestions.Questions, 8, answerObj)
|
||||
answerObj.loctation = getQuestionAnswer(item.TableQuestions.Questions, 6, answerObj)
|
||||
answerObj.lesionLength = getQuestionAnswer(item.TableQuestions.Questions, 0, answerObj)
|
||||
answerObj.lesionShort = getQuestionAnswer(item.TableQuestions.Questions, 1, answerObj)
|
||||
var isLymphLesion = getQuestionAnswer(item.TableQuestions.Questions, 2, answerObj)
|
||||
let isLymphLesion = getQuestionAnswer(item.TableQuestions.Questions, 2, answerObj)
|
||||
isLymphLesion = isLymphLesion ? parseInt(isLymphLesion) : null
|
||||
answerObj.isLymphLesion = isLymphLesion
|
||||
answerObj.lesionState = getQuestionAnswer(item.TableQuestions.Questions, 7, answerObj)
|
||||
|
|
|
@ -18,30 +18,6 @@
|
|||
<i class="el-icon-circle-close" style="font-size: 25px;cursor: pointer;" @click="handleClose" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- <el-form-item
|
||||
:label="$t('trials:reading:title:lesionType')"
|
||||
prop="LesionType"
|
||||
:rules="[
|
||||
{ required:true,message: $t('common:ruleMessage:select'), trigger: ['blur']},
|
||||
]"
|
||||
>
|
||||
<el-select
|
||||
v-model="questionForm.LesionType"
|
||||
filterable
|
||||
:disabled="!isCurrentTask || readingTaskState>=2"
|
||||
@change="((val)=>{lesionTypeChange(val)})"
|
||||
>
|
||||
|
||||
<el-option
|
||||
v-for="item of $d.LesionType"
|
||||
:key="item.id"
|
||||
:value="item.value"
|
||||
:label="item.label"
|
||||
/>
|
||||
|
||||
</el-select>
|
||||
</el-form-item> -->
|
||||
<el-form-item
|
||||
v-for="qs in questions"
|
||||
v-show="qs.ShowQuestion!==2"
|
||||
|
@ -315,44 +291,6 @@ export default {
|
|||
return ''
|
||||
}
|
||||
},
|
||||
async lesionTypeChange(v) {
|
||||
this.$emit('determineExistsUnsavedLession', async val => {
|
||||
if (val) {
|
||||
// 判断是否超过该病灶类型个数的最大值
|
||||
var idx = this.tableQuestions.findIndex(item => item.LesionType === v)
|
||||
if (idx > -1 && !!this.tableQuestions[idx].MaxQuestionCount && this.tableQuestions[idx].MaxQuestionCount <= this.tableQuestions[idx].TableQuestions.Answers.length) {
|
||||
let msg = this.$t('trials:reading:warnning:msg14')
|
||||
// msg = msg.replace('xxx', this.tableQuestions[idx].QuestionName)
|
||||
msg = msg.replace('xxx', this.tableQuestions[idx].MaxQuestionCount)
|
||||
this.$confirm(msg, {
|
||||
type: 'warning',
|
||||
showCancelButton: false,
|
||||
callback: action => {}
|
||||
})
|
||||
this.$set(this.questionForm, 'LesionType', this.originalQuestionForm.LesionType)
|
||||
return
|
||||
}
|
||||
|
||||
var arr = []
|
||||
this.questionForm[this.getQuestionId(1001)] = ''
|
||||
this.questionForm[this.getQuestionId(1002)] = ''
|
||||
this.questionForm[this.getQuestionId(1003)] = ''
|
||||
this.questions.forEach(item => {
|
||||
item.Answer = this.questionForm[item.Id] ? this.questionForm[item.Id] : ''
|
||||
arr.push(item)
|
||||
})
|
||||
var type = null
|
||||
if (this.questionForm.RowId) {
|
||||
type = 1
|
||||
} else {
|
||||
type = 0
|
||||
}
|
||||
DicomEvent.$emit('changeLesionType', { questionForm: arr, oldLesionType: this.lesionType, newLesionType: v, rowIndex: this.questionForm.RowIndex, questionId: this.parentQsId, measureData: this.questionForm.MeasureData, type, rowId: this.questionForm.RowId })
|
||||
} else {
|
||||
this.$set(this.questionForm, 'LesionType', this.originalQuestionForm.LesionType)
|
||||
}
|
||||
})
|
||||
},
|
||||
deleteLesionInfo() {
|
||||
return new Promise((resolve, reject) => {
|
||||
const loading = this.$loading({ fullscreen: true })
|
||||
|
@ -390,7 +328,7 @@ export default {
|
|||
},
|
||||
calculate(qsMarkArr, type) {
|
||||
var num = 0
|
||||
for (let i = 0; i< qsMarkArr.length; i++) {
|
||||
for (let i = 0; i < qsMarkArr.length; i++) {
|
||||
const mark = qsMarkArr[i]
|
||||
const v = this.questionForm[this.getQuestionId(mark)]
|
||||
if (isNaN(parseFloat(v))) {
|
||||
|
@ -407,7 +345,7 @@ export default {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
return num === null ? num : num.toFixed(this.digitPlaces)
|
||||
},
|
||||
limitBlur(qId, valueType) {
|
||||
|
|
|
@ -75,13 +75,13 @@
|
|||
</el-tooltip>
|
||||
<div style="position: absolute;left: 60px;top: 2px;">
|
||||
<div style="display: flex;flex-direction: row;font-size: 11px;width:200px;height: 30px;">
|
||||
<div style="margin-left:10px;">
|
||||
<div v-show="item.TableQuestions.Answers[i].area1" style="margin-left:10px;">
|
||||
{{ item.TableQuestions.Answers[i].area1 }}m㎡
|
||||
</div>
|
||||
<div style="margin-left:10px;">
|
||||
<div v-show="item.TableQuestions.Answers[i].area2" style="margin-left:10px;">
|
||||
{{ item.TableQuestions.Answers[i].area2 }}m㎡
|
||||
</div>
|
||||
<div style="margin-left:10px;margin-bottom:5px;">
|
||||
<div v-show="item.TableQuestions.Answers[i].diff" style="margin-left:10px;margin-bottom:5px;">
|
||||
{{ item.TableQuestions.Answers[i].diff }}m㎡
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
@ -18,30 +18,6 @@
|
|||
<i class="el-icon-circle-close" style="font-size: 25px;cursor: pointer;" @click="handleClose" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- <el-form-item
|
||||
:label="$t('trials:reading:title:lesionType')"
|
||||
prop="LesionType"
|
||||
:rules="[
|
||||
{ required:true,message: $t('common:ruleMessage:select'), trigger: ['blur']},
|
||||
]"
|
||||
>
|
||||
<el-select
|
||||
v-model="questionForm.LesionType"
|
||||
filterable
|
||||
:disabled="!isCurrentTask || readingTaskState>=2"
|
||||
@change="((val)=>{lesionTypeChange(val)})"
|
||||
>
|
||||
|
||||
<el-option
|
||||
v-for="item of $d.LesionType"
|
||||
:key="item.id"
|
||||
:value="item.value"
|
||||
:label="item.label"
|
||||
/>
|
||||
|
||||
</el-select>
|
||||
</el-form-item> -->
|
||||
<el-form-item
|
||||
v-for="qs in questions"
|
||||
v-show="qs.ShowQuestion!==2"
|
||||
|
@ -70,9 +46,9 @@
|
|||
@change="((val)=>{formItemChange(val, qs)})"
|
||||
@blur="limitBlur(qs.Id, qs.ValueType)"
|
||||
>
|
||||
<!-- <template v-if="qs.Unit" slot="append">
|
||||
<template v-if="qs.Unit" slot="append">
|
||||
{{ $fd('ValueUnit', parseInt(qs.Unit)) }}
|
||||
</template> -->
|
||||
</template>
|
||||
</el-input>
|
||||
</template>
|
||||
<!-- 自动计算 -->
|
||||
|
@ -315,96 +291,65 @@ export default {
|
|||
return ''
|
||||
}
|
||||
},
|
||||
async lesionTypeChange(v) {
|
||||
this.$emit('determineExistsUnsavedLession', async val => {
|
||||
if (val) {
|
||||
// 判断是否超过该病灶类型个数的最大值
|
||||
var idx = this.tableQuestions.findIndex(item => item.LesionType === v)
|
||||
if (idx > -1 && !!this.tableQuestions[idx].MaxQuestionCount && this.tableQuestions[idx].MaxQuestionCount <= this.tableQuestions[idx].TableQuestions.Answers.length) {
|
||||
let msg = this.$t('trials:reading:warnning:msg14')
|
||||
// msg = msg.replace('xxx', this.tableQuestions[idx].QuestionName)
|
||||
msg = msg.replace('xxx', this.tableQuestions[idx].MaxQuestionCount)
|
||||
this.$confirm(msg, {
|
||||
type: 'warning',
|
||||
showCancelButton: false,
|
||||
callback: action => {}
|
||||
})
|
||||
this.$set(this.questionForm, 'LesionType', this.originalQuestionForm.LesionType)
|
||||
return
|
||||
}
|
||||
|
||||
var arr = []
|
||||
this.questionForm[this.getQuestionId(1001)] = ''
|
||||
this.questionForm[this.getQuestionId(1002)] = ''
|
||||
this.questionForm[this.getQuestionId(1003)] = ''
|
||||
this.questions.forEach(item => {
|
||||
item.Answer = this.questionForm[item.Id] ? this.questionForm[item.Id] : ''
|
||||
arr.push(item)
|
||||
})
|
||||
var type = null
|
||||
if (this.questionForm.RowId) {
|
||||
type = 1
|
||||
} else {
|
||||
type = 0
|
||||
}
|
||||
DicomEvent.$emit('changeLesionType', { questionForm: arr, oldLesionType: this.lesionType, newLesionType: v, rowIndex: this.questionForm.RowIndex, questionId: this.parentQsId, measureData: this.questionForm.MeasureData, type, rowId: this.questionForm.RowId })
|
||||
} else {
|
||||
this.$set(this.questionForm, 'LesionType', this.originalQuestionForm.LesionType)
|
||||
}
|
||||
})
|
||||
},
|
||||
deleteLesionInfo() {
|
||||
return new Promise((resolve, reject) => {
|
||||
const loading = this.$loading({ fullscreen: true })
|
||||
var param = {
|
||||
visitTaskId: this.visitTaskId,
|
||||
questionId: this.parentQsId,
|
||||
rowId: this.questionForm.RowId
|
||||
}
|
||||
deleteReadingRowAnswer(param)
|
||||
.then(async res => {
|
||||
if (res.IsSuccess) {
|
||||
DicomEvent.$emit('getReportInfo', true)
|
||||
}
|
||||
loading.close()
|
||||
resolve()
|
||||
}).catch(() => {
|
||||
loading.close()
|
||||
reject()
|
||||
})
|
||||
})
|
||||
},
|
||||
async formItemChange(v, question) {
|
||||
if (this.questionForm.RowId) {
|
||||
this.$set(this.questionForm, 'saveTypeEnum', 1)
|
||||
} else {
|
||||
this.$set(this.questionForm, 'saveTypeEnum', 0)
|
||||
}
|
||||
if (question.QuestionMark === 1001 || question.QuestionMark === 1002) {
|
||||
this.questionForm[this.getQuestionId(1003)] = this.calculate([1001, 1002], '-')
|
||||
if (question.QuestionMark === 1011 || question.QuestionMark === 1012 || question.QuestionMark === 1013) {
|
||||
// 最小值
|
||||
this.questionForm[this.getQuestionId(1014)] = this.calculate([1011, 1012, 1013], 'min')
|
||||
// 平均值
|
||||
this.questionForm[this.getQuestionId(1015)] = this.calculate([1011, 1012, 1013], 'avg')
|
||||
}
|
||||
this.$emit('resetQuestions', { saveTypeEnum: this.questionForm.saveTypeEnum, rowIndex: this.rowIndex, questionId: this.parentQsId, anwsers: this.questionForm })
|
||||
let l1, l2, l3, min, mean, angle
|
||||
if (this.lesionType === 101) {
|
||||
l1 = this.getQuestionVal(1011)
|
||||
l2 = this.getQuestionVal(1012)
|
||||
l3 = this.getQuestionVal(1013)
|
||||
min = this.getQuestionVal(1014)
|
||||
mean = this.getQuestionVal(1015)
|
||||
} else if (this.lesionType === 103) {
|
||||
angle = this.getQuestionVal(1016)
|
||||
}
|
||||
this.$emit('resetQuestions', { l1, l2, l3, min, mean, angle, saveTypeEnum: this.questionForm.saveTypeEnum, rowIndex: this.rowIndex, questionId: this.parentQsId, anwsers: this.questionForm })
|
||||
},
|
||||
calculate(qsMarkArr, type) {
|
||||
var num = 0
|
||||
qsMarkArr.map((qsmark, i) => {
|
||||
const arr = []
|
||||
for (let i = 0; i < qsMarkArr.length; i++) {
|
||||
const mark = qsMarkArr[i]
|
||||
let v = this.questionForm[this.getQuestionId(mark)]
|
||||
if (isNaN(parseFloat(v))) {
|
||||
num = null
|
||||
break
|
||||
}
|
||||
v = parseFloat(v)
|
||||
if (i === 0) {
|
||||
const v = this.questionForm[this.getQuestionId(qsmark)]
|
||||
num = isNaN(parseFloat(v)) ? 0 : parseFloat(v)
|
||||
num = v
|
||||
arr.push(v)
|
||||
} else {
|
||||
const v = this.questionForm[this.getQuestionId(qsmark)]
|
||||
switch (type) {
|
||||
case '-':
|
||||
num -= isNaN(parseFloat(v)) ? 0 : parseFloat(v)
|
||||
case 'min':
|
||||
num = num > v ? v : num
|
||||
break
|
||||
case 'avg':
|
||||
arr.push(v)
|
||||
if (arr.length === qsMarkArr.length) {
|
||||
num = arr.reduce((acc, curr) => {
|
||||
return acc + curr
|
||||
}, 0) / arr.length
|
||||
}
|
||||
break
|
||||
}
|
||||
}
|
||||
})
|
||||
return parseFloat(num).toFixed(this.digitPlaces)
|
||||
}
|
||||
|
||||
return num === null ? num : num.toFixed(this.digitPlaces)
|
||||
},
|
||||
limitBlur(qId, valueType) {
|
||||
const value = isNaN(parseFloat(this.questionForm[qId])) ? null : parseFloat(this.questionForm[qId])
|
||||
if (value === null) return
|
||||
const value = this.questionForm[qId]
|
||||
if (valueType === 0) {
|
||||
this.$set(this.questionForm, qId, parseInt(value))
|
||||
} else if (valueType === 3) {
|
||||
|
@ -494,7 +439,17 @@ export default {
|
|||
this.$set(this.questionForm, 'saveTypeEnum', 2)
|
||||
this.originalQuestionForm = { ...this.questionForm }
|
||||
this.$set(this.questionForm, 'RowId', res.Result.RowId)
|
||||
this.$emit('resetQuestions', { saveTypeEnum: this.questionForm.saveTypeEnum, rowIndex: this.rowIndex, questionId: this.parentQsId, anwsers: this.questionForm })
|
||||
let l1, l2, l3, min, mean, angle
|
||||
if (this.lesionType === 101) {
|
||||
l1 = this.getQuestionVal(1011)
|
||||
l2 = this.getQuestionVal(1012)
|
||||
l3 = this.getQuestionVal(1013)
|
||||
min = this.getQuestionVal(1014)
|
||||
mean = this.getQuestionVal(1015)
|
||||
} else if (this.lesionType === 103) {
|
||||
angle = this.getQuestionVal(1016)
|
||||
}
|
||||
this.$emit('resetQuestions', { l1, l2, l3, min, mean, angle, saveTypeEnum: this.questionForm.saveTypeEnum, rowIndex: this.rowIndex, questionId: this.parentQsId, anwsers: this.questionForm })
|
||||
this.$emit('close')
|
||||
|
||||
DicomEvent.$emit('refreshQuestions')
|
||||
|
|
|
@ -73,6 +73,19 @@
|
|||
<el-tooltip v-if="readingTaskState<2 && parseInt(item.TableQuestions.Answers[i].saveTypeEnum) ===1" class="item" effect="dark" :content="$t('trials:reading:button:incompleteInfor')" placement="bottom">
|
||||
<i class="el-icon-warning" style="color:#ff9800" />
|
||||
</el-tooltip>
|
||||
<div style="position: absolute;left: 60px;top: 2px;">
|
||||
<div style="display: flex;flex-direction: row;font-size: 11px;width:200px;height: 30px;">
|
||||
<div v-show="item.TableQuestions.Answers[i].min && item.LesionType === 101" style="margin-left:10px;">
|
||||
min: {{ item.TableQuestions.Answers[i].min }}μm
|
||||
</div>
|
||||
<div v-show="item.TableQuestions.Answers[i].mean && item.LesionType === 101" style="margin-left:10px;">
|
||||
mean: {{ item.TableQuestions.Answers[i].mean }}μm
|
||||
</div>
|
||||
<div v-show="item.TableQuestions.Answers[i].angle && item.LesionType === 103" style="margin-left:10px;">
|
||||
{{ item.TableQuestions.Answers[i].angle }}°
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</template>
|
||||
|
@ -91,7 +104,6 @@
|
|||
:reading-task-state="readingTaskState"
|
||||
:is-base-line-task="isBaseLineTask"
|
||||
@getReadingQuestionAndAnswer="getReadingQuestionAndAnswer"
|
||||
@determineExistsUnsavedLession="determineExistsUnsavedLession"
|
||||
@resetQuestions="resetQuestions"
|
||||
@close="close"
|
||||
/>
|
||||
|
@ -349,7 +361,15 @@ export default {
|
|||
if (item.Type === 'table' && item.Id === obj.questionId) {
|
||||
var idx = item.TableQuestions.Answers.findIndex(i => i.RowIndex === obj.rowIndex)
|
||||
item.TableQuestions.Answers[idx].saveTypeEnum = obj.saveTypeEnum
|
||||
|
||||
if (item.LesionType === 101) {
|
||||
item.TableQuestions.Answers[idx].l1 = obj.l1
|
||||
item.TableQuestions.Answers[idx].l2 = obj.l2
|
||||
item.TableQuestions.Answers[idx].l3 = obj.l3
|
||||
item.TableQuestions.Answers[idx].min = obj.min
|
||||
item.TableQuestions.Answers[idx].mean = obj.mean
|
||||
} else if (item.LesionType === 103) {
|
||||
item.TableQuestions.Answers[idx].angle = obj.angle
|
||||
}
|
||||
for (const i in obj.anwsers) {
|
||||
item.TableQuestions.Answers[idx][i] = String(obj.anwsers[i])
|
||||
}
|
||||
|
@ -364,8 +384,14 @@ export default {
|
|||
if (item.Type === 'table' && item.TableQuestions && item.TableQuestions.Answers.length > 0) {
|
||||
item.TableQuestions.Answers.forEach(answerObj => {
|
||||
if (answerObj.RowId) {
|
||||
var diffVal = this.getQuestionAnswer(item.TableQuestions.Questions, 1003, answerObj)
|
||||
this.$set(answerObj, 'saveTypeEnum', isNaN(parseFloat(diffVal)) ? 1 : 2)
|
||||
if (item.LesionType === 101) {
|
||||
var min = this.getQuestionAnswer(item.TableQuestions.Questions, 1014, answerObj)
|
||||
var mean = this.getQuestionAnswer(item.TableQuestions.Questions, 1015, answerObj)
|
||||
this.$set(answerObj, 'saveTypeEnum', (isNaN(parseFloat(min)) || isNaN(parseFloat(mean))) ? 1 : 2)
|
||||
} else if (item.LesionType === 103) {
|
||||
var angle = this.getQuestionAnswer(item.TableQuestions.Questions, 1016, answerObj)
|
||||
this.$set(answerObj, 'saveTypeEnum', isNaN(parseFloat(angle)) ? 1 : 2)
|
||||
}
|
||||
} else {
|
||||
this.$set(answerObj, 'saveTypeEnum', 0)
|
||||
}
|
||||
|
@ -497,10 +523,6 @@ export default {
|
|||
return 0
|
||||
}
|
||||
},
|
||||
determineExistsUnsavedLession(callback) {
|
||||
callback(true)
|
||||
return
|
||||
},
|
||||
getLesionName(orderMark, rowIndex) {
|
||||
var lessionName = ''
|
||||
var rowIndexArr = rowIndex.split('.')
|
||||
|
@ -623,6 +645,7 @@ export default {
|
|||
async close(questionsObj) {
|
||||
if (questionsObj) {
|
||||
this.getReadingQuestionAndAnswer(questionsObj.visitTaskId)
|
||||
this.refreshQuestions()
|
||||
}
|
||||
this.activeItem.activeRowIndex = null
|
||||
this.activeItem.activeCollapseId = null
|
||||
|
|
Loading…
Reference in New Issue