Browse Source

diagnosis

master
pengjun 2 years ago
parent
commit
70d1643a9b
  1. 82
      src/components/common/ItemTypeTree.vue
  2. 4
      src/components/patientRegister/PatientRegisterItem.vue
  3. 6
      src/router/index.js
  4. 1
      src/store/index.js
  5. 6
      src/views/Home.vue
  6. 22
      src/views/charge/charge.vue
  7. 232
      src/views/diagnosis/diagnosis.vue
  8. 106
      src/views/diagnosis/diagnosisSug.vue

82
src/components/common/ItemTypeTree.vue

@ -0,0 +1,82 @@
<template>
<div>
<div style="margin:2px 2px 2px 2px;">
<el-input placeholder="输入关键字进行过滤" v-model="filterText" size="small" />
</div>
<div :style="'overflow: scroll;height:' +(window.pageHeight < 600 ? 410 : window.pageHeight - 190) + 'px;'">
<el-tree :data="dict.itemTypeTree" :props="customerOrg.treeprops"
node-key="id" :filter-node-method="filterNode"
:default-expanded-keys="customerOrg.defaultExpandedKeys"
@node-click="treeclick" highlight-current ref="customerOrgTree"/>
</div>
</div>
</template>
<script>
import { mapState, mapMutations } from "vuex";
import { getapi, postapi, putapi, deletapi } from "@/api/api";
import { tcdate, deepCopy } from "../../utlis/proFunc";
import { getTreePids} from "../../utlis/tree";
export default {
components: {},
props:['refreshItemTypeId'],
data() {
return {
filterText:''
};
},
computed: {
...mapState(["customerOrg", "window","dict"]),
},
//
created() {
},
//
mounted() {
//
this.dictInit();
},
methods: {
...mapMutations(["setData"]),
//
dictInit(){
//
getapi("/api/app/item-type/by-code-all").then((res) => {
if (res.code != -1) {
this.dict.itemTypeTree = res.data;
tcdate(this.dict.itemTypeTree);
}
});
},
//
treeclick(data) {
this.refreshItemTypeId(data.id);
},
//
filterNode(value, data) {
//console.log(value,data)
if (!value) return true;
return data['displayName'].indexOf(value) !== -1 || data['simpleCode'].indexOf(value.toUpperCase()) !== -1;
}
},
watch: {
"filterText"(newVal,oldVal){
this.$refs['customerOrgTree'].filter(newVal);
}
},
};
</script>
<style scoped>
@import "../../assets/css/global.css";
</style>

4
src/components/patientRegister/PatientRegisterItem.vue

@ -867,7 +867,7 @@ export default {
let sumChargeDetails = Number(0) //
let qtyIsOneLast = 0 //1
console.log('this.total / this.totalStand',this.total , this.totalStand)
// console.log('this.total / this.totalStand',this.total , this.totalStand)
this.discount = Math.round((100 * this.total / this.totalStand) * 100)/100
this.patientRegister.patientRegisterAbs.forEach((e, index) => {
@ -878,7 +878,7 @@ export default {
sumChargeDetails += Math.round((e.standardPrice * this.discount * e.amount / 100) * 100)/100
});
console.log('this.total - sumChargeDetails', sumChargeDetails, this.total - sumChargeDetails)
// console.log('this.total - sumChargeDetails', sumChargeDetails, this.total - sumChargeDetails)
//
if (this.total != sumChargeDetails) {
console.log('qtyIsOneLast',qtyIsOneLast)

6
src/router/index.js

@ -149,6 +149,12 @@ const routes = [{
component: () =>
import ("../views/basic-dictionary/DiagnosisLevel.vue"),
},
{
path: "/diagnosisSet",
name:'诊断建议设置',
component: () =>
import ("../views/diagnosis/diagnosis.vue"),
},
//---------------------- 收费设置 start ----------------------
{
path: "/invoice-item-type",

1
src/store/index.js

@ -242,6 +242,7 @@ export default new Vuex.Store({
asbItemAll: [], //所有组合项目
asbItem: [], //显示的 未选组合项目
asbItemQuick: [], //显示的 未选组合项目(供快速选择)
diagnosisLevel:[], //诊断级别
},
//项目特有的对象数据

6
src/views/Home.vue

@ -53,7 +53,7 @@
</span>
<span style="width: 20px">1</span>
用户权限管理</span
权限管理</span
>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item
@ -247,8 +247,8 @@
"
>性激素参考范围</el-dropdown-item
> -->
<el-dropdown-item command="diagnosis" class="dropdownmain"
>诊断</el-dropdown-item
<el-dropdown-item command="diagnosisSet" class="dropdownmain"
>诊断建议设置</el-dropdown-item
>
<el-dropdown-item
command="diagnosis-template"

22
src/views/charge/charge.vue

@ -261,6 +261,7 @@ export default {
patientName: '',
},//
patientList: [],//
formInit:{},
form: {
id: null,
patientRegisterId: null,
@ -322,6 +323,7 @@ export default {
},
created() {
this.formInit = Object.assign({},this.form)
this.dictInit();
},
@ -413,18 +415,20 @@ export default {
console.log(url,body,res)
if (res.code != - 1) {
this.patientList = res.data.items;
if (this.patientList.length == 1 && this.query.chargeFlag == 'N') {
//this.patientList.length == 1 && this.query.chargeFlag == 'N'
if (this.patientList.length > 0) {
// this.query.patientRegisterNo = this.patientList[0].patientRegisterNo;
// this.query.patientName = this.patientList[0].patientName;
// this.query.patientNo = this.patientList[0].patientNo;
this.$nextTick(() =>{
this.$refs['patientList'].setCurrentRow(this.patientList[0])
this.rowClick(this.patientList[0])
})
// this.rowClick(this.patientList[0])
// setTimeout(() => {
// this.$refs['patientList'].setCurrentRow(this.patientList[0])
// }, 200)
setTimeout(() => {
this.$refs['patientList'].setCurrentRow(this.patientList[0])
this.rowClick(this.patientList[0])
}, 100)
})
}else{
this.asbItemsForFee = []
this.form = Object.assign({},this.formInit)
}
}
loading.close();
@ -867,7 +871,7 @@ export default {
if (res.code != -1) {
this.form.id = res.data.chargeId; //
this.$confirm("操作成功, 是否打印发票?", "提示", {
confirmButtonText: "是",
cancelButtonText: "否",

232
src/views/diagnosis/diagnosis.vue

@ -0,0 +1,232 @@
<template>
<div>
<el-card class="elcard">
<div slot="header">
<span>诊断建议设置</span>
</div>
<div style="display: flex;">
<!-- 类别树组件 -->
<div :style="'border: 1px solid;width:200px; height:' +(window.pageHeight < 600 ? 450 : window.pageHeight - 150) +'px;'">
<ItemTypeTree :refreshItemTypeId="refreshItemTypeId"/>
</div>
<!-- 诊断与建议 -->
<div style="display: block;">
<!-- 诊断列表 -->
<div style="margin-left:5px;display: flex;">
<div :style="'width:' + (window.pageWidth - 200 - 110 - 50) + 'px;'">
<div style="margin-left: 5px;display: flex; flex-wrap: wrap;">
<div>
<el-checkbox v-model="query.itemTypeFlag">项目类别作为查询条件</el-checkbox>
<el-input placeholder="查询关键字" v-model="query.keyWords" size="small" clearable style="width: 200px" />
</div>
</div>
<div>
<el-table :data="tableData" border
:height="window.pageHeight < 600 ? 200 : Math.floor((window.pageHeight - 200) / 2)"
highlight-current-row @row-click="rowClick" size="small" ref="tableDiagnosis">
<el-table-column
v-for="(item, index) in headerCols"
:key="`col_${index}`"
:min-width="dropCol[index].minWidth"
:align="dropCol[index].align"
:label="item.label"
>
<template slot-scope="scope">
<div v-if="dropCol[index].prop == 'sn'" >
{{ scope.$index + 1 }}
</div>
<div v-else-if ="dropCol[index].prop == 'isIll'
|| dropCol[index].prop == 'isSummaryTemplate'" >
{{ scope.row[dropCol[index].prop] == 'Y' ? '是':'否' }}
</div>
<div v-else-if="dropCol[index].prop == 'itemTypeId'" >
{{ dddw(dict.itemTypeTree, "id", scope.row[dropCol[index].prop], "displayName") }}
</div>
<div v-else-if="dropCol[index].prop == 'diagnosisLevelId'" >
{{ dddw(dict.diagnosisLevel, "id", scope.row[dropCol[index].prop], "displayName") }}
</div>
<div v-else-if="dropCol[index].prop == 'forSexId'" >
{{ dddw(dict.forSex, "id", scope.row[dropCol[index].prop], "displayName") }}
</div>
<div v-else-if ="dropCol[index].prop == 'lastModificationTime'
|| dropCol[index].prop == 'creationTime'" >
{{ scope.row[dropCol[index].prop] ? moment(scope.row[dropCol[index].prop]).format('yyyy-MM-DD HH:mm:ss'):'' }}
</div>
<div v-else>
{{ scope.row[dropCol[index].prop] }}
</div>
</template>
</el-table-column>
</el-table>
</div>
</div>
<!--按钮-->
<div style="margin-left: 10px;">
<div>
<el-button class="btnClass" @click="btnQuery">查询</el-button>
</div>
<div>
<el-button type="primary" class="btnClass" @click="btnQuery">新增</el-button>
</div>
<div>
<el-button type="success" class="btnClass" @click="btnQuery">编辑</el-button>
</div>
<div>
<el-button type="danger" class="btnClass" @click="btnQuery">删除</el-button>
</div>
<div>
<el-button type="danger" class="btnClass" @click="btnQuery">保存排序</el-button>
</div>
</div>
</div>
<!-- 诊断对应的建议列表 -->
<div style="margin-top:5px;">
<DiagnosisSug :formDiagnosis="form"/>
</div>
</div>
</div>
</el-card>
</div>
</template>
<script>
import moment from "moment";
import { mapState } from "vuex";
import { getapi, postapi, putapi, deletapi } from "@/api/api";
import Sortable from "sortablejs";
import ItemTypeTree from "../../components/common/ItemTypeTree.vue";
import DiagnosisSug from "./diagnosisSug.vue";
import { deepCopy,dddw } from '@/utlis/proFunc';
export default {
components: {
ItemTypeTree,
DiagnosisSug,
},
data() {
return {
query:{
itemTypeFlag:true, //
itemTypeId:'',
keyWords:'',
},
tableData:[], //
formInit:{},
form:{
id:'',
suggestions:[],
},
rules:{
},
//
headerCols: [],
//
dropCol: [
{ label: "序号",prop: "sn",minWidth: 40,align:"center"},
{ label: "项目类别",prop: "itemTypeId",minWidth: 120,align:"center"},
{ label: "诊断级别",prop: "diagnosisLevelId",minWidth: 60,align:"center"},
{ label: "诊断名称",prop: "displayName",minWidth: 100,align:"center"},
{ label: "建议名称",prop: "suggestionName",minWidth: 100,align:"center"},
{ label: "疾病",prop: "isIll",minWidth: 40,align:"center"},
{ label: "适用性别",prop: "forSexId",minWidth: 60,align:"center"},
{ label: "总检模板",prop: "isSummaryTemplate",minWidth: 60,align:"center"},
{ label: "创建者",prop: "creatorName",minWidth: 60,align:"center"},
{ label: "创建时间",prop: "creationTime",minWidth: 130,align:"center"},
{ label: "修改者",prop: "lastModifierName",minWidth: 60,align:"center"},
{ label: "修改时间",prop: "lastModificationTime",minWidth: 130,align:"center"},
],
};
},
created() {
this.init()
},
//
mounted() {
this.btnQuery();
},
computed: {
...mapState(["customerOrg", "window","dict"]),
},
methods: {
moment,dddw,
init(){
this.formInit = Object.assign({},this.form)
this.headerCols = deepCopy(this.dropCol)
//
getapi("/api/app/for-sex").then((res) => {
if (res.code != -1) {
this.dict.forSex = res.data;
}
});
//
getapi("/api/app/diagnosis-level").then((res) => {
if (res.code != -1) {
this.dict.diagnosisLevel = res.data.items;
}
});
},
//
refreshItemTypeId(itemTypeId){
this.query.itemTypeId = itemTypeId
},
btnQuery(){
let body = {}
if(this.query.itemTypeFlag && this.query.itemTypeId) body.itemTypeId = this.query.itemTypeId
if(this.query.keyWords) body.keyWords = this.query.keyWords
postapi('/api/app/diagnosis/getlistinsuggestion',body).then(res =>{
if(res.code != -1){
this.tableData = res.data
}
})
console.log(this.query)
},
rowClick(row){
this.form = deepCopy(row)
},
},
watch: {
"query.itemTypeId"(newVal,oldVal){
this.btnQuery();
}
},
};
</script>
<style scoped>
@import '../../assets/css/global_button.css';
@import '../../assets/css/global_card.css';
@import '../../assets/css/global_dialog.css';
@import '../../assets/css/global_form.css';
@import '../../assets/css/global_input.css';
@import '../../assets/css/global_table.css';
@import '../../assets/css/global.css';
.btnClass{
width:100px;
margin-bottom: 5px;
}
</style>

106
src/views/diagnosis/diagnosisSug.vue

@ -0,0 +1,106 @@
<template>
<div style="margin-left:5px;display: flex;">
<div :style="'width:' + (window.pageWidth - 200 - 110 - 50) + 'px;'">
<el-table :data="tableData" border
:height="window.pageHeight < 600 ? 215 : Math.floor((window.pageHeight - 170) / 2)"
highlight-current-row @row-click="rowClick" size="small" ref="elTable">
<el-table-column type="index" label="序号" min-width="40" align="center"/>
<el-table-column prop="suggestionContent" label="建议内容">
<template slot-scope="scope">
<el-input type="textarea" v-model="scope.row.suggestionContent" placeholder="建议内容" style="width: 100%"
:autosize="{ minRows: 1, maxRows: 100 }">
</el-input>
</template>
</el-table-column>
</el-table>
</div>
<!--按钮-->
<div style="margin-left: 10px;">
<div>
<el-button type="primary" class="btnClass" @click="btnQuery">新增</el-button>
</div>
<div>
<el-button type="danger" class="btnClass" @click="btnQuery">删除</el-button>
</div>
<div>
<el-button type="success" class="btnClass" @click="btnQuery">保存</el-button>
</div>
</div>
</div>
</template>
<script>
import moment from "moment";
import { mapState } from "vuex";
import { getapi, postapi, putapi, deletapi } from "@/api/api";
import Sortable from "sortablejs";
import { deepCopy,dddw } from '@/utlis/proFunc';
export default {
components: {
},
props:["formDiagnosis"],
data() {
return {
tableData:[], //
curRow:{}, //
};
},
created() {
this.init()
},
//
mounted() {
this.btnQuery();
},
computed: {
...mapState(["window"]),
},
methods: {
moment,dddw,
init(){
this.tableData = deepCopy(this.formDiagnosis.suggestions)
},
//
refreshItemTypeId(itemTypeId){
this.query.itemTypeId = itemTypeId
},
rowClick(row){
this.curRow = row
},
},
watch: {
"formDiagnosis.id"(newVal,oldVal){
this.init()
}
},
};
</script>
<style scoped>
@import '../../assets/css/global_button.css';
@import '../../assets/css/global_card.css';
@import '../../assets/css/global_dialog.css';
@import '../../assets/css/global_form.css';
@import '../../assets/css/global_input.css';
@import '../../assets/css/global_table.css';
@import '../../assets/css/global.css';
.btnClass{
width:100px;
margin-bottom: 5px;
}
</style>
Loading…
Cancel
Save