@@ -164,6 +187,9 @@ export default {
},
pacsType: 'dcm', // image/dcm
checkPictures: [],
+
+ tabChoosed: "0",
+ tabPosition: "top", // 多个明细检查排列方式
};
},
@@ -205,6 +231,21 @@ export default {
methods: {
checkPagePriv, moment,
+ // 显示tab标签名称,过长处理
+ dispLabel(itemName) {
+ return itemName.length > 5 ? (itemName.substring(0, 4) + "…") : itemName
+ },
+
+ // 清除结果
+ btnClear(seq) {
+ this.doctorCheck.checkItemList[seq].result = ''
+ },
+
+ // 默认结果
+ btnDefResult(seq) {
+ this.doctorCheck.checkItemList[seq].result = this.doctorCheck.checkItemList[seq].defaultResult
+ },
+
// 生成 图片预览列表
previewSrcList(oriList, curImag) {
let srcList = []
@@ -378,6 +419,7 @@ export default {
// 选择描述与结论
btnChooseBigtext() {
// console.log('this.pacsParams', this.pacsParams)
+ this.pacsParams.index = parseInt(this.tabChoosed)
this.pacsParams.refresh++
this.dialogWin.PacsTemplate = true
},
@@ -385,11 +427,11 @@ export default {
// 确定描述与结论
btnOkBigtext() {
// console.log('this.pacsParams', this.pacsParams)
- if (!this.pacsParams.result || !this.pacsParams.summary) {
- this.$message.warning({ showClose: true, message: '请填写检查结果与结论' })
+ if (!this.pacsParams.summary) {
+ this.$message.warning({ showClose: true, message: '请填写检查结论' })
return
}
- this.doctorCheck.checkItemList[0].result = this.pacsParams.result
+ //this.doctorCheck.checkItemList[0].result = this.pacsParams.result
this.doctorCheck.checkSummaryList = [{
id: Math.random(),
registerCheckId: this.doctorCheck.RegisterCheckEdit.id,
@@ -498,6 +540,14 @@ export default {
// 组合项目明细
this.doctorCheck.checkItemList = res.data.registerCheckItemDetails
+ if(this.doctorCheck.checkItemList.length > 0){
+ this.tabChoosed = "0"
+ }
+ if(this.doctorCheck.checkItemList.length > 3){
+ this.tabPosition = 'left'
+ }else{
+ this.tabPosition = 'top'
+ }
// 小结与建议
this.doctorCheck.checkSummaryList = res.data.registerCheckSummaryDetails
diff --git a/src/components/doctorCheck/PacsTemplate copy.vue b/src/components/doctorCheck/PacsTemplate copy.vue
new file mode 100644
index 0000000..3a79757
--- /dev/null
+++ b/src/components/doctorCheck/PacsTemplate copy.vue
@@ -0,0 +1,275 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
{{ node.label }}
+
+
+
+
+
+
+
+
+ 检查结果:
+
+
+
+
+
+
+
+ 清除
+ 默认结果
+ 确定
+
+
+
+
+
+
+
diff --git a/src/components/doctorCheck/PacsTemplate.vue b/src/components/doctorCheck/PacsTemplate.vue
index 87ade5f..338d513 100644
--- a/src/components/doctorCheck/PacsTemplate.vue
+++ b/src/components/doctorCheck/PacsTemplate.vue
@@ -5,9 +5,9 @@
+
-
检查结果:
-
+
+
+ 检查结果:
+
+ 横排
+ 纵排
+
+
+
+
+
+
+
+
检查结论:
@@ -40,8 +65,12 @@
- 清除
- 默认结果
+
+ 清除
+
+
+ 默认结果
+
确定
@@ -77,12 +106,13 @@ export default {
id: "id",
children: "children",
}, //树形组件的数据结构
-
+ tabChoosed: "0",
+ tabPosition: "top", // 多个明细检查排列方式
};
},
//
computed: {
- ...mapState(["window", "dialogWin"]),
+ ...mapState(["window", "dialogWin", "doctorCheck"]),
mainHeight() {
return this.window.pageHeight - 118;
@@ -92,12 +122,12 @@ export default {
return this.mainHeight - 120 - 80 - 80;
},
- decLineCount(){
- return this.refParams.from == 'dcm' ? 14:16
+ decLineCount() {
+ return this.refParams.from == 'dcm' ? 14 : 16
},
- conLineCount(){
- return this.refParams.from == 'dcm' ? 7:8
+ conLineCount() {
+ return this.refParams.from == 'dcm' ? 7 : 8
}
},
//创建组件后
@@ -115,12 +145,18 @@ export default {
methods: {
// 初始化数据
- init() {
- this.btnClear()
+ init() {
this.description = []
this.result = this.refParams.result || ''
- this.summary = this.refParams.summary || ''
- console.log('init')
+ this.summary = this.refParams.summary || ''
+ this.tabChoosed = this.refParams.index + ''
+ this.tabPosition = this.doctorCheck.checkItemList.length > 5 ? 'left' : 'top'
+ console.log('init')
+ },
+
+ // 显示tab标签名称,过长处理
+ dispLabel(itemName) {
+ return itemName.length > 5 ? (itemName.substring(0, 4) + "…") : itemName
},
//勾选节点
@@ -135,62 +171,73 @@ export default {
this.description = res.data.descriptionDetail
this.conclusion = res.data.conclusionDetail
let opraType = false
- if(checked){
+ if (checked) {
// 勾选
opraType = true
- }else if(!indeterminate){
+ } else if (!indeterminate) {
// 取消勾选
opraType = false
}
this.chooseDescription(opraType)
this.chooseConclusion(opraType)
}
- });
+ });
},
//树过滤
filterNode(value, data) {
//console.log(value,data)
- if (!value) return true;
+ if (!value) return true;
return data['displayName'].indexOf(value) > -1 || data['simpleCode'].indexOf(value.toUpperCase()) > -1;
},
// 选择true或取消false 描述
- chooseDescription(opraType){
+ chooseDescription(opraType) {
let bfind = false
+ let result = this.doctorCheck.checkItemList[parseInt(this.tabChoosed)].result
this.description.forEach(e => {
- bfind = this.result.includes(e.description)
- if(opraType){
- if(!bfind){
- if(this.result){
- this.result += ";" + e.description
- }else{
- this.result = e.description
+ bfind = result.includes(e.description)
+ if (opraType) {
+ if (!bfind) {
+ if (result) {
+ if(result == this.doctorCheck.checkItemList[parseInt(this.tabChoosed)].defaultResult){
+ result = e.description
+ }else{
+ result += ";" + e.description
+ }
+ } else {
+ result = e.description
}
}
- }else{
- if(bfind) this.result = this.result.replaceAll(e.description + ';','').replaceAll(e.description,'')
+ } else {
+ if (bfind) result = result.replaceAll(e.description + ';', '').replaceAll(e.description, '')
}
});
+
+ // 去掉 最后的 ;
+ if (result.substring(result.length - 1) == ';') {
+ result = result.substring(0, result.length - 1)
+ }
+ this.doctorCheck.checkItemList[parseInt(this.tabChoosed)].result = result
},
// 选择true或取消false 描述
- chooseConclusion(opraType){
+ chooseConclusion(opraType) {
let lfind = 0
let summarys = this.summary.split(';')
this.conclusion.forEach(e => {
lfind = summarys.indexOf(e.conclusion)
- if(opraType){
- if(lfind == -1) summarys.push(e.conclusion)
- }else{
- if(lfind > -1) summarys.splice(lfind,1)
+ if (opraType) {
+ if (lfind == -1) summarys.push(e.conclusion)
+ } else {
+ if (lfind > -1) summarys.splice(lfind, 1)
}
});
let summary = ''
summarys.forEach(e => {
- if(summary){
+ if (summary) {
summary += ';' + e
- }else{
+ } else {
summary = e
}
});
@@ -200,16 +247,16 @@ export default {
//获取pacs结果模板
getPacsTemplateTree() {
let resultType = [], resultTemplate = [], treeData = []
- postapi('/api/app/BigtextResultType/GetList',{
- itemTypeId:this.refParams.row.itemTypeId
+ postapi('/api/app/BigtextResultType/GetList', {
+ itemTypeId: this.refParams.row.itemTypeId
})
.then(res => {
if (res.code > -1) {
resultType = res.data
resultType.forEach(e => {
e.disabled = true
- });
- return postapi('/api/app/BigtextResultTemplate/GetList',{})
+ });
+ return postapi('/api/app/BigtextResultTemplate/GetList', {})
}
})
.then(res => {
@@ -223,23 +270,35 @@ export default {
}
})
},
-
+
btnTest() {
console.log('this.descriptionChoosed', this.descriptionChoosed)
console.log('this.conclusionChoosed', this.conclusionChoosed)
},
- // 清除所选描述与结论
- btnClear() {
- console.log('btnClear')
- this.result = ''
- this.summary = ''
+ // 清除所有描述与结论
+ btnClearAll() {
+ this.doctorCheck.checkItemList.forEach(e => {
+ e.result = ''
+ });
+ this.summary = ''
+ },
+
+ // 清除结果
+ btnClear(seq) {
+ this.doctorCheck.checkItemList[seq].result = ''
+ },
+
+ // 默认结果
+ btnDefResult(seq) {
+ this.doctorCheck.checkItemList[seq].result = this.doctorCheck.checkItemList[seq].defaultResult
},
// 默认结果
btnDefault() {
- this.btnClear()
- this.result = this.refParams.row.defaultResult
+ this.doctorCheck.checkItemList.forEach(e => {
+ e.result = e.defaultResult
+ });
this.summary = '未见异常'
},
@@ -259,6 +318,11 @@ export default {
if (newVal && newVal != oldVal) this.init();
},
+ // 检查明细改变
+ "tabChoosed"(newVal, oldVal) {
+ if (newVal && newVal != oldVal) this.conclusion = [];
+ },
+
},
};