Files
his/openhis-ui-vue3/src/views/medicationmanagement/statisticalManagement/diseaseDetails.vue
zhangfei 9c3e603b94 Fix Bug #443: 手术计费:点击签发耗材时异常报错
当手术计费弹窗中点击"签发"耗材时,因耗材的locationId(发放库房)为空导致后端异常。
在DoctorStationAdviceAppServiceImpl.handDevice方法中,当locationId为null时,使用登录用户的科室ID作为默认值,
与NurseBillingAppService中的处理方式保持一致。
2026-05-08 09:14:18 +08:00

229 lines
5.7 KiB
Vue
Executable File

<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryRef" :inline="true" label-width="100px">
<el-form-item label="姓名:" prop="searchKey">
<el-input
v-model="queryParams.searchKey"
placeholder="序号/姓名"
clearable
style="width: 200px"
@keyup.enter="handleQuery"
/>
</el-form-item>
<el-form-item label="就诊日期:">
<el-date-picker
v-model="approvalTime"
type="daterange"
start-placeholder="开始日期"
end-placeholder="结束日期"
style="width: 300px"
value-format="YYYY-MM-DD"
/>
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button type="primary" plain icon="Search" @click="handleQuery">查询</el-button>
</el-col>
<el-col :span="1.5">
<el-button type="warning" plain icon="CircleClose" @click="handleClear">重置</el-button>
</el-col>
<el-col :span="1.5">
<el-button type="warning" plain icon="Download" @click="handleExport">导出</el-button>
</el-col>
</el-row>
<el-table
v-loading="loading"
:data="diseaseList"
@selection-change="handleSelectionChange"
height="calc(100vh - 300px)"
>
<el-table-column type="selection" width="50" align="center" />
<el-table-column
label="序号"
align="center"
key="supplyBusno"
prop="supplyBusno"
width="100"
:show-overflow-tooltip="true"
/>
<el-table-column
label="姓名"
align="center"
key="name"
prop="name"
width="140"
:show-overflow-tooltip="true"
/>
<el-table-column
label="性别"
align="center"
key="genderEnum"
prop="genderEnum"
width="140"
:show-overflow-tooltip="true"
/>
<el-table-column
label="年龄"
align="center"
key="age"
prop="age"
width="140px"
:show-overflow-tooltip="true"
/>
<el-table-column
label="科室"
align="center"
key="locationId"
prop="locationId"
width="140"
:show-overflow-tooltip="true"
/>
<el-table-column
label="就诊时间"
align="center"
key="encounterStartTime"
prop="encounterStartTime"
:show-overflow-tooltip="true"
/>
<el-table-column
label="身份证号"
align="center"
key="idCard"
prop="idCard"
:show-overflow-tooltip="true"
/>
<el-table-column
label="电话"
align="center"
key="phone"
prop="phone"
:show-overflow-tooltip="true"
/>
<el-table-column
label="诊断"
align="center"
key="conditionId"
prop="conditionId"
:show-overflow-tooltip="true"
/>
</el-table>
<pagination
v-show="total > 0"
:total="total"
v-model:page="queryParams.pageNo"
v-model:limit="queryParams.pageSize"
@pagination="getList"
/>
</div>
</template>
<script setup name="diseaseDetails">
import {getDiseaseDetails,} from './statisticalManagent';
const { proxy } = getCurrentInstance();
const route = useRoute();
const diseaseList = ref([]);
const loading = ref(true);
const ids = ref([]);
const single = ref(true);
const multiple = ref(true);
const total = ref(0);
const approvalTime = ref([]);
const supplierListOptions = ref([]);
const locationIdList = ref([]);
const data = reactive({
form: {},
queryParams: {
pageNo: 1,
pageSize: 10,
searchKey: undefined,
busNo: undefined,
name: undefined,
medicationDefId: undefined,
department: undefined,
purposeLocationId: undefined,
categoryType: undefined,
supplierId: undefined,
occurrenceTimeSTime: undefined,
occurrenceTimeETime: undefined,
},
rules: {},
});
const { queryParams, form, rules } = toRefs(data);
function getPharmacyCabinetLists() {
getPharmacyCabinetList().then((response) => {
locationIdList.value = response.data;
});
getInboundInit().then((response) => {
supplierListOptions.value = response.data.supplierListOptions;
});
}
/** 导出按钮操作 */
function handleExport() {
proxy.$download.downloadGet(
'report-manage/inbound/excel-out',
{
...queryParams.value,
},
`dict_${new Date().getTime()}.xlsx`
);
}
/** 查询调拨管理项目列表 */
function getList() {
loading.value = true;
getDiseaseDetails(queryParams.value).then((res) => {
loading.value = false;
diseaseList.value = res.data.records;
total.value = res.data.total;
});
}
/** 搜索按钮操作 */
function handleQuery() {
queryParams.value.occurrenceTimeSTime =
approvalTime.value && approvalTime.value.length == 2 ? approvalTime.value[0] + ' 00:00:00' : '';
queryParams.value.occurrenceTimeETime =
approvalTime.value && approvalTime.value.length == 2 ? approvalTime.value[1] + ' 23:59:59' : '';
queryParams.value.pageNo = 1;
getList();
}
/** 清空条件按钮操作 */
function handleClear() {
// 清空查询条件
queryParams.value.occurrenceTimeSTime = '';
queryParams.value.occurrenceTimeETime = '';
approvalTime.value = '';
proxy.resetForm('queryRef');
getList();
}
/** 选择条数 */
function handleSelectionChange(selection) {
ids.value = selection.map((item) => item.id);
single.value = selection.length != 1;
multiple.value = !selection.length;
}
getList();
</script>
<style scoped>
.custom-tree-node {
display: flex;
align-items: center;
}
.title {
font-weight: bold;
font-size: large;
margin-bottom: 10px;
}
</style>