删除表格数据判断标记是否存在
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
parent
c5c096a592
commit
c904b21287
|
@ -496,6 +496,9 @@ export default {
|
||||||
this.$emit('operateImageMarker', { operateStateEnum: 6, question })
|
this.$emit('operateImageMarker', { operateStateEnum: 6, question })
|
||||||
},
|
},
|
||||||
async deleteTableCol(row, index) {
|
async deleteTableCol(row, index) {
|
||||||
|
let data = row.TableQuestions.Answers[index]
|
||||||
|
let hasMark = Object.keys(data).some(key => this.questionsMarkStatus[`${data.RowId}_${key}`] && this.questionsMarkStatus[`${data.RowId}_${key}`].isMarked)
|
||||||
|
if (hasMark) return this.$alert(this.$t('dicom3D:ReadPage:alert:QuestionToMarkNoDel'))
|
||||||
let loading = null
|
let loading = null
|
||||||
try {
|
try {
|
||||||
let confirm = await this.$confirm(this.$t('trials:uploadNonDicoms:message:msg1'))
|
let confirm = await this.$confirm(this.$t('trials:uploadNonDicoms:message:msg1'))
|
||||||
|
@ -691,21 +694,26 @@ export default {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (isExistUnSaved) {
|
if (isExistUnSaved) {
|
||||||
// 标记未保存是否确认关闭?
|
if (this.addOrEdit.type = 'add') {
|
||||||
const confirm = await this.$confirm(this.$t("dicom3D:CustomizeQuestionFormItem:confirm:markNoSaveAndclose"), {
|
// 标记未保存是否确认关闭?
|
||||||
type: 'warning',
|
const confirm = await this.$confirm(this.$t("dicom3D:CustomizeQuestionFormItem:confirm:markNoSaveAndclose"), {
|
||||||
distinguishCancelAndClose: true
|
type: 'warning',
|
||||||
})
|
distinguishCancelAndClose: true
|
||||||
if (confirm !== 'confirm') return
|
})
|
||||||
// 清除绑定关系
|
if (confirm !== 'confirm') return
|
||||||
let obj = {}
|
// 清除绑定关系
|
||||||
if (!this.QuestionsForm.RowId) {
|
let obj = {}
|
||||||
obj.markTableQuestions = this.markTableQuestions
|
if (!this.QuestionsForm.RowId) {
|
||||||
obj.questionId = this.question.Id
|
obj.markTableQuestions = this.markTableQuestions
|
||||||
this.$emit('unBindAnnotationToQuestion', obj)
|
obj.questionId = this.question.Id
|
||||||
}
|
this.$emit('unBindAnnotationToQuestion', obj)
|
||||||
|
}
|
||||||
|
|
||||||
|
return this.addOrEdit.visible = false
|
||||||
|
}
|
||||||
|
// 标记未保存无法关闭?
|
||||||
|
return this.$alert(this.$t('dicom3D:CustomizeQuestionFormItem:alert:markNoSaveNoclose'))
|
||||||
|
|
||||||
this.addOrEdit.visible = false
|
|
||||||
} else {
|
} else {
|
||||||
this.addOrEdit.visible = false
|
this.addOrEdit.visible = false
|
||||||
}
|
}
|
||||||
|
@ -1185,21 +1193,25 @@ export default {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (isExistUnSaved) {
|
if (isExistUnSaved) {
|
||||||
//标记未保存是否确认关闭?
|
if (this.addOrEdit.type = 'add') {
|
||||||
const confirm = await this.$confirm(this.$t("dicom3D:CustomizeQuestionFormItem:confirm:markNoSaveAndclose"), {
|
//标记未保存是否确认关闭?
|
||||||
type: 'warning',
|
const confirm = await this.$confirm(this.$t("dicom3D:CustomizeQuestionFormItem:confirm:markNoSaveAndclose"), {
|
||||||
distinguishCancelAndClose: true
|
type: 'warning',
|
||||||
})
|
distinguishCancelAndClose: true
|
||||||
if (confirm !== 'confirm') return
|
})
|
||||||
// 清除绑定关系
|
if (confirm !== 'confirm') return
|
||||||
let obj = {}
|
// 清除绑定关系
|
||||||
if (!this.QuestionsForm.RowId) {
|
let obj = {}
|
||||||
obj.markTableQuestions = this.markTableQuestions
|
if (!this.QuestionsForm.RowId) {
|
||||||
obj.questionId = this.question.Id
|
obj.markTableQuestions = this.markTableQuestions
|
||||||
this.$emit('unBindAnnotationToQuestion', obj)
|
obj.questionId = this.question.Id
|
||||||
}
|
this.$emit('unBindAnnotationToQuestion', obj)
|
||||||
|
}
|
||||||
|
|
||||||
done()
|
return done()
|
||||||
|
}
|
||||||
|
// 标记未保存无法关闭?
|
||||||
|
return this.$alert(this.$t('dicom3D:CustomizeQuestionFormItem:alert:markNoSaveNoclose'))
|
||||||
// this.$alert('存在标记信息未保存!')
|
// this.$alert('存在标记信息未保存!')
|
||||||
} else {
|
} else {
|
||||||
done()
|
done()
|
||||||
|
|
|
@ -922,13 +922,15 @@ export default {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
this.questionMarkInfoList = questionMarkInfoList.filter(item => {
|
this.questionMarkInfoList = questionMarkInfoList.filter(item => {
|
||||||
const { TableQuestionId, QuestionId } = item || {}
|
const { TableQuestionId, QuestionId, RowId } = item || {}
|
||||||
if ((TableQuestionId && QuestionId === questionId && markTableQuestions.includes(TableQuestionId))) {
|
if ((TableQuestionId && QuestionId === questionId && markTableQuestions.includes(TableQuestionId)) && !RowId) {
|
||||||
if (questionsMarkStatus && questionsMarkStatus[TableQuestionId]) {
|
if (questionsMarkStatus && questionsMarkStatus[TableQuestionId]) {
|
||||||
delete questionsMarkStatus[TableQuestionId]
|
delete questionsMarkStatus[TableQuestionId]
|
||||||
|
}else {
|
||||||
|
return item
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
return
|
return item
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in New Issue