Fix Bug 505505 【业务逻辑缺陷】药品医嘱已由药房发药,护士仍能在“医嘱校对”模块执行“退回”操作
[门诊手术安排]“手术申请查询”弹窗底部,分页组件与界底部元素重叠,影响操作。
This commit is contained in:
@@ -178,9 +178,7 @@ public class AdviceProcessAppServiceImpl implements IAdviceProcessAppService {
|
|||||||
inpatientAdviceParam.setEncounterIds(null);
|
inpatientAdviceParam.setEncounterIds(null);
|
||||||
Integer exeStatus = inpatientAdviceParam.getExeStatus();
|
Integer exeStatus = inpatientAdviceParam.getExeStatus();
|
||||||
inpatientAdviceParam.setExeStatus(null);
|
inpatientAdviceParam.setExeStatus(null);
|
||||||
// requestStatus由前端tab控制,需在后端过滤
|
// requestStatus由前端tab传入,通过QueryWrapper自动添加到SQL外层WHERE过滤
|
||||||
Integer requestStatus = inpatientAdviceParam.getRequestStatus();
|
|
||||||
inpatientAdviceParam.setRequestStatus(null);
|
|
||||||
// 构建查询条件
|
// 构建查询条件
|
||||||
QueryWrapper<InpatientAdviceParam> queryWrapper
|
QueryWrapper<InpatientAdviceParam> queryWrapper
|
||||||
= HisQueryUtils.buildQueryWrapper(inpatientAdviceParam, null, null, null);
|
= HisQueryUtils.buildQueryWrapper(inpatientAdviceParam, null, null, null);
|
||||||
@@ -293,16 +291,6 @@ public class AdviceProcessAppServiceImpl implements IAdviceProcessAppService {
|
|||||||
inpatientAdvicePage.setTotal(filteredList.size());
|
inpatientAdvicePage.setTotal(filteredList.size());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 按请求状态(tab切换)过滤医嘱
|
|
||||||
if (requestStatus != null) {
|
|
||||||
List<InpatientAdviceDto> statusFilteredList = inpatientAdvicePage.getRecords().stream()
|
|
||||||
.filter(advice -> requestStatus.equals(advice.getRequestStatus()))
|
|
||||||
.collect(Collectors.toList());
|
|
||||||
inpatientAdvicePage.setRecords(statusFilteredList);
|
|
||||||
inpatientAdvicePage.setTotal(statusFilteredList.size());
|
|
||||||
}
|
|
||||||
|
|
||||||
return R.ok(inpatientAdvicePage);
|
return R.ok(inpatientAdvicePage);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -379,7 +367,7 @@ public class AdviceProcessAppServiceImpl implements IAdviceProcessAppService {
|
|||||||
.in(MedicationDispense::getMedReqId, medReqIds)
|
.in(MedicationDispense::getMedReqId, medReqIds)
|
||||||
.eq(MedicationDispense::getStatusEnum, DispenseStatus.COMPLETED.getValue()));
|
.eq(MedicationDispense::getStatusEnum, DispenseStatus.COMPLETED.getValue()));
|
||||||
if (!dispenseList.isEmpty()) {
|
if (!dispenseList.isEmpty()) {
|
||||||
return R.fail("该医嘱已发药,无法退回");
|
return R.fail("该药品已由药房发放,请先执行退药处理,不可直接退回");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Long practitionerId = SecurityUtils.getLoginUser().getPractitionerId();
|
Long practitionerId = SecurityUtils.getLoginUser().getPractitionerId();
|
||||||
|
|||||||
@@ -23,7 +23,7 @@
|
|||||||
<span class="descriptions-item-label">全选:</span>
|
<span class="descriptions-item-label">全选:</span>
|
||||||
<el-switch v-model="chooseAll" @change="handelSwitchChange" />
|
<el-switch v-model="chooseAll" @change="handelSwitchChange" />
|
||||||
<el-button class="ml20" type="primary" @click="handleCheck"> 核对通过 </el-button>
|
<el-button class="ml20" type="primary" @click="handleCheck"> 核对通过 </el-button>
|
||||||
<el-button class="ml20 mr20" type="danger" @click="handleCancel"> 退回 </el-button>
|
<el-button class="ml20 mr20" type="danger" :disabled="hasDispensedSelected" @click="handleCancel"> 退回 </el-button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div
|
<div
|
||||||
@@ -152,6 +152,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script setup>
|
<script setup>
|
||||||
|
import {ref, computed} from 'vue';
|
||||||
import {adviceVerify, cancel, getPrescriptionList} from './api';
|
import {adviceVerify, cancel, getPrescriptionList} from './api';
|
||||||
import {patientInfoList} from '../../components/store/patient.js';
|
import {patientInfoList} from '../../components/store/patient.js';
|
||||||
import {formatDateStr} from '@/utils/index';
|
import {formatDateStr} from '@/utils/index';
|
||||||
@@ -163,6 +164,11 @@ const type = ref(null);
|
|||||||
const { proxy } = getCurrentInstance();
|
const { proxy } = getCurrentInstance();
|
||||||
const loading = ref(false);
|
const loading = ref(false);
|
||||||
const chooseAll = ref(false);
|
const chooseAll = ref(false);
|
||||||
|
const selectionTrigger = ref(0);
|
||||||
|
const hasDispensedSelected = computed(() => {
|
||||||
|
selectionTrigger.value;
|
||||||
|
return getSelectRows().some(item => item.dispenseStatus === 4);
|
||||||
|
});
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
requestStatus: {
|
requestStatus: {
|
||||||
type: Number,
|
type: Number,
|
||||||
@@ -262,7 +268,9 @@ function getGroupMarkers() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 选择框改变时的处理
|
// 选择框改变时的处理
|
||||||
function handleSelectionChange(selection, row) {}
|
function handleSelectionChange(selection, row) {
|
||||||
|
selectionTrigger.value++;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 核对通过
|
* 核对通过
|
||||||
@@ -291,7 +299,7 @@ function handleCancel() {
|
|||||||
// 校验已发药的医嘱不允许退回
|
// 校验已发药的医嘱不允许退回
|
||||||
let dispensedItems = list.filter(item => item.dispenseStatus === 4);
|
let dispensedItems = list.filter(item => item.dispenseStatus === 4);
|
||||||
if (dispensedItems.length > 0) {
|
if (dispensedItems.length > 0) {
|
||||||
proxy.$message.error('该医嘱已发药,无法退回');
|
proxy.$message.error('该药品已由药房发放,请先执行退药处理,不可直接退回');
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
cancel(list).then((res) => {
|
cancel(list).then((res) => {
|
||||||
@@ -310,12 +318,16 @@ function getSelectRows() {
|
|||||||
// 获取选中的医嘱信息
|
// 获取选中的医嘱信息
|
||||||
let list = [];
|
let list = [];
|
||||||
prescriptionList.value.forEach((item, index) => {
|
prescriptionList.value.forEach((item, index) => {
|
||||||
list = [...list, ...proxy.$refs['tableRef' + index][0].getSelectionRows()];
|
const ref = proxy.$refs['tableRef' + index];
|
||||||
|
if (ref && ref[0]) {
|
||||||
|
list = [...list, ...ref[0].getSelectionRows()];
|
||||||
|
}
|
||||||
});
|
});
|
||||||
return list.map((item) => {
|
return list.map((item) => {
|
||||||
return {
|
return {
|
||||||
requestId: item.requestId,
|
requestId: item.requestId,
|
||||||
requestTable: item.adviceTable,
|
requestTable: item.adviceTable,
|
||||||
|
dispenseStatus: item.dispenseStatus,
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -689,7 +689,7 @@
|
|||||||
</el-dialog>
|
</el-dialog>
|
||||||
|
|
||||||
<!-- 手术申请查询弹窗 -->
|
<!-- 手术申请查询弹窗 -->
|
||||||
<el-dialog :title="'手术申请查询'" v-model="showApplyDialog" width="1200px" @close="cancelApplyDialog" class="apply-query-dialog">
|
<el-dialog :title="'手术申请查询'" v-model="showApplyDialog" width="1200px" @close="cancelApplyDialog" class="surgery-apply-dialog">
|
||||||
<!-- 查询条件区 -->
|
<!-- 查询条件区 -->
|
||||||
<el-form :model="applyQueryParams" ref="applyQueryRef" :inline="true" class="query-form">
|
<el-form :model="applyQueryParams" ref="applyQueryRef" :inline="true" class="query-form">
|
||||||
<el-form-item label="手术单号" prop="surgeryNo">
|
<el-form-item label="手术单号" prop="surgeryNo">
|
||||||
@@ -741,16 +741,16 @@
|
|||||||
</el-form>
|
</el-form>
|
||||||
|
|
||||||
<!-- 结果表格区 -->
|
<!-- 结果表格区 -->
|
||||||
<el-table
|
<el-table
|
||||||
ref="applyTableRef"
|
ref="applyTableRef"
|
||||||
v-loading="applyLoading"
|
v-loading="applyLoading"
|
||||||
:data="applyList"
|
:data="applyList"
|
||||||
row-key="surgeryNo"
|
row-key="surgeryNo"
|
||||||
@row-click="handleApplyRowClick"
|
@row-click="handleApplyRowClick"
|
||||||
:row-class-name="tableRowClassName"
|
:row-class-name="tableRowClassName"
|
||||||
style="width: 100%"
|
style="width: 100%"
|
||||||
max-height="400"
|
max-height="340"
|
||||||
:scroll="{ y: 400 }"
|
:scroll="{ y: 340 }"
|
||||||
>
|
>
|
||||||
<el-table-column type="selection" width="55" :selectable="handleSelectable" />
|
<el-table-column type="selection" width="55" :selectable="handleSelectable" />
|
||||||
<el-table-column label="ID" align="center" width="80" fixed>
|
<el-table-column label="ID" align="center" width="80" fixed>
|
||||||
@@ -781,7 +781,7 @@
|
|||||||
</el-table>
|
</el-table>
|
||||||
|
|
||||||
<!-- 底部分页区 -->
|
<!-- 底部分页区 -->
|
||||||
<div class="pagination-container">
|
<div class="pagination-container apply-pagination" style="margin-top: 10px; padding-bottom: 20px">
|
||||||
<pagination
|
<pagination
|
||||||
v-show="applyTotal > 0"
|
v-show="applyTotal > 0"
|
||||||
:total="applyTotal"
|
:total="applyTotal"
|
||||||
@@ -792,10 +792,12 @@
|
|||||||
@pagination="getSurgicalScheduleList"
|
@pagination="getSurgicalScheduleList"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
<!-- 分页与底部操作区之间的间隔 -->
|
||||||
|
<div style="height: 48px"></div>
|
||||||
|
|
||||||
<!-- 底部操作区 -->
|
<!-- 底部操作区 -->
|
||||||
<template #footer>
|
<template #footer>
|
||||||
<div class="dialog-footer">
|
<div class="dialog-footer" style="margin-top: 24px; padding-top: 12px; border-top: 1px solid #ebeef5">
|
||||||
<el-button @click="cancelApplyDialog">取消</el-button>
|
<el-button @click="cancelApplyDialog">取消</el-button>
|
||||||
<el-button type="primary" @click="confirmApply">确认</el-button>
|
<el-button type="primary" @click="confirmApply">确认</el-button>
|
||||||
</div>
|
</div>
|
||||||
@@ -830,8 +832,8 @@
|
|||||||
</div>
|
</div>
|
||||||
<div style="padding: 10px">
|
<div style="padding: 10px">
|
||||||
<prescriptionlist :patientInfo="chargePatientInfo" ref="prescriptionRef"
|
<prescriptionlist :patientInfo="chargePatientInfo" ref="prescriptionRef"
|
||||||
:sourceBillNo="chargePatientInfo.sourceBillNo"
|
:generateSourceEnum="1"
|
||||||
:generateSourceEnum="chargePatientInfo.generateSourceEnum" />
|
:sourceBillNo="chargePatientInfo.sourceBillNo" />
|
||||||
<div class="overlay" v-if="disabled"></div>
|
<div class="overlay" v-if="disabled"></div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -2350,6 +2352,22 @@ function getRowClassName({ row, rowIndex }) {
|
|||||||
margin-left: 10px;
|
margin-left: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* 手术申请查询弹窗 — 分页与footer间距 */
|
||||||
|
.surgery-apply-dialog :deep(.el-dialog__body) {
|
||||||
|
padding-bottom: 32px;
|
||||||
|
}
|
||||||
|
.surgery-apply-dialog :deep(.el-dialog__footer) {
|
||||||
|
padding-top: 0;
|
||||||
|
}
|
||||||
|
.surgery-apply-dialog :deep(.apply-pagination) {
|
||||||
|
padding-bottom: 24px;
|
||||||
|
margin-bottom: 16px;
|
||||||
|
border-bottom: 1px solid #ebeef5;
|
||||||
|
}
|
||||||
|
.surgery-apply-dialog :deep(.apply-pagination .el-pagination) {
|
||||||
|
margin-right: 80px;
|
||||||
|
}
|
||||||
|
|
||||||
/* 选中行样式 */
|
/* 选中行样式 */
|
||||||
:deep(.el-table .selected-row) {
|
:deep(.el-table .selected-row) {
|
||||||
background-color: #ecf5ff !important;
|
background-color: #ecf5ff !important;
|
||||||
@@ -2359,21 +2377,22 @@ function getRowClassName({ row, rowIndex }) {
|
|||||||
border-bottom: 1px solid #d9ecff !important;
|
border-bottom: 1px solid #d9ecff !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* 手术申请查询弹窗 — 防止分页与底部重叠 */
|
</style>
|
||||||
:deep(.apply-query-dialog .el-dialog__body) {
|
|
||||||
max-height: 75vh;
|
<style>
|
||||||
overflow-y: auto;
|
/* 手术申请查询弹窗 — 非 scoped 确保穿透 teleport */
|
||||||
padding-bottom: 20px;
|
.surgery-apply-dialog .apply-pagination {
|
||||||
}
|
padding-bottom: 24px !important;
|
||||||
|
margin-bottom: 16px !important;
|
||||||
:deep(.apply-query-dialog .pagination-container) {
|
border-bottom: 1px solid #ebeef5 !important;
|
||||||
margin-top: 16px;
|
}
|
||||||
}
|
.surgery-apply-dialog .apply-pagination .el-pagination {
|
||||||
|
margin-right: 80px !important;
|
||||||
:deep(.apply-query-dialog .dialog-footer) {
|
}
|
||||||
margin-top: 12px;
|
.surgery-apply-dialog .el-dialog__body {
|
||||||
padding-top: 12px;
|
padding-bottom: 32px !important;
|
||||||
border-top: 1px solid #ebeef5;
|
}
|
||||||
}
|
.surgery-apply-dialog .el-dialog__footer {
|
||||||
|
padding-top: 0 !important;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
Reference in New Issue
Block a user