快速外呼页面

This commit is contained in:
zhuangyuanke 2024-12-05 09:14:53 +08:00
parent 1132cbebe6
commit 660505e05c
2 changed files with 324 additions and 0 deletions

View File

@ -0,0 +1,10 @@
import request from '@/utils/request'
// 查询导入批次列表
export function patientInfoImportBatchlist(query) {
return request({
url: '/manage/patientInfoimporttemp/list',
method: 'get',
params: query
})
}

View File

@ -0,0 +1,314 @@
<template>
<div class="app-container" ref="layout">
<div ref="topform" class="form">
<SearchFilter labelWidth="90px" :labelWidths="310" size="small" @search="handleQuery" patientUploadButtonVisible ="true"
@reset="resetQuery" @minShowCtrol="getMaxTableHeight">
<el-form-item label="导入日期" prop="" label-width="120px">
<el-date-picker v-model="createTime" type="daterange" range-separator="" start-placeholder="开始日期"
style="width: 220px" value-format="yyyy-MM-dd" end-placeholder="结束日期">
</el-date-picker>
</el-form-item>
<el-form-item label="医院" prop="">
<el-select v-model="queryParams.hospitalAgencyId" filterable placeholder="请选择医院" style="width:220px" clearable
@clear="clearhospitalAgency" @change="changehospitalAgency">
<el-option v-for="item in hospitalAgencylist" :key="item.id" :label="item.agencyName" :value="item.id">
</el-option>
</el-select>
</el-form-item>
<el-form-item label="院区" prop="">
<el-select v-model="queryParams.campusAgencyId" filterable placeholder="请选择院区" style="width:220px" clearable
@clear="clearcampusAgency" >
<el-option v-for="item in campusAgencylist" :key="item.id" :label="item.agencyName" :value="item.id">
</el-option>
</el-select>
</el-form-item>
</SearchFilter>
</div>
<!-- <div ref="mb8" class="mb8">
<el-row :gutter="10" class="">
<el-col :span="1.5">
<el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
v-hasPermi="['manage:blacklist:add']">新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button type="success" plain icon="el-icon-edit" size="mini" :disabled="single" @click="handleUpdate"
v-hasPermi="['manage:blacklist:edit']">修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button type="danger" plain icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete"
v-hasPermi="['manage:blacklist:remove']">删除</el-button>
</el-col> -->
<!-- <el-col :span="1.5">
<el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport"
v-hasPermi="['manage:blacklist:export']">导出</el-button>
</el-col> -->
<!-- <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
</div> -->
<div ref="table">
<el-table :max-height="maxTableHeight" v-loading="loading" :data="PatientInfoImportBatchlist"
@selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" />
<el-table-column label="序号" type="index" width="48" align="center" />
<el-table-column label="流水号" prop="sn" width="180" align="center" />
<el-table-column label="患者数" align="center" prop="patientCount" width="100"/>
<el-table-column label="操作人" align="center" prop="createBy" width='120' />
<el-table-column label="导入日期" align="center" prop="createTime" width="100">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.createTime, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button size="mini" type="text" @click="handleUpdate(scope.row)"
v-hasPermi="['manage:blacklist:edit']">修改</el-button>
<el-button size="mini" type="text" @click="handleDelete(scope.row)"
v-hasPermi="['manage:blacklist:remove']">删除</el-button>
</template>
</el-table-column>
</el-table>
</div>
<!-- <pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize" @pagination="getList" /> -->
<myPagination v-show="total > 0" :total="total" :pageSize="queryParams.pageSize"
:indexFromWrap="queryParams.pageNum" @updateCPage="updateCPage"></myPagination>
</div>
</template>
<script>
import { patientInfoImportBatchlist} from "@/api/manage/patientInfoImport";
import { selectAgencyList, getDepartmentList, getAgencyList } from "@/api/manage/selectAgencyList";
import SearchFilter from '../../components/SearchForm.vue'
export default {
name: "Importlist",
components: { SearchFilter },
data() {
return {
maxTableHeight: undefined,
//list
hospitalAgencylist: [],
// list
campusAgencylist: [],
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
PatientInfoImportBatchlist: [],
//
title: "",
//
open: false,
createTime:"",
//
queryParams: {
pageNum: 1,
pageSize: 10,
hospitalAgencyId: null,
importTimeStart: "",
importTimeEnd: "",
campusAgencyId: null,
},
//
form: {},
//
rules: {}
};
},
created() {
this.selectAgencyinfo();
this.getList();
},
mounted() {
this.getMaxTableHeight()
this.screenChange()
},
methods: {
//
handleRules(){
console.log('this.patientInfoImportList')
this.getList()
},
updateCPage(index, size) {
this.queryParams.pageNum = index
this.queryParams.pageSize = size
this.getList();
},
/** 查询 */
getList() {
this.loading = true;
patientInfoImportBatchlist(this.queryParams).then(response => {
this.PatientInfoImportBatchlist = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
campusAgencyId: null,
createBy: null,
createTime: null,
updateBy: null,
updateTime: null
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
if (this.createTime?.length > 0) {
this.queryParams.importTimeStart = this.createTime[0];
this.queryParams.importTimeEnd = this.createTime[1];
} else {
this.queryParams.importTimeStart = null;
this.queryParams.importTimeEnd = null;
}
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.queryParams = {
pageNum: 1,
pageSize: 10
}
this.createTime ='';
// this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length !== 1
this.multiple = !selection.length
},
/** 导出按钮操作 */
handleExport() {
this.download('manage/blacklist/export', {
...this.queryParams
}, `blacklist_${new Date().getTime()}.xlsx`)
},
//list
selectAgencyinfo() {
let query = {
agencyStatus: 'ON',
nodeType: 'HOSPITAL',
}
selectAgencyList(query).then(res => {
this.hospitalAgencylist = res.data
})
},
//
getAgencyListinfo(nodeType, id, type) {
let query = {
nodeType: nodeType,
}
if (nodeType == 'HOSPITAL') {
query.hospitalId = id
} else if (nodeType == 'CAMPUS') {
query.campusId = id
}
getAgencyList(query).then(res => {
// if (type)
console.log(nodeType );
console.log(res.data.campusList);
{
if (nodeType == 'HOSPITAL') {
this.campusAgencylist = res.data.campusList;
}
}
})
},
//
changehospitalAgency(id, type, typetwo) {
this.getAgencyListinfo('HOSPITAL', id, type)
// let query = {
// agencyStatus: 'ON',
// nodeType: 'CAMPUS',
// parentId: id,
// }
// selectAgencyList(query).then(res => {
if (type) {
if (!typetwo) {
this.form.campusAgencyId = null
}
} else {
this.queryParams.campusAgencyId = null
}
// })
},
//
changecampusAgency(id, type, typetwo) {
this.getAgencyListinfo('CAMPUS', id, type)
},
//
clearhospitalAgency(type) {
if (type) {
this.form.campusAgencyId = null
this.form.departmentId = null
this.form.wardId = null
} else {
this.queryParams.campusAgencyId = null
this.queryParams.departmentId = null
this.queryParams.wardId = null
}
},
//
clearcampusAgency(type) {
if (type) {
this.form.departmentId = null
this.form.wardId = null
this.getAgencyListinfo('HOSPITAL', this.form.hospitalAgencyId, type)
} else {
this.queryParams.departmentId = null
this.queryParams.wardId = null
this.getAgencyListinfo('HOSPITAL', this.queryParams.hospitalAgencyId)
}
},
//
getMaxTableHeight() {
const windowInnerHeight = window.innerHeight //
const layoutDiv = this.$refs.layout
const formDiv = this.$refs.topform
const mb8Div = this.$refs.mb8
this.maxTableHeight =
windowInnerHeight - 134 -
this.getBoxPadding(layoutDiv) -
this.getBoxHeight(mb8Div) -
this.getBoxHeight(formDiv)
},
// resize
screenChange() {
// resizeresize
window.addEventListener('resize', this.getMaxTableHeight, true)
//
//
// beforeDestroy
this.$once('hook:beforeDestroy', () => {
window.removeEventListener('resize', this.getMaxTableHeight, true)
})
},
}
};
</script>