手术名称管理
This commit is contained in:
parent
c419276587
commit
5b09bd721d
@ -146,13 +146,41 @@
|
|||||||
<!-- 添加或修改手术信息对话框 -->
|
<!-- 添加或修改手术信息对话框 -->
|
||||||
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
|
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
|
||||||
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
|
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
|
||||||
<el-form-item label="所属科室" prop="departmentName">
|
<el-form-item label="科室名称" prop="departmentId">
|
||||||
|
<el-button
|
||||||
|
type=""
|
||||||
|
v-if="departmentName == '请选择科室'"
|
||||||
|
@click="clickinnerVisible()"
|
||||||
|
style="
|
||||||
|
width: 379px;
|
||||||
|
text-align: left;
|
||||||
|
height: 36px;
|
||||||
|
color: #c0c4cc;
|
||||||
|
overflow: hidden;
|
||||||
|
"
|
||||||
|
>{{ departmentName }}</el-button
|
||||||
|
>
|
||||||
|
<el-button
|
||||||
|
@click="clickinnerVisible()"
|
||||||
|
type=""
|
||||||
|
v-else
|
||||||
|
style="
|
||||||
|
width: 379px;
|
||||||
|
text-align: left;
|
||||||
|
height: 36px;
|
||||||
|
padding-left: -10px;
|
||||||
|
overflow: hidden;
|
||||||
|
"
|
||||||
|
>{{ departmentName }}</el-button
|
||||||
|
>
|
||||||
|
</el-form-item>
|
||||||
|
<!-- <el-form-item label="所属科室" prop="departmentName">
|
||||||
<el-input
|
<el-input
|
||||||
v-model="form.departmentName"
|
v-model="form.departmentName"
|
||||||
placeholder="请输入所属科室"
|
placeholder="请输入所属科室"
|
||||||
disabled
|
disabled
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item> -->
|
||||||
<el-form-item label="手术名称" prop="operationName">
|
<el-form-item label="手术名称" prop="operationName">
|
||||||
<el-input
|
<el-input
|
||||||
v-model="form.operationName"
|
v-model="form.operationName"
|
||||||
@ -184,36 +212,113 @@
|
|||||||
<el-button @click="cancel">取 消</el-button>
|
<el-button @click="cancel">取 消</el-button>
|
||||||
</div>
|
</div>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
|
<!-- 科室弹框 -->
|
||||||
|
<el-dialog
|
||||||
|
title=""
|
||||||
|
:visible.sync="innerVisibleshow"
|
||||||
|
width="1000px"
|
||||||
|
append-to-body
|
||||||
|
:before-close="innerVisiblecancel"
|
||||||
|
>
|
||||||
|
<el-form
|
||||||
|
ref="queryForm"
|
||||||
|
:model="informationqueryParams"
|
||||||
|
:rules="rules"
|
||||||
|
label-width="80px"
|
||||||
|
:inline="true"
|
||||||
|
>
|
||||||
|
<el-form-item label="科室名称" prop="departmentName" label-width="120">
|
||||||
|
<el-input
|
||||||
|
v-model="informationqueryParams.departmentName"
|
||||||
|
placeholder="请输入科室名称"
|
||||||
|
clearable
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item>
|
||||||
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
icon="el-icon-search"
|
||||||
|
size="mini"
|
||||||
|
@click="informationInfoinfo"
|
||||||
|
>搜索</el-button
|
||||||
|
>
|
||||||
|
<el-button
|
||||||
|
icon="el-icon-refresh"
|
||||||
|
size="mini"
|
||||||
|
@click="addresetQuerylist"
|
||||||
|
>重置</el-button
|
||||||
|
>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
|
||||||
|
<el-table
|
||||||
|
:data="infolist"
|
||||||
|
@cell-dblclick="nurseclick"
|
||||||
|
v-loading="loading"
|
||||||
|
>
|
||||||
|
<el-table-column label="请选择" width="100" align="center">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
style="width: 15px; height: 15px"
|
||||||
|
v-if="form.departmentId == scope.row.departmentCode"
|
||||||
|
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="departmentName"
|
||||||
|
label="科室名称"
|
||||||
|
align="center"
|
||||||
|
:show-overflow-tooltip="true"
|
||||||
|
>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
<pagination
|
||||||
|
v-show="totaldepartment > 0"
|
||||||
|
:total="totaldepartment"
|
||||||
|
:page.sync="informationqueryParams.pageNum"
|
||||||
|
:limit.sync="informationqueryParams.pageSize"
|
||||||
|
@pagination="informationInfoinfo"
|
||||||
|
/>
|
||||||
|
</el-dialog>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { listOperationInfo, getOperationInfo, delOperationInfo, addOperationInfo, updateOperationInfo, listOperationNum } from "@/api/operationInfo/operationInfo";
|
import { listOperationInfo, getOperationInfo, delOperationInfo, addOperationInfo, updateOperationInfo, listOperationNum } from "@/api/operationInfo/operationInfo";
|
||||||
|
import { department, listDisease } from "@/api/manage/script";
|
||||||
export default {
|
export default {
|
||||||
name: "OperationInfo",
|
name: "OperationInfo",
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
itemname: null,
|
|
||||||
disabled: false,
|
disabled: false,
|
||||||
|
itemname: null,
|
||||||
|
departmentName: null,
|
||||||
|
diseaseTypeName: null,
|
||||||
name: '',
|
name: '',
|
||||||
count: '',//全部
|
departmentId: null,
|
||||||
// 用户导入参数
|
count:'',
|
||||||
upload: {
|
|
||||||
// 是否显示弹出层(用户导入)
|
|
||||||
open: false,
|
innerVisibleshow: false, //科室弹框
|
||||||
// 弹出层标题(用户导入)
|
// 科室
|
||||||
title: "",
|
informationqueryParams: {
|
||||||
// 是否禁用上传
|
pageNum: 1,
|
||||||
isUploading: false,
|
pageSize: 10,
|
||||||
// 是否更新已经存在的用户数据
|
departmentName: null,
|
||||||
updateSupport: 0,
|
|
||||||
// 设置上传的请求头部
|
|
||||||
// headers: { Authorization: "Bearer " + getToken() },
|
|
||||||
headers: {},
|
|
||||||
// 上传的地址
|
|
||||||
url: process.env.VUE_APP_BASE_API + "/system/user/importData",
|
|
||||||
},
|
},
|
||||||
|
infolist: [],
|
||||||
|
totaldepartment: 0,
|
||||||
|
|
||||||
// 遮罩层
|
// 遮罩层
|
||||||
loading: true,
|
loading: true,
|
||||||
// 选中数组
|
// 选中数组
|
||||||
@ -268,9 +373,11 @@ export default {
|
|||||||
},
|
},
|
||||||
// 表单校验
|
// 表单校验
|
||||||
rules: {
|
rules: {
|
||||||
// departmentName: [
|
departmentId:[
|
||||||
// { required: true, message: "所属科室不能为空", trigger: "blur" }
|
{ required: true, message: "所属科室名称不能为空", trigger: "blur" }
|
||||||
// ],
|
|
||||||
|
|
||||||
|
],
|
||||||
operationName: [
|
operationName: [
|
||||||
{ required: true, message: "手术名称不能为空", trigger: "blur" }
|
{ required: true, message: "手术名称不能为空", trigger: "blur" }
|
||||||
],
|
],
|
||||||
@ -294,21 +401,74 @@ export default {
|
|||||||
// this.$refs.box.addEventListener('scroll', this.lazyLoading) // 滚动到底部,再加载的处理事件
|
// this.$refs.box.addEventListener('scroll', this.lazyLoading) // 滚动到底部,再加载的处理事件
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
// 点击科室
|
||||||
|
clickinnerVisible() {
|
||||||
|
this.innerVisibleshow = true;
|
||||||
|
if (this.itemname) {
|
||||||
|
this.informationqueryParams.departmentId = this.itemname
|
||||||
|
|
||||||
|
} else {
|
||||||
|
this.informationqueryParams.departmentId = null
|
||||||
|
}
|
||||||
|
this.informationInfoinfo();
|
||||||
|
},
|
||||||
|
// 科室列表
|
||||||
|
informationInfoinfo() {
|
||||||
|
department(this.informationqueryParams).then((response) => {
|
||||||
|
this.infolist = response.rows;
|
||||||
|
this.totaldepartment = response.total;
|
||||||
|
this.loading = false;
|
||||||
|
});
|
||||||
|
// this.informationqueryParams.page = 1;
|
||||||
|
},
|
||||||
|
// 科室名称重置
|
||||||
|
addresetQuerylist() {
|
||||||
|
this.informationqueryParams = {
|
||||||
|
pageNum: 1,
|
||||||
|
pageSize: 10,
|
||||||
|
};
|
||||||
|
this.informationInfoinfo();
|
||||||
|
},
|
||||||
|
innerVisiblecancel() {
|
||||||
|
this.innerVisibleshow = false;
|
||||||
|
},
|
||||||
|
// 科室名称圆点按钮
|
||||||
|
nurseclick(row) {
|
||||||
|
this.form.departmentId = row.departmentCode;
|
||||||
|
this.departmentName = row.departmentName;
|
||||||
|
this.form.diseaseTypeId = '';
|
||||||
|
this.diseaseTypeName = '请选择病种';
|
||||||
|
this.innerVisibleshow = false;
|
||||||
|
},
|
||||||
|
|
||||||
|
// 左侧科室
|
||||||
|
// itemdata(item) {
|
||||||
|
// if (item) {
|
||||||
|
// this.itemname = item.id
|
||||||
|
// this.form.departmentId = this.itemname
|
||||||
|
// this.form.departmentName = item.departmentName
|
||||||
|
// this.loading = true;
|
||||||
|
// this.queryParams.departmentId = this.itemname
|
||||||
|
// this.getList()
|
||||||
|
// } else {
|
||||||
|
// this.queryParams.departmentId = ''
|
||||||
|
// this.itemname = null
|
||||||
|
// this.getList()
|
||||||
|
|
||||||
|
// }
|
||||||
|
// },
|
||||||
// 左侧科室
|
// 左侧科室
|
||||||
itemdata(item) {
|
itemdata(item) {
|
||||||
if (item) {
|
if (item) {
|
||||||
this.itemname = item.id
|
this.itemname = item.id
|
||||||
this.form.departmentId = this.itemname
|
this.departmentName = item.departmentName
|
||||||
this.form.departmentName = item.departmentName
|
|
||||||
this.loading = true;
|
this.loading = true;
|
||||||
this.queryParams.departmentId = this.itemname
|
this.queryParams.departmentId = item.id
|
||||||
this.getList()
|
this.getList()
|
||||||
} else {
|
} else {
|
||||||
this.queryParams.departmentId = ''
|
this.queryParams.departmentId = ''
|
||||||
this.itemname = null
|
this.itemname = null
|
||||||
this.getList()
|
this.getList()
|
||||||
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
// 左侧科室
|
// 左侧科室
|
||||||
@ -394,19 +554,32 @@ export default {
|
|||||||
},
|
},
|
||||||
/** 新增按钮操作 */
|
/** 新增按钮操作 */
|
||||||
handleAdd() {
|
handleAdd() {
|
||||||
console.log(this.itemname)
|
// console.log(this.itemname)
|
||||||
if (!this.itemname) {
|
// if (!this.itemname) {
|
||||||
this.$modal.msgError("请先选择科室");
|
// this.$modal.msgError("请先选择科室");
|
||||||
} else {
|
// } else {
|
||||||
// this.reset();
|
// // this.reset();
|
||||||
this.form.operationName = null;
|
// this.form.operationName = null;
|
||||||
this.form.operationInfo = null;
|
// this.form.operationInfo = null;
|
||||||
this.open = true;
|
// this.open = true;
|
||||||
this.title = "添加手术信息";
|
// this.title = "添加手术信息";
|
||||||
if (this.title == "添加手术信息") {
|
// if (this.title == "添加手术信息") {
|
||||||
this.disabled = false;
|
// this.disabled = false;
|
||||||
}
|
// }
|
||||||
|
// }
|
||||||
|
this.reset();
|
||||||
|
if (this.itemname) {
|
||||||
|
this.form.departmentName = this.departmentName
|
||||||
|
this.form.departmentId = this.itemname
|
||||||
|
} else if (this.itemname == null) {
|
||||||
|
this.departmentName = "请选择科室"
|
||||||
}
|
}
|
||||||
|
else {
|
||||||
|
this.departmentName = "请选择科室"
|
||||||
|
}
|
||||||
|
|
||||||
|
this.open = true;
|
||||||
|
this.title = "添加手术信息";
|
||||||
|
|
||||||
},
|
},
|
||||||
/** 修改按钮操作 */
|
/** 修改按钮操作 */
|
||||||
@ -431,9 +604,11 @@ export default {
|
|||||||
},
|
},
|
||||||
/** 提交按钮 */
|
/** 提交按钮 */
|
||||||
submitForm() {
|
submitForm() {
|
||||||
|
console.log(this.form,'0000')
|
||||||
this.$refs["form"].validate(valid => {
|
this.$refs["form"].validate(valid => {
|
||||||
if (valid) {
|
if (valid) {
|
||||||
if (this.form.id) {
|
if (this.form.id!=null) {
|
||||||
|
this.form.departmentName = this.departmentName
|
||||||
updateOperationInfo(this.form).then(response => {
|
updateOperationInfo(this.form).then(response => {
|
||||||
this.$modal.msgSuccess("修改成功");
|
this.$modal.msgSuccess("修改成功");
|
||||||
this.open = false;
|
this.open = false;
|
||||||
@ -441,6 +616,14 @@ export default {
|
|||||||
this.Departmentlist();
|
this.Departmentlist();
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
|
if (this.itemname) {
|
||||||
|
this.form.departmentName = this.departmentName
|
||||||
|
this.form.departmentId = this.itemname
|
||||||
|
|
||||||
|
} else {
|
||||||
|
this.form.departmentName = this.departmentName
|
||||||
|
console.log(this.form,'1111')
|
||||||
|
}
|
||||||
addOperationInfo(this.form).then(response => {
|
addOperationInfo(this.form).then(response => {
|
||||||
this.$modal.msgSuccess("新增成功");
|
this.$modal.msgSuccess("新增成功");
|
||||||
this.open = false;
|
this.open = false;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user