Commit c390484a by wangshuangqing

添加途径与频率的下拉数据

parent 307d754b
......@@ -2,7 +2,7 @@
* @Author: wsq
* @Date: 2022-04-22 15:20:58
* @LastEditors: wsq
* @LastEditTime: 2023-01-12 10:28:45
* @LastEditTime: 2023-02-02 16:06:18
* @Description:
-->
<template>
......@@ -22,7 +22,10 @@
</div>
</div>
<div class="Entrypath_top_right">
<el-button style="background-color:#0283bb;color:#ffff" size="mini" @click="okbtn()"
<el-button
style="background-color: #0283bb; color: #ffff"
size="mini"
@click="okbtn()"
>确定进入路径</el-button
>
</div>
......@@ -32,11 +35,28 @@
<div class="Entrypath_table_lefttab">
<div class="Entrypath_table_lefttab_select">
<div class="Entrypath_table_lefttab_select_inp">
<span>检索路径:</span> <el-input v-model="pathinput" size="mini" clearable/>
<span>检索路径:</span>
<el-input v-model="pathinput" size="mini" clearable />
</div>
<div class="Entrypath_table_lefttab_select_chack">
<el-button style="background-color:#ffff;color:#91cbcd;margin-right:10px;border:1px solid #91cbcd" plain size="mini" @click="selectbtn()">查询</el-button>
<el-checkbox v-model="checked" label="只显示推荐路径" size="large" @change="checkchange"/>
<el-button
style="
background-color: #ffff;
color: #91cbcd;
margin-right: 10px;
border: 1px solid #91cbcd;
"
plain
size="mini"
@click="selectbtn()"
>查询</el-button
>
<el-checkbox
v-model="checked"
label="只显示推荐路径"
size="large"
@change="checkchange"
/>
</div>
</div>
<div class="Entrypath_table_lefttab_table">
......@@ -71,7 +91,7 @@
:data="OnetableData"
border
stripe
:header-cell-style="{background:'#0184bc',color:'#ffff'}"
:header-cell-style="{ background: '#0184bc', color: '#ffff' }"
>
<el-table-column
show-overflow-tooltip
......@@ -94,7 +114,7 @@
scrollbar-always-on
height="100%"
stripe
:header-cell-style="{background:'#0184bc',color:'#ffff'}"
:header-cell-style="{ background: '#0184bc', color: '#ffff' }"
>
<el-table-column
show-overflow-tooltip
......@@ -117,7 +137,7 @@
scrollbar-always-on
height="100%"
stripe
:header-cell-style="{background:'#0184bc',color:'#ffff'}"
:header-cell-style="{ background: '#0184bc', color: '#ffff' }"
>
<el-table-column
show-overflow-tooltip
......@@ -143,7 +163,7 @@ import {
} from "@vue/composition-api";
import { decimal } from "../utils/decimal";
import { img } from "../assets/img/zu.png";
import { Message,MessageBox } from "element-ui";
import { Message, MessageBox } from "element-ui";
import { useRoute, useRouter } from "../utils/useVueRouter";
import { setItem, getItem } from "../utils/auth";
import { Loading } from "element-ui";
......@@ -159,7 +179,7 @@ export default {
//输入框
pathinput: "",
//选择框
checked:false,
checked: false,
//标识
IsRoute: "",
//患者信息
......@@ -222,13 +242,12 @@ export default {
.catch((error) => {});
};
//显示推荐路径单选框变化
const checkchange=(val)=>{
state.checked=val
const checkchange = (val) => {
state.checked = val;
};
//查询
const selectbtn=()=>{
getLeftdata()
const selectbtn = () => {
getLeftdata();
};
//获取左侧表格数据
const getLeftdata = () => {
......@@ -265,50 +284,48 @@ export default {
//点击进入路径按钮
const okbtn = () => {
MessageBox.confirm(
'确定进入路径吗?',
{
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
}
)
.then(() => {
if (state.iscid == 0) {
Message({
message: "请先选择路径名称!",
MessageBox.confirm(
"确定进入路径吗?",
{
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
});
} else if (state.iscid != 0) {
http
.post(
`/ClinicalRoute/ClinicalRoute/CreatePatientRoute?pid=${route.value.query.pid}&crid=${state.iscid}`,
{}
)
.then((data) => {
}
)
.then(() => {
if (state.iscid == 0) {
Message({
message: "成功",
type: "success",
message: "请先选择路径名称!",
type: "warning",
});
router.push({
path: "outClinicalpathway",
query: {
pid: route.value.query.pid,
},
});
})
.catch((error) => {});
}
})
.catch(() => {
Message({
type: 'info',
message: '取消',
})
})
} else if (state.iscid != 0) {
http
.post(
`/ClinicalRoute/ClinicalRoute/CreatePatientRoute?pid=${route.value.query.pid}&crid=${state.iscid}`,
{}
)
.then((data) => {
Message({
message: "成功",
type: "success",
});
router.push({
path: "outClinicalpathway",
query: {
pid: route.value.query.pid,
},
});
})
.catch((error) => {});
}
})
.catch(() => {
Message({
type: "info",
message: "取消",
});
});
};
onMounted(() => {
......@@ -326,7 +343,7 @@ export default {
rowclick,
okbtn,
checkchange,
selectbtn
selectbtn,
};
},
};
......@@ -343,22 +360,20 @@ export default {
background-color: #32a0d3 !important;
}
//多选框选中状态文本颜色
::v-deep .el-checkbox__input.is-checked+.el-checkbox__label{
color: black !important;
::v-deep .el-checkbox__input.is-checked + .el-checkbox__label {
color: black !important;
}
//多选框选中状态背景颜色
::v-deep .el-checkbox__input.is-checked .el-checkbox__inner{
background-color: #1097e0 !important;
border-color: #1097e0 !important;
::v-deep .el-checkbox__input.is-checked .el-checkbox__inner {
background-color: #1097e0 !important;
border-color: #1097e0 !important;
}
//输入框高亮颜色
::v-deep .el-input__inner{
background-color: #f3fbfe;
border: 1px solid #91cbcd;
::v-deep .el-input__inner {
background-color: #f3fbfe;
border: 1px solid #91cbcd;
}
// 滚动条的宽度
::v-deep .el-table__body-wrapper::-webkit-scrollbar {
/*滚动条整体样式*/
......@@ -442,7 +457,7 @@ export default {
span {
width: 80%;
color: #181617;
color: #181617;
display: flex;
justify-content: flex-start;
align-items: center;
......@@ -461,7 +476,7 @@ export default {
padding-left: 20px;
span {
width: 80%;
color: #181617;
color: #181617;
display: flex;
justify-content: flex-start;
align-items: center;
......
......@@ -2,7 +2,7 @@
* @Author: wsq
* @Date: 2022-04-22 15:20:58
* @LastEditors: wsq
* @LastEditTime: 2023-01-31 17:53:02
* @LastEditTime: 2023-02-03 13:16:40
* @Description:
-->
<template>
......@@ -142,7 +142,7 @@
default-expand-all
>
<el-table-column type="selection" width="55" />
<el-table-column label="医嘱类型" width="180" fixed="left">
<el-table-column label="医嘱类型" width="180">
<template #default="scope">{{ yztype[scope.row.type] }}</template>
</el-table-column>
<el-table-column
......@@ -150,21 +150,18 @@
property="advice_name"
label="路径名称"
width="150"
fixed="left"
/>
<el-table-column
show-overflow-tooltip
property="project_code"
label="医院项目编码"
width="120"
fixed="left"
/>
<el-table-column
show-overflow-tooltip
property="project_name"
label="医院项目名称"
width="150"
fixed="left"
/>
<el-table-column
......@@ -221,12 +218,48 @@
show-overflow-tooltip
property="medicUseMode"
label="途径"
/>
width="120"
>
<template #default="scope">
<el-select
v-if="scope.row.advice_name == null && scope.row.ischeck == 1"
size="mini"
v-model="scope.row.medicUseMode"
>
<el-option
v-for="item in medicUseModeoptions"
:key="item.id"
:label="item.describe"
:value="item.describe"
>
</el-option>
</el-select>
<span v-else>{{ scope.row.medicUseMode }}</span>
</template>
</el-table-column>
<el-table-column
show-overflow-tooltip
property="medicUsePlan"
label="频率"
/>
width="140"
>
<template #default="scope">
<el-select
v-if="scope.row.advice_name == null && scope.row.ischeck == 1"
size="mini"
v-model="scope.row.medicUsePlan"
>
<el-option
v-for="item in medicUsePlanoptions"
:key="item.id"
:label="item.describe"
:value="item.describe"
>
</el-option>
</el-select>
<span v-else>{{ scope.row.medicUsePlan }}</span>
</template>
</el-table-column>
<el-table-column prop="dropNumber" label="滴数" width="120">
<template #default="scope">
......@@ -302,6 +335,11 @@ export default {
const route = useRoute();
const router = useRouter();
const fromRef = ref();
function tableLayout() {
nextTick(() => {
fromRef.value.doLayout();
});
}
const monthlyPlanTable = ref();
const multipleTable = ref();
let state = reactive({
......@@ -349,7 +387,34 @@ export default {
],
tempRow: {}, //储存正在编辑的行
tempRowChildren: [],
medicUseModeoptions: [], //途径
medicUsePlanoptions: [], //频率
});
//获取途径,频率的下拉数据
const gemedicUseModeoptions = () => {
http
.post(
`/ClinicalRoute/ClinicalRoute/GetStaCRParametersByType?type=1`,
{}
)
.then((data) => {
state.medicUseModeoptions = data;
})
.catch((error) => {});
};
//获取频率,频率的下拉数据
const gemedicUsePlanoptions = () => {
http
.post(
`/ClinicalRoute/ClinicalRoute/GetStaCRParametersByType?type=2`,
{}
)
.then((data) => {
state.medicUsePlanoptions = data;
})
.catch((error) => {});
};
//获取患者信息
const gettopdata = () => {
......@@ -386,14 +451,7 @@ export default {
})
) {
row.ischeck = 1;
state.tempRow = _.cloneDeep(row);
if (row.children) {
for (let a = 0; a < row.children.length; a++) {
state.tempRowChildren = _.cloneDeep(row.children[a]);
console.log("state.tempRowChildren[a]", state.tempRowChildren);
}
row.children.map((j) => {
toggleSelection(j, true);
});
......@@ -403,34 +461,10 @@ export default {
if (row.children) {
row.children.map((p) => {
p.ischeck = 2;
// for (var i = 0; i < state.tableData.length; i++) {
// if (state.tableData[i].children.length > 0) {
// for (let j = 0; j < state.tableData[i].children.length; j++) {
// if (state.tableData[i].children[j].id == p.id) {
// state.tableData[i].children[j] =
// state.tempRowChildren[j - 1];
// console.log("p.id", p.id);
// console.log(
// "state.tempRowChildren[j-1]",
// state.tempRowChildren[j - 1]
// );
// }
// }
// }
// }
toggleSelection(p, false);
});
} else {
//取消选中 还原数据
for (var i = 0; i < state.tableData.length; i++) {
if (state.tableData[i].children.length > 0) {
for (let j = 0; j < state.tableData[i].children.length; j++) {
if (state.tableData[i].children[j].id == row.id) {
state.tableData[i].children[j] = state.tempRow;
}
}
}
}
//取消的行数据
row.ischeck = 2;
}
......@@ -543,6 +577,7 @@ export default {
state.timeindex = val.inhosdays;
state.case_routeid = val.case_routeid;
state.inhosdays = val.inhosdays;
//获取表格数据
http
.post(
`/ClinicalRoute/ClinicalRoute/GetGetRouteAdvicesRight?pid=${route.value.query.pid}&case_routeid=${state.case_routeid}&searchQuery=${state.inhosdays}`,
......@@ -567,7 +602,6 @@ export default {
};
//加入医嘱
const joinorder = () => {
console.log("加入按钮-tabledata", state.tableData);
http
.post(
`/ClinicalRoute/ClinicalRoute/SetPatientRoutes?pid=${route.value.query.pid}`,
......@@ -652,6 +686,8 @@ export default {
onMounted(() => {
gettopdata();
getlefttime();
gemedicUseModeoptions();
gemedicUsePlanoptions();
});
return {
......@@ -678,6 +714,9 @@ export default {
getreasonoptions,
getTitle,
confirm,
tableLayout,
gemedicUseModeoptions,
gemedicUsePlanoptions,
};
},
};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment