This commit is contained in:
曹辉 2022-11-07 16:42:59 +08:00
parent c8642a686d
commit 1e6ec7bf49
6 changed files with 451 additions and 368 deletions

View File

@ -8,8 +8,11 @@
v-show="showSearch"
label-width="68px"
>
<el-form-item label="护理站" prop="nurseStationId"
v-if="nurseStationlist.find((e) => e.isAdmin == '1')">
<el-form-item
label="护理站"
prop="nurseStationId"
v-if="nurseStationlist.find((e) => e.isAdmin == '1')"
>
<el-select
v-model="queryParams.nurseStationId"
placeholder="请选择护理站"
@ -25,8 +28,7 @@
</el-option>
</el-select>
</el-form-item>
<el-form-item label="护理站" prop="nurseStationId"
v-else>
<el-form-item label="护理站" prop="nurseStationId" v-else>
<el-select
v-model="queryParams.nurseStationId"
placeholder="请选择护理站"
@ -150,16 +152,8 @@
prop="departmentPerson"
/> -->
<el-table-column label="联系电话" align="center" prop="phone" />
<el-table-column
label="创建时间"
align="center"
prop="createTime"
/>
<el-table-column
label="创建人"
align="center"
prop="createBy"
/>
<el-table-column label="创建时间" align="center" prop="createTime" />
<el-table-column label="创建人" align="center" prop="createBy" />
<el-table-column
label="操作"
align="center"
@ -197,7 +191,7 @@
<!-- 添加护理站部门信息对话框 -->
<el-dialog
:title="title"
:visible.sync="open2"
:visible.sync="addopen"
width="800px"
append-to-body
>
@ -218,7 +212,34 @@
:rules="rules.nurseStationDepartmentList.nurseStationId"
:prop="`nurseStationDepartmentList.${index}.nurseStationId`"
>
<el-select
<el-button
type=""
v-if="item.nurseStationName == '请选择护理站名称'"
@click="clickinnerVisible(item, index)"
style="
width: 250px;
text-align: left;
height: 36px;
color: #c0c4cc;
overflow: hidden;
"
>{{ item.nurseStationName }}</el-button
>
<!-- @click="clickinnerVisible(item, index)" -->
<el-button
@click="clickinnerVisible(item, index)"
type=""
v-else
style="
width: 250px;
text-align: left;
height: 36px;
padding-left: -10px;
overflow: hidden;
"
>{{ item.nurseStationName }}</el-button
>
<!-- <el-select
v-model="item.nurseStationId"
clearable
placeholder="请选择护理站"
@ -233,7 +254,7 @@
:value="item.id"
>
</el-option>
</el-select>
</el-select> -->
</el-form-item>
<el-form-item
label="科室名称"
@ -247,7 +268,6 @@
maxlength="15"
/>
</el-form-item>
<el-form-item
label="科室负责人"
:rules="rules.nurseStationDepartmentList.departmentPerson"
@ -259,7 +279,6 @@
style="width: 250px"
/>
</el-form-item>
<el-form-item
label="联系电话"
:rules="rules.nurseStationDepartmentList.phone"
@ -280,7 +299,6 @@
@click="adddisease"
v-if="index == 0"
></el-button>
<el-button
type="danger"
icon="el-icon-delete"
@ -299,17 +317,18 @@
<!-- 修改护理站部门信息对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="100px">
<el-form-item
label="所属护理站"
prop="nurseStationId"
>
<el-select
<el-form-item label="所属护理站" prop="nurseStationId">
<el-input
v-model="form.nurseStationName"
placeholder="请选择护理站"
style="width: 250px"
disabled
/>
<!-- <el-select
v-model="form.nurseStationId"
clearable
placeholder="请选择护理站"
v-loadmore="loadMore"
style="width: 250px"
@click="nurseinfo"
disabled
>
<el-option
@ -319,14 +338,14 @@
:value="item.id"
>
</el-option>
</el-select>
</el-select> -->
</el-form-item>
<el-form-item label="科室名称" prop="departmentName">
<el-input
v-model="form.departmentName"
placeholder="请输入科室名称"
style="width: 250px"
maxlength="15"
maxlength="15"
/>
</el-form-item>
<el-form-item label="科室负责人" prop="departmentPerson">
@ -350,6 +369,125 @@
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
<!-- 新增护理站名称弹框 -->
<el-dialog
title="选择护理站"
:visible.sync="innerVisible"
width="1000px"
append-to-body
>
<el-form
ref="queryForm"
:model="nurseStationqueryParams"
:rules="rules"
label-width="80px"
:inline="true"
>
<el-form-item
label="护理站编码"
prop="nurseStationCode"
label-width="120"
>
<el-input
v-model="nurseStationqueryParams.nurseStationCode"
placeholder="请输入护理站编码"
clearable
@keyup.enter.native="addhd"
/>
</el-form-item>
<el-form-item
label="护理站名称"
prop="nurseStationName"
label-width="120"
>
<el-input
v-model="nurseStationqueryParams.nurseStationName"
placeholder="请输入护理站名称"
clearable
@keyup.enter.native="addhd"
/>
</el-form-item>
<el-form-item>
<el-button
type="primary"
icon="el-icon-search"
size="mini"
@click="addhd"
>搜索</el-button
>
<el-button icon="el-icon-refresh" size="mini" @click="addresetQuery"
>重置</el-button
>
</el-form-item>
</el-form>
<el-table :data="nurseStationlist" @cell-dblclick="nurseclick">
<el-table-column label="请选择" width="100" align="center">
<template slot-scope="scope">
<el-button
type="primary"
style="width: 15px; height: 15px"
v-if="stationid == scope.row.id"
circle
@click="nurseclick(scope.row)"
></el-button>
<el-button
v-else
style="width: 15px; height: 15px"
circle
@click="nurseclick(scope.row)"
></el-button>
</template>
</el-table-column>
<el-table-column
property="nurseStationCode"
label="护理站编码"
align="center"
>
</el-table-column>
<el-table-column
property="nurseStationName"
label="护理站名称"
align="center"
:show-overflow-tooltip="true"
>
</el-table-column>
<!-- <el-table-column
label="护理站类型"
align="center"
prop="nurseStationType"
>
<template slot-scope="scope">
{{
scope.row.nurseStationType == "LX202209140018" ? "生活护理" : ""
}}
{{
scope.row.nurseStationType == "LX202209140019" ? "医疗护理" : ""
}}
</template>
</el-table-column> -->
<el-table-column
property="phone"
label="联系电话"
align="center"
>
</el-table-column>
<el-table-column
property="address"
label="护理站地址"
align="center"
:show-overflow-tooltip="true"
>
</el-table-column>
</el-table>
<pagination
v-show="total2 > 0"
:total="total2"
:page.sync="nurseStationqueryParams.pageNum"
:limit.sync="nurseStationqueryParams.pageSize"
@pagination="info"
/>
</el-dialog>
</div>
</template>
<script>
@ -359,7 +497,6 @@ import {
delStationDepartment,
addStationDepartment,
updateStationDepartment,
list,
} from "@/api/system/StationDepartment";
import { getListByUser } from "@/api/system/userlist.js";
@ -391,14 +528,13 @@ export default {
//
total: 0,
total2: 0,
//
StationDepartmentList: [],
//
title: "",
//
open: false,
open2: false,
addopen: false,
//
queryParams: {
pageNum: 1,
@ -450,13 +586,13 @@ export default {
},
],
phone: [
{
required: true,
validator: checkMobile,
trigger: "blur",
message: "",
},
],
{
required: true,
validator: checkMobile,
trigger: "blur",
message: "",
},
],
},
nurseStationId: [
{
@ -488,15 +624,36 @@ export default {
},
],
},
index: "",
stationid: "",
nursename: "",
innerVisible: false,
};
},
created() {
this.getList();
// this.listinfo();
this.info();
},
methods: {
// add
nurseclick(row) {
console.log(row);
this.nursename = row.nurseStationName;
this.stationid = row.id;
this.form.nurseStationId = row.id;
this.innerVisible = false;
this.form.nursename = row.nurseStationName;
this.form.nurseStationDepartmentList[this.index].nurseStationName =
row.nurseStationName;
this.form.nurseStationDepartmentList[this.index].nurseStationId = row.id;
},
//
clickinnerVisible(item, index) {
this.stationid = item.nurseStationId;
this.innerVisible = true;
this.index = index;
},
//deldisease
deldisease(index) {
this.form.nurseStationDepartmentList.splice(index, 1);
@ -509,6 +666,7 @@ export default {
departmentName: "",
departmentPerson: "",
phone: "",
nurseStationName: "请选择护理站名称",
};
if (this.form.nurseStationDepartmentList.length == 5) {
this.$message.error("最多只能5条");
@ -525,12 +683,8 @@ export default {
this.loading = false;
});
},
nurseinfo() {
this.nurseStationId = row.nurseStationId;
},
//
loadMore() {
//
loadMore() {
var a = Math.ceil(this.total2 / 10);
if (this.nurseStationlist.length + 1 >= this.total2) {
} else {
@ -547,17 +701,6 @@ export default {
}
}
},
//
listinfo() {
list(this.nurseStationqueryParams).then((res) => {
console.log(res);
// res.rows.forEach((e) => {
this.nurseStationlist = res.rows;
this.total2 = res.total;
console.log(this.nurseStationlist);
});
// });
},
/** 查询护理站部门信息列表 */
getList() {
this.loading = true;
@ -570,7 +713,7 @@ export default {
//
cancel() {
this.open = false;
this.open2 = false;
this.addopen = false;
this.reset();
},
//
@ -595,6 +738,7 @@ export default {
departmentName: "",
departmentPerson: "",
phone: "",
nurseStationName: "请选择护理站名称",
},
],
};
@ -608,19 +752,19 @@ export default {
/** 重置按钮操作 */
resetQuery() {
if (this.nurseStationlist[0].isAdmin == "1") {
this.resetForm("queryForm");
this.queryParams = {
pageNum: 1,
pageSize: 10,
nurseStationId: null,
departmentCode: null,
departmentName: null,
departmentPerson: null,
phone: null,
nurseStationName: null,
};
this.handleQuery();
}else {
this.resetForm("queryForm");
this.queryParams = {
pageNum: 1,
pageSize: 10,
nurseStationId: null,
departmentCode: null,
departmentName: null,
departmentPerson: null,
phone: null,
nurseStationName: null,
};
this.handleQuery();
} else {
console.log(1);
this.queryParams.departmentCode = null;
this.queryParams.pageSize = 10;
@ -629,12 +773,23 @@ export default {
this.handleQuery();
}
},
//
info() {
addhd() {
getListByUser(this.nurseStationqueryParams).then((res) => {
this.total2 = res.total;
this.nurseStationlist = res.rows;
});
},
addresetQuery() {
this.nurseStationqueryParams = {
pageNum: 1,
pageSize: 10,
};
this.addhd();
},
//
info() {
getListByUser(this.nurseStationqueryParams).then((res) => {
console.log(res);
if (res.rows[0].isAdmin == "1") {
console.log(true);
this.nurseStationlist = res.rows;
this.total2 = res.total;
} else {
@ -642,7 +797,6 @@ export default {
this.nurseStationlist = res.rows;
this.queryParams.nurseStationId = res.rows[0].id;
this.handleQuery();
console.log(this.queryParams)
}
});
},
@ -655,7 +809,7 @@ export default {
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open2 = true;
this.addopen = true;
// this.nurseStationName="",
this.title = "添加护理站部门信息";
},
@ -671,6 +825,7 @@ export default {
},
/** 提交按钮 */
submitForm() {
console.log(this.form);
this.$refs["form"].validate((valid) => {
if (valid) {
if (this.form.id != null) {
@ -682,7 +837,7 @@ export default {
} else {
addStationDepartment(this.form).then((response) => {
this.$modal.msgSuccess("新增成功");
this.open2 = false;
this.addopen = false;
this.getList();
});
}
@ -693,7 +848,7 @@ export default {
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal
.confirm('是否确认删除护理站部门信息的数据项?')
.confirm("是否确认删除护理站部门信息的数据项?")
.then(function () {
return delStationDepartment(ids);
})

View File

@ -8,10 +8,13 @@
v-show="showSearch"
label-width="68px"
>
<el-form-item label="护理站" prop="nurseStationId" v-if="nurseStationlist.find((e) => e.isAdmin == '1')">
<el-form-item
label="护理站"
prop="nurseStationId"
v-if="nurseStationlist.find((e) => e.isAdmin == '1')"
>
<el-select
v-model="queryParams.nurseStationId"
placeholder="请选择护理站"
v-loadmore="loadMore"
@keyup.enter.native="handleQuery"
@ -26,7 +29,7 @@
</el-select>
</el-form-item>
<el-form-item label="护理站" prop="nurseStationId" v-else>
<el-form-item label="护理站" prop="nurseStationId" v-else>
<el-select
v-model="queryParams.nurseStationId"
placeholder="请选择护理站"
@ -41,7 +44,11 @@
</el-option>
</el-select>
</el-form-item>
<el-form-item label="所属科室" prop="departmentName" style="margin-left:25px">
<el-form-item
label="所属科室"
prop="departmentName"
style="margin-left: 25px"
>
<el-input
v-model="queryParams.departmentName"
placeholder="请输入所属科室"
@ -52,7 +59,7 @@
<el-form-item label="姓名" prop="nursePersonName">
<el-input
v-model="queryParams.nursePersonName"
placeholder="请输入居住地址"
placeholder="请输入姓名"
clearable
@keyup.enter.native="handleQuery"
/>
@ -159,7 +166,12 @@
</el-table-column>
<el-table-column label="联系电话" align="center" prop="phone" />
<el-table-column label="居住地址" align="center" prop="address" :show-overflow-tooltip="true"/>
<el-table-column
label="居住地址"
align="center"
prop="address"
:show-overflow-tooltip="true"
/>
<el-table-column label="创建人" align="center" prop="createBy" />
<el-table-column label="创建时间" align="center" prop="createTime" />
@ -223,7 +235,6 @@
:prop="`nurseStationPersonList.${index}.nurseStationId`"
>
<el-button
type=""
@click="clickinnerVisible(item, index)"
v-if="item.nurseStationName == '请选择护理站名称'"
@ -237,7 +248,6 @@
>{{ item.nurseStationName }}</el-button
>
<el-button
type=""
@click="clickinnerVisible(item, index)"
v-else
@ -387,7 +397,6 @@
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
<!-- 新增护理站名称弹框 -->
<el-dialog
:title="title2"
@ -397,7 +406,7 @@
>
<el-form
ref="queryForm"
:model="queryParams2"
:model="nurseStationqueryParams"
:rules="rules"
label-width="80px"
:inline="true"
@ -416,7 +425,7 @@
label-width="120"
>
<el-input
v-model="queryParams2.nurseStationCode"
v-model="nurseStationqueryParams.nurseStationCode"
placeholder="请输入护理站编码"
clearable
@keyup.enter.native="handleQuery"
@ -428,7 +437,7 @@
label-width="120"
>
<el-input
v-model="queryParams2.nurseStationName"
v-model="nurseStationqueryParams.nurseStationName"
placeholder="请输入护理站名称"
clearable
@keyup.enter.native="handleQuery"
@ -447,8 +456,8 @@
>
</el-form-item>
</el-form>
<el-table :data="stationLists" @cell-dblclick="nurseclick">
<el-table-column label="请选择" width="70" align="center">
<el-table :data="nurseStationlist" @cell-dblclick="nurseclick">
<el-table-column label="请选择" width="100" align="center">
<template slot-scope="scope">
<el-button
type="primary"
@ -468,54 +477,46 @@
<el-table-column
property="nurseStationCode"
label="护理站编码"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="nurseStationName"
label="护理站名称"
width="150"
align="center"
:show-overflow-tooltip="true"
>
</el-table-column>
<el-table-column
<!-- <el-table-column
label="护理站类型"
align="center"
prop="nurseStationType"
>
<template slot-scope="scope">
{{
scope.row.nurseStationType == "LX202209140018" ? "生活护理" : ""
scope.row.nurseStationType == "LX202211070001" ? "生活护理" : ""
}}
{{
scope.row.nurseStationType == "LX202209140019" ? "医疗护理" : ""
scope.row.nurseStationType == "LX202211070002" ? "医疗护理" : ""
}}
</template>
</el-table-column>
</el-table-column> -->
<el-table-column
property="phone"
label="联系电话"
width="150"
align="center"
>
<el-table-column property="phone" label="联系电话" align="center">
</el-table-column>
<el-table-column
property="address"
label="护理地址"
width="150"
label="护理站地址"
align="center"
:show-overflow-tooltip="true"
>
</el-table-column>
</el-table>
<pagination
v-show="total2 > 0"
:total="total2"
:page.sync="queryParams2.pageNum"
:limit.sync="queryParams2.pageSize"
v-show="total5 > 0"
:total="total5"
:page.sync="nurseStationqueryParams.pageNum"
:limit.sync="nurseStationqueryParams.pageSize"
@pagination="handleQuery2"
/>
</el-dialog>
@ -579,7 +580,7 @@
</el-form-item>
</el-form>
<el-table :data="stationLists" @cell-dblclick="nurseclick2">
<el-table-column label="请选择" width="70" align="center">
<el-table-column label="请选择" width="100" align="center">
<template slot-scope="scope">
<el-button
type="primary"
@ -599,18 +600,16 @@
<el-table-column
property="nurseStationCode"
label="护理站编码"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="nurseStationName"
label="护理站名称"
width="150"
align="center"
>
</el-table-column>
<el-table-column
<!-- <el-table-column
label="护理站类型"
align="center"
prop="nurseStationType"
@ -623,28 +622,18 @@
scope.row.nurseStationType == "LX202209140019" ? "医疗护理" : ""
}}
</template>
</el-table-column>
</el-table-column> -->
<el-table-column
property="phone"
label="联系电话"
width="150"
align="center"
>
<el-table-column property="phone" label="联系电话" align="center">
</el-table-column>
<el-table-column
property="address"
label="护理地址"
width="150"
align="center"
>
<el-table-column property="address" label="护理站地址" align="center">
</el-table-column>
</el-table>
<pagination
v-show="total2 > 0"
:total="total2"
:page.sync="queryParams2.pageNum"
:limit.sync="queryParams2.pageSize"
v-show="total5 > 0"
:total="total5"
:page.sync="nurseStationqueryParams.pageNum"
:limit.sync="nurseStationqueryParams.pageSize"
@pagination="handleQuery2"
/>
</el-dialog>
@ -695,18 +684,18 @@
:data="StationDepartmentLists"
@cell-dblclick="StationDepartmentclick"
>
<el-table-column label="请选择" width="70" align="center">
<el-table-column label="请选择" width="100" align="center">
<template slot-scope="scope">
<el-button
type="primary"
style="width: 15px; height: 15px;overflow: hidden;"
style="width: 15px; height: 15px; overflow: hidden"
v-if="departid == scope.row.departmentCode"
circle
@click="StationDepartmentclick(scope.row)"
></el-button>
<el-button
v-else
style="width: 15px; height: 15px;overflow: hidden;"
style="width: 15px; height: 15px; overflow: hidden"
circle
@click="StationDepartmentclick(scope.row)"
></el-button>
@ -715,14 +704,12 @@
<el-table-column
property="departmentCode"
label="科室编码"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="departmentName"
label="科室名称"
width="150"
align="center"
>
</el-table-column>
@ -730,16 +717,10 @@
<el-table-column
property="departmentPerson"
label="科室负责人"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="phone"
label="联系电话"
width="150"
align="center"
>
<el-table-column property="phone" label="联系电话" align="center">
</el-table-column>
</el-table>
<pagination
@ -805,7 +786,7 @@
:data="StationDepartmentLists"
@cell-dblclick="StationDepartmentclick2"
>
<el-table-column label="请选择" width="70" align="center">
<el-table-column label="请选择" width="100" align="center">
<template slot-scope="scope">
<el-button
type="primary"
@ -825,14 +806,12 @@
<el-table-column
property="departmentCode"
label="科室编码"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="departmentName"
label="科室名称"
width="150"
align="center"
>
</el-table-column>
@ -840,14 +819,12 @@
<el-table-column
property="departmentPerson"
label="科室负责人"
width="150"
align="center"
>
</el-table-column>
<el-table-column
property="phone"
label="联系电话"
width="150"
align="center"
>
</el-table-column>
@ -860,7 +837,6 @@
@pagination="handleQuery3"
/>
</el-dialog>
<!-- 修改 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="100px">
@ -871,17 +847,15 @@
style="margin-left: -20px"
>
<el-button
disabled
disabled
type=""
@click="clickinnerVisible2"
v-if="nurseStationName == '请选择护理站名称'"
style="width: 362px; text-align: left; height: 36px; color: #c0c4cc"
>{{ nurseStationName }}</el-button
>
<el-button
disabled
disabled
type=""
@click="clickinnerVisible2"
v-else
style="
width: 362px;
@ -1183,9 +1157,9 @@ export default {
trigger: "blur",
},
],
// departmentName: [
// { required: true, message: "", trigger: "blur" },
// ],
departmentName: [
{ required: true, message: "所属科室不能为空", trigger: "blur" },
],
// nurseStationId: [
// { required: true, message: "", trigger: "blur" },
// ],
@ -1261,7 +1235,6 @@ export default {
methods: {
// //
departclick(item, index) {
console.log(item);
this.departid = item.departmentCode;
this.innerVisible2 = true;
@ -1281,24 +1254,10 @@ export default {
},
//
clickinnerVisible(item, index) {
// console.log(item);
this.stationid = item.nurseStationId;
this.innerVisible = true;
this.index = index;
},
//
clickinnerVisible2() {
stationList(this.queryParams2).then((res) => {
this.stationLists = res.rows;
this.total2 = res.total;
this.loading = false;
});
// console.log(item);
this.stationid2 = this.form.nurseStationId;
this.innerVisiblexg = true;
// this.index = index;
},
//xialakuang
// loadMore() {
// console.log("1");
@ -1344,7 +1303,6 @@ export default {
address: "",
sex: "",
nurseStationId: "",
departmentName: "请选择所属科室",
// departname: "",
nurseStationName: "请选择护理站名称",
@ -1374,7 +1332,6 @@ export default {
this.nurseStationName = row.nurseStationName;
this.stationid2 = row.id;
this.form.nurseStationId = row.id;
console.log(this.form);
this.innerVisiblexg = false;
this.form.nursename = row.nurseStationName;
},
@ -1415,8 +1372,8 @@ export default {
},
getList2() {
//
this.loading = true;
stationList(this.queryParams2).then((res) => {
this.loading = true;
stationList(this.queryParams2).then((res) => {
this.stationLists = res.rows;
this.total2 = res.total;
this.loading = false;
@ -1426,7 +1383,6 @@ export default {
this.total3 = res.total;
this.loading = false;
});
},
//
cancel() {
@ -1439,7 +1395,6 @@ export default {
},
//
reset() {
this.form = {
id: null,
nurseStationId: null,
@ -1473,20 +1428,14 @@ export default {
],
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery2() {
this.queryParams.pageNum = 1;
stationList(this.queryParams2).then((res) => {
this.stationLists = res.rows;
this.total2 = res.total;
this.loading = false;
getListByUser(this.nurseStationqueryParams).then((res) => {
this.total5 = res.total;
this.nurseStationlist = res.rows;
});
this.innerVisible = true;
},
handleQuery3() {
console.log(this.queryParams3);
StationDepartmentList(this.queryParams3).then((response) => {
@ -1512,17 +1461,14 @@ export default {
},
/** 重置按钮操作 */
resetQuery2() {
this.queryParams2 = {
this.nurseStationqueryParams = {
pageNum: 1,
pageSize: 10,
nurseStationName: null,
id: null,
nurseStationId: null,
};
stationList(this.queryParams2).then((res) => {
this.stationLists = res.rows;
this.total2 = res.total;
});
this.handleQuery2();
},
resetQuery3() {
this.queryParams3 = {
@ -1543,22 +1489,21 @@ export default {
resetQuery() {
if (this.nurseStationlist[0].isAdmin == "1") {
this.resetForm("queryForm");
this.queryParams = {
pageNum: 1,
pageSize: 10,
nurseStationId: null,
departmentCode: null,
userId: null,
nursePersonCode: null,
nursePersonName: null,
nursePersonType: null,
phone: null,
address: null,
};
this.handleQuery();
} else {
this.resetForm("queryForm");
this.queryParams = {
pageNum: 1,
pageSize: 10,
nurseStationId: null,
departmentCode: null,
userId: null,
nursePersonCode: null,
nursePersonName: null,
nursePersonType: null,
phone: null,
address: null,
};
this.handleQuery();
} else {
console.log(1);
console.log(this.nurseStationlist);
this.queryParams.departmentName = null;
@ -1596,10 +1541,9 @@ export default {
this.title = "修改护理站人员信息";
if (this.departmentName == null && this.departmentName == undefined) {
this.departmentName = "请选择所属科室";
} else{
this.departmentName = response.data.departmentName;
} else {
this.departmentName = response.data.departmentName;
}
});
},
/** 提交按钮 */
@ -1608,7 +1552,6 @@ export default {
this.$refs["form"].validate((valid) => {
// this.form.nursename = null;
// this.form.nurseStationId = null;
if (valid) {
if (this.form.id != null) {
updatePerson(this.form).then((response) => {
@ -1632,7 +1575,7 @@ export default {
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal
.confirm('是否确认删除护理站人员信息的数据项?')
.confirm("是否确认删除护理站人员信息的数据项?")
.then(function () {
return delPerson(ids);
})
@ -1690,7 +1633,7 @@ export default {
`person_${new Date().getTime()}.xlsx`
);
},
//
//
info() {
getListByUser(this.nurseStationqueryParams).then((res) => {
console.log(res);

View File

@ -59,7 +59,7 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="护理站类型" prop="nurseStationName">
<!-- <el-form-item label="护理站类型" prop="nurseStationName">
<el-select
v-model="queryParams.nurseStationType"
clearable
@ -74,7 +74,7 @@
>
</el-option>
</el-select>
</el-form-item>
</el-form-item> -->
<!-- <el-form-item label="联系电话" prop="phone">
<el-input
v-model="queryParams.phone"
@ -203,13 +203,13 @@
prop="nurseStationName"
:show-overflow-tooltip="true"
/>
<el-table-column label="护理站类型" align="center" prop="nurseTypeName">
<!-- <el-table-column label="护理站类型" align="center" prop="nurseTypeName">
<template slot-scope="scope">
<el-button size="mini" type="text" @click="looktype(scope.row)"
>查看</el-button
>
</template>
</el-table-column>
</el-table-column> -->
<el-table-column label="所属区域" align="center" prop="area">
<template slot-scope="scope">
<span>{{
@ -445,7 +445,7 @@
oninput=" if(value.length>10){value=value.slice(0,20)}"
/>
</el-form-item>
<el-form-item label="护理类型" prop="nurseStationType">
<!-- <el-form-item label="护理类型" prop="nurseStationType">
<el-select
v-model="nurseStationType2"
multiple
@ -460,7 +460,7 @@
>
</el-option>
</el-select>
</el-form-item>
</el-form-item> -->
<el-form-item label="联系电话" prop="phone">
<el-input
v-model="form.phone"
@ -468,6 +468,15 @@
maxlength="11"
/>
</el-form-item>
<el-form-item label="排序" prop="sort">
<el-input
v-model="form.sort"
placeholder="排序不可输入小数点"
type="number"
min="0"
oninput="if(value.indexOf('.')>0){value=value.slice(0,value.indexOf('.')+0)} if(value.length>8){value=value.slice(0,8)}"
/>
</el-form-item>
<el-form-item label="负责人" prop="dutyPerson">
<el-input
v-model="form.dutyPerson"
@ -482,15 +491,7 @@
maxlength="11"
/>
</el-form-item>
<el-form-item label="排序" prop="sort">
<el-input
v-model="form.sort"
placeholder="排序不可输入小数点"
type="number"
min="0"
oninput="if(value.indexOf('.')>0){value=value.slice(0,value.indexOf('.')+0)} if(value.length>8){value=value.slice(0,8)}"
/>
</el-form-item>
<el-form-item label="护理站总概述" prop="nurseStationDescription">
<el-input
style="width: 208px"
@ -571,7 +572,7 @@
<el-button
size="mini"
type="text"
@click="delnurseStationLabelList(scope.$index,scope.row)"
@click="delnurseStationLabelList(scope.$index, scope.row)"
>删除</el-button
>
</template>
@ -843,20 +844,20 @@ export default {
console.log(imgUrl);
this.form.stationIntroducePcitureUrl = imgUrl;
},
delnurseStationLabelList(index,item) {
console.log(index,item);
console.log()
delnurseStationLabelList(index, item) {
console.log(index, item);
console.log();
// this.looknurseStationLabel.splice(index,1)
if(this.looknurseStationLabel.length===1){
this.looknurseStationLabel = [
{
labelDescription: "",
sort: "",
ids: 1,
},
];
}else{
this.looknurseStationLabel.splice(index,1)
if (this.looknurseStationLabel.length === 1) {
this.looknurseStationLabel = [
{
labelDescription: "",
sort: "",
ids: 1,
},
];
} else {
this.looknurseStationLabel.splice(index, 1);
}
// if (item.ids && !item.id) {
// if (this.looknurseStationLabel.length == 1) {
@ -906,14 +907,14 @@ export default {
console.log(this.looknurseStationLabel);
},
//
// looknurseStationLabelList(item) {
// console.log(item);
// nurseStationlabel(item.id).then((res) => {
// this.looknurseStationLabel = res.rows;
// this.nurseStationLabelopen = true;
// console.log(this.looknurseStationLabel);
// });
// },
looknurseStationLabelList(item) {
console.log(item);
nurseStationlabel(item.id).then((res) => {
this.looknurseStationLabel = res.rows;
this.nurseStationLabelopen = true;
console.log(this.looknurseStationLabel);
});
},
//
looktype(item) {
// console.log(item);

View File

@ -230,9 +230,9 @@
:before-close="cancel"
>
<el-form ref="form" :model="form" :rules="rules" label-width="100px">
<el-form-item label="所属护理站" >
<el-form-item label="所属护理站">
<el-button
disabled
disabled
style="width: 360px; text-align: left; height: 36px; color: #c0c4cc"
@click="open3 = true"
v-if="form.nurseStationName == '请选择所属护理站'"
@ -240,7 +240,7 @@
{{ form.nurseStationName }}
</el-button>
<el-button
disabled
disabled
style="width: 360px; text-align: left; height: 36px"
@click="open3 = true"
>
@ -462,7 +462,7 @@
:before-close="cancel2"
>
<el-form
:model="nurseStationqueryParams"
:model="getListByUserquery"
ref="queryForm"
size="small"
:inline="true"
@ -471,7 +471,7 @@
<el-form-item label="护理站名称">
<el-input
style="width: 180px"
v-model="nurseStationqueryParams.nurseStationName"
v-model="getListByUserquery.nurseStationName"
placeholder="请输入项目名称"
clearable
@keyup.enter.native="handleQuery2"
@ -480,7 +480,7 @@
<el-form-item label="护理站编号">
<el-input
style="width: 180px"
v-model="nurseStationqueryParams.nurseStationCode"
v-model="getListByUserquery.nurseStationCode"
placeholder="请输入护理站编号"
clearable
@keyup.enter.native="handleQuery2"
@ -501,7 +501,7 @@
</el-form>
<el-table
v-loading="loading"
:data="nurseStationlist2"
:data="nurseStationlist"
@cell-dblclick="clicknurseStation2"
>
<el-table-column width="60" align="center" label="请选择">
@ -546,11 +546,11 @@
</el-table>
<pagination
v-show="total2 > 0"
:total="total2"
:page.sync="nurseStationqueryParams.pageNum"
:limit.sync="nurseStationqueryParams.pageSize"
@pagination="listinfo"
v-show="total3 > 0"
:total="total3"
:page.sync="getListByUserquery.pageNum"
:limit.sync="getListByUserquery.pageSize"
@pagination="info"
/>
</el-dialog>
<!-- add// -->
@ -562,7 +562,7 @@
:before-close="cancel2"
>
<el-form
:model="nurseStationqueryParams"
:model="getListByUserquery"
ref="queryForm"
size="small"
:inline="true"
@ -571,7 +571,7 @@
<el-form-item label="护理站名称" prop="nurseStationName">
<el-input
style="width: 180px"
v-model="nurseStationqueryParams.nurseStationName"
v-model="getListByUserquery.nurseStationName"
placeholder="请输入项目名称"
clearable
@keyup.enter.native="handleQuery2"
@ -580,7 +580,7 @@
<el-form-item label="护理站编号" prop="nurseStationCode">
<el-input
style="width: 180px"
v-model="nurseStationqueryParams.nurseStationCode"
v-model="getListByUserquery.nurseStationCode"
placeholder="请输入护理站编号"
clearable
@keyup.enter.native="handleQuery2"
@ -601,7 +601,7 @@
</el-form>
<el-table
v-loading="loading"
:data="nurseStationlist2"
:data="nurseStationlist"
@cell-dblclick="clicknurseStation"
>
<el-table-column width="60" align="center" label="请选择">
@ -650,11 +650,11 @@
</el-table>
<pagination
v-show="total2 > 0"
:total="total2"
:page.sync="nurseStationqueryParams.pageNum"
:limit.sync="nurseStationqueryParams.pageSize"
@pagination="listinfo"
v-show="total3 > 0"
:total="total3"
:page.sync="getListByUserquery.pageNum"
:limit.sync="getListByUserquery.pageSize"
@pagination="info"
/>
</el-dialog>
<!-- // -->
@ -870,7 +870,7 @@ export default {
created() {
this.getList();
this.info();
this.listinfo();
// this.listinfo();
},
methods: {
/** 下载模板操作 */
@ -892,8 +892,8 @@ export default {
this.$refs.upload.clearFiles();
this.$alert(
"<div style='overflow: auto;overflow-x: hidden;max-height: 70vh;padding: 10px 20px 0;'>" +
response.msg +
"</div>",
response.msg +
"</div>",
"导入结果",
{ dangerouslyUseHTMLString: true }
);
@ -961,15 +961,10 @@ export default {
this.open2 = false;
this.open3 = false;
this.reset2();
list(this.nurseStationqueryParams).then((res) => {
console.log(res);
this.nurseStationlist = res.rows;
this.total2 = res.total;
});
},
//
reset2() {
this.nurseStationqueryParams = {
this.getListByUserquery = {
pageNum: 1,
pageSize: 10,
areaCode: null,
@ -1022,18 +1017,18 @@ export default {
this.listStationConsumableinfo();
},
//
listinfo() {
list(this.nurseStationqueryParams).then((res) => {
this.nurseStationlist2 = res.rows;
console.log(this.nurseStationlist2);
this.total2 = res.total;
});
},
// listinfo() {
// list(this.nurseStationqueryParams).then((res) => {
// this.nurseStationlist2 = res.rows;
// console.log(this.nurseStationlist2);
// this.total2 = res.total;
// });
// },
//
handleQuery2() {
console.log(this.nurseStationqueryParams);
this.nurseStationqueryParams.pageNum = 1;
this.listinfo();
this.info();
},
/** 重置按钮操作 */
sresetQuery() {
@ -1124,7 +1119,7 @@ export default {
this.getList();
this.$modal.msgSuccess("删除成功");
})
.catch(() => { });
.catch(() => {});
},
/** 导出按钮操作 */
handleExport() {
@ -1141,7 +1136,6 @@ export default {
this.upload.title = "护理站耗材导入";
this.upload.open = true;
},
//
info() {
getListByUser(this.getListByUserquery).then((res) => {

View File

@ -95,7 +95,6 @@
>
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
@ -147,7 +146,6 @@
@queryTable="getList"
></right-toolbar>
</el-row>
<el-table
v-loading="loading"
:data="nurseItemList"
@ -204,16 +202,8 @@
align="center"
prop="advanceAppointDuration"
/>
<el-table-column
label="创建时间"
align="center"
prop="createTime"
/>
<el-table-column
label="创建人"
align="center"
prop="createBy"
/>
<el-table-column label="创建时间" align="center" prop="createTime" />
<el-table-column label="创建人" align="center" prop="createBy" />
<!-- <el-table-column label="排序" align="center" prop="sort" /> -->
<el-table-column
@ -248,7 +238,6 @@
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<!-- 添加或修改护理站护理项目对话框 -->
<el-dialog
:title="title"
@ -309,7 +298,7 @@
maxlength="50"
/>
</el-form-item>
<el-form-item label="护理类型" prop="nurseTypeId">
<!-- <el-form-item label="护理类型" prop="nurseTypeId">
<el-select
v-model="form.nurseTypeId"
clearable
@ -324,7 +313,7 @@
>
</el-option>
</el-select>
</el-form-item>
</el-form-item> -->
<el-form-item
label="提前预约时长"
prop="nurseStationItem.advanceAppointDuration"
@ -336,6 +325,14 @@
min="0"
/>
</el-form-item>
<el-form-item label="项目头像" prop="nurseStationItem.itemPictureUrl">
<stationAcatar
style="width: 208px"
@imgUrl="imgUrl"
:img="form.nurseStationItem.itemPictureUrl"
:type="'itemPictureUrl'"
/>
</el-form-item>
<el-form-item label="排序" prop="nurseStationItem.sort">
<el-input
v-model="form.nurseStationItem.sort"
@ -363,12 +360,11 @@
<el-table
ref="nurseStationItemPrices"
:data="form.nurseStationItemPrices"
style="margin-top: 20px; width: 100%"
style="margin-top: 20px; width: 900px"
>
<el-table-column
property="serveDurationUnit"
label="服务时长和单位"
width="145"
align="center"
>
<template slot-scope="scope">
@ -379,12 +375,7 @@
</template>
</el-table-column>
<el-table-column
property="price"
label="价格"
width="166"
align="center"
>
<el-table-column property="price" label="价格" align="center">
<template slot-scope="scope">
<el-input
v-model="scope.row.price"
@ -394,12 +385,7 @@
></el-input>
</template>
</el-table-column>
<el-table-column
property="description"
label="描述"
width="140"
align="center"
>
<el-table-column property="description" label="描述" align="center">
<template slot-scope="scope">
<el-input
v-model="scope.row.description"
@ -407,7 +393,7 @@
></el-input>
</template>
</el-table-column>
<el-table-column label="操作" align="center" width="105">
<el-table-column label="操作" align="center">
<template slot-scope="scope">
<el-button
size="mini"
@ -425,13 +411,7 @@
</el-table-column>
</el-table>
</el-form-item>
<el-form-item label="项目头像" prop="nurseStationItem.itemPictureUrl">
<stationAcatar
@imgUrl="imgUrl"
:img="form.nurseStationItem.itemPictureUrl"
:type="'itemPictureUrl'"
/>
</el-form-item>
<el-form-item label="护理项目耗材" required>
<el-button
type="primary"
@ -443,7 +423,7 @@
<el-table
ref="singleTable"
:data="form.nurseStationItemConsumables"
style="margin-top: 20px; width: 850px"
style="margin-top: 20px; width: 900px"
>
<el-table-column
property="nurseStationConsumableId"
@ -546,7 +526,7 @@
</el-form>
<el-table
v-loading="loading"
:data="nurseStationlist2"
:data="nurseStationlist"
@cell-dblclick="choicestationid"
>
<el-table-column label="请选择" width="70" align="center">
@ -568,37 +548,37 @@
</el-button>
</template>
</el-table-column>
<el-table-column label="所属区域编码" align="center" prop="areaCode" />
<el-table-column
label="护理站编号"
property="nurseStationCode"
label="护理站编码"
align="center"
prop="nurseStationCode"
/>
>
</el-table-column>
<el-table-column
property="nurseStationName"
label="护理站名称"
align="center"
prop="nurseStationName"
/>
>
</el-table-column>
<el-table-column property="phone" label="联系电话" align="center">
</el-table-column>
<el-table-column
label="护理类型"
property="address"
label="护理站地址"
align="center"
prop="nurseStationType"
/>
<el-table-column label="联系电话" align="center" prop="phone" />
<el-table-column label="护理站地址" align="center" prop="address" />
<el-table-column label="负责人" align="center" prop="dutyPerson" />
<el-table-column label="负责人电话" align="center" prop="dutyPhone" />
:show-overflow-tooltip="true"
>
</el-table-column>
</el-table>
<pagination
v-show="total2 > 0"
:total="total2"
:page.sync="nurseStationqueryParams.pageNum"
:limit.sync="nurseStationqueryParams.pageSize"
v-show="total4 > 0"
:total="total4"
:page.sync="getListByUserquery.pageNum"
:limit.sync="getListByUserquery.pageSize"
@pagination="stationlist"
/>
</el-dialog>
<!-- 耗材弹框 -->
<el-dialog
title="添加护理项目耗材"
@ -709,7 +689,6 @@
@pagination="listStationConsumable"
/>
</el-dialog>
<!-- // -->
<el-dialog
:title="upload.title"
@ -871,9 +850,13 @@ export default {
"nurseStationItem.advanceAppointDuration": [
{ required: true, message: "提前预约时长不能为空", trigger: "blur" },
],
"nurseStationItem.itemPictureUrl":[{
required: true, trigger: "blur", message: "请选择项目头像"
}],
"nurseStationItem.itemPictureUrl": [
{
required: true,
trigger: "blur",
message: "请选择项目头像",
},
],
nurseStationId: [
{ required: true, trigger: "blur", message: "请选择所属护理站" },
],
@ -995,9 +978,9 @@ export default {
},
//
stationlist() {
liststation(this.nurseStationqueryParams).then((res) => {
this.nurseStationlist2 = res.rows;
this.total2 = res.total;
getListByUser(this.getListByUserquery).then((res) => {
this.total4 = res.total;
this.nurseStationlist = res.rows;
});
},
//

View File

@ -364,10 +364,10 @@
</el-row>
<el-row>
<el-col :span="12">
<!-- multiple -->
<el-form-item label="护理站" prop="nurseStationIds">
<el-select
v-model="form.nurseStationIds"
multiple
placeholder="请选择护理站"
v-loadmore="loadMore"
>
@ -797,17 +797,18 @@ export default {
const userId = row.userId || this.ids;
getUser(userId).then((response) => {
this.form = response.data;
if (
!this.form.nurseStationIds ||
this.form.nurseStationIds == null ||
this.form.nurseStationIds.length == 0
) {
} else {
this.form.nurseStationIds = this.form.nurseStationIds.split(",");
this.form.nurseStationIds = this.form.nurseStationIds.map((e) => {
return (e = Number(e));
});
}
this.form.nurseStationIds = Number(this.form.nurseStationIds);
// if (
// !this.form.nurseStationIds ||
// this.form.nurseStationIds == null ||
// this.form.nurseStationIds.length == 0
// ) {
// } else {
// this.form.nurseStationIds = this.form.nurseStationIds.split(",");
// this.form.nurseStationIds = this.form.nurseStationIds.map((e) => {
// return (e = Number(e));
// });
// }
console.log(this.form);
this.postOptions = response.posts;
@ -845,7 +846,13 @@ export default {
console.log(this.form);
this.$refs["form"].validate((valid) => {
if (valid) {
this.form.nurseStationIds = this.form.nurseStationIds.join(",");
// this.form.nurseStationIds = this.form.nurseStationIds.join(",");
// this.form.nurseStationIds = JSON.stringify(this.form.nurseStationIds);
// var obj = [];
// obj.push(this.form.nurseStationIds);
// console.log(obj)
// this.form.nurseStationIds = obj;
console.log(this.form);
if (this.form.userId != undefined) {
updateUser(this.form).then((response) => {
this.$modal.msgSuccess("修改成功");