|
@@ -0,0 +1,139 @@
|
|
|
+<template>
|
|
|
+ <div class="layout_container">
|
|
|
+ <div class="round-header">
|
|
|
+ <el-radio-group
|
|
|
+ v-model="patStatus"
|
|
|
+ @change="handleStatusChange"
|
|
|
+ >
|
|
|
+ <el-radio name="OUT_HOSPITAL" value="OUT_HOSPITAL" label="出院患者" />
|
|
|
+ <el-radio name="IN_HOSPITAL" value="IN_HOSPITAL" label="在院患者" />
|
|
|
+ </el-radio-group>
|
|
|
+ <el-input
|
|
|
+ v-model="userInput"
|
|
|
+ placeholder="请输入住院号或姓名"
|
|
|
+ style="width: 130px;margin-left: 60px"
|
|
|
+ clearable
|
|
|
+ @keyup.enter="searchPatient"
|
|
|
+ />
|
|
|
+ <el-button type="primary" icon="Search" @click="searchPatient">检索</el-button>
|
|
|
+ </div>
|
|
|
+ <div style="height: 8px"></div>
|
|
|
+ <div class="layout_main layout_el-table">
|
|
|
+ <el-table :data="patList" stripe>
|
|
|
+ <el-table-column prop="patNo" label="住院号" width="100"/>
|
|
|
+ <el-table-column prop="times" label="住院次数" width="100"/>
|
|
|
+ <el-table-column prop="name" label="姓名" width="100"/>
|
|
|
+ <el-table-column prop="medTypeName" label="医保身份" width="130"/>
|
|
|
+ <el-table-column prop="bedNo" label="床位号" width="80"/>
|
|
|
+ <el-table-column prop="admDate" label="入院时间" width="160"/>
|
|
|
+ <el-table-column prop="disDate" label="出院时间" width="160"/>
|
|
|
+ <el-table-column prop="wardName" label="病区" />
|
|
|
+ <el-table-column prop="deptName" label="小科室" />
|
|
|
+ <el-table-column label="操作">
|
|
|
+ <template #default="{row}">
|
|
|
+ <el-button
|
|
|
+ v-if="patStatus === 'IN_HOSPITAL'"
|
|
|
+ type="primary"
|
|
|
+ plain
|
|
|
+ @click="beforeKickOut(row)"
|
|
|
+ >
|
|
|
+ 踢出
|
|
|
+ </el-button>
|
|
|
+ <el-button
|
|
|
+ v-else
|
|
|
+ color="purple"
|
|
|
+ plain
|
|
|
+ @click="beforePullBack(row)"
|
|
|
+ >
|
|
|
+ 召回
|
|
|
+ </el-button>
|
|
|
+ <el-button
|
|
|
+ type="danger"
|
|
|
+ plain
|
|
|
+ @click="beforeRevokeSettle(row)"
|
|
|
+ >
|
|
|
+ 取消结算
|
|
|
+ </el-button>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ </el-table>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+</template>
|
|
|
+
|
|
|
+<script setup>
|
|
|
+
|
|
|
+import {checkKickOutCondition, getActpatient, kickOut, pullBack, revokeSettlement} from "@/api/inpatient/force-in-and-out.js";
|
|
|
+import {ElMessageBox} from "element-plus";
|
|
|
+import {xcMessage} from "@/utils/xiaochan-element-plus";
|
|
|
+
|
|
|
+const patStatus = ref('OUT_HOSPITAL');
|
|
|
+const userInput = ref('')
|
|
|
+
|
|
|
+const patList = ref([])
|
|
|
+
|
|
|
+function searchPatient() {
|
|
|
+ const params = {
|
|
|
+ patStatus: patStatus.value,
|
|
|
+ userInput: userInput.value,
|
|
|
+ }
|
|
|
+ getActpatient(params).then(res => {
|
|
|
+ patList.value = res
|
|
|
+ })
|
|
|
+}
|
|
|
+
|
|
|
+function handleStatusChange() {
|
|
|
+ patList.value = []
|
|
|
+}
|
|
|
+
|
|
|
+function beforePullBack(row) {
|
|
|
+ ElMessageBox.confirm('是否确定召回此患者?', '提示', {
|
|
|
+ type: 'warning',
|
|
|
+ }).then(() => {
|
|
|
+ pullBack(row).then(res => {
|
|
|
+ xcMessage.success(res)
|
|
|
+ searchPatient()
|
|
|
+ })
|
|
|
+ }).catch(() => {})
|
|
|
+}
|
|
|
+
|
|
|
+function beforeKickOut(row) {
|
|
|
+ ElMessageBox.confirm('是否确定为此患者办理出院?', '提示', {
|
|
|
+ type: 'warning',
|
|
|
+ }).then(() => {
|
|
|
+ checkCondition(row)
|
|
|
+ }).catch(() => {})
|
|
|
+}
|
|
|
+
|
|
|
+function checkCondition(row) {
|
|
|
+ checkKickOutCondition(row).then(res => {
|
|
|
+ if (res === 'OK') {
|
|
|
+ doKickOut(row)
|
|
|
+ } else {
|
|
|
+ ElMessageBox.confirm(res, '提示', {
|
|
|
+ type: 'warning',
|
|
|
+ }).then(() => {
|
|
|
+ doKickOut(row)
|
|
|
+ }).catch(() => {})
|
|
|
+ }
|
|
|
+ })
|
|
|
+}
|
|
|
+
|
|
|
+function doKickOut(row) {
|
|
|
+ kickOut(row).then(res => {
|
|
|
+ xcMessage.success(res)
|
|
|
+ searchPatient()
|
|
|
+ })
|
|
|
+}
|
|
|
+
|
|
|
+function beforeRevokeSettle(row) {
|
|
|
+ ElMessageBox.confirm('是否确定取消结算?', '提示', {
|
|
|
+ type: 'warning',
|
|
|
+ }).then(() => {
|
|
|
+ revokeSettlement(row).then(res => {
|
|
|
+ xcMessage.success(res)
|
|
|
+ })
|
|
|
+ }).catch(() => {})
|
|
|
+}
|
|
|
+
|
|
|
+</script>
|