|
@@ -24,6 +24,7 @@
|
|
|
</el-select>
|
|
|
<el-input v-model="overviewParam.bah" style="width: 110px" placeholder="住院号" clearable></el-input>
|
|
|
<el-button type="primary" icon="el-icon-search" @click="searchPatient">检索</el-button>
|
|
|
+ <el-button type="primary" icon="el-icon-check" @click="archiveBa">签收</el-button>
|
|
|
<el-button type="primary" icon="el-icon-s-operation" @click="showAdvanceSearch = true">高级条件检索</el-button>
|
|
|
<el-divider direction="vertical"></el-divider>
|
|
|
|
|
@@ -31,16 +32,11 @@
|
|
|
<el-button type="primary">功能菜单<i class="el-icon-arrow-down el-icon--right"></i> </el-button>
|
|
|
<template #dropdown>
|
|
|
<el-dropdown-menu>
|
|
|
- <el-dropdown-item icon="el-icon-printer" command="sign">签收首页</el-dropdown-item>
|
|
|
<el-dropdown-item icon="el-icon-printer" command="unSign">解除签收</el-dropdown-item>
|
|
|
- <el-dropdown-item icon="el-icon-printer" command="allLate" divided>迟交总览</el-dropdown-item>
|
|
|
- <el-dropdown-item icon="el-icon-printer" command="dismissCount">出院患者计数</el-dropdown-item>
|
|
|
- <el-dropdown-item icon="el-icon-printer" command="lend" divided>借阅标记</el-dropdown-item>
|
|
|
- <el-dropdown-item icon="el-icon-printer" command="unLend">借阅归还</el-dropdown-item>
|
|
|
+ <el-dropdown-item icon="el-icon-printer" command="dismissCount" divided>出院患者统计</el-dropdown-item>
|
|
|
<el-dropdown-item icon="el-icon-printer" command="print1" divided>打印正面</el-dropdown-item>
|
|
|
<el-dropdown-item icon="el-icon-printer" command="print2">打印反面</el-dropdown-item>
|
|
|
<el-dropdown-item icon="el-icon-printer" command="confirmPrint">确认已打印</el-dropdown-item>
|
|
|
- <el-dropdown-item icon="el-icon-printer" command="exportExcel" divided>导出Excel</el-dropdown-item>
|
|
|
</el-dropdown-menu>
|
|
|
</template>
|
|
|
</el-dropdown>
|
|
@@ -151,17 +147,55 @@
|
|
|
<el-button type="primary" icon="el-icon-arrow-right" @click="nextPage" :disabled="currentSRPage > 1 && searchResults.length < 10">下一页</el-button>
|
|
|
</div>
|
|
|
</el-dialog>
|
|
|
- <el-dialog v-model="showDismissCount" title="出院患者统计">
|
|
|
+ <el-dialog v-model="showDismissCount" title="出院患者统计" width="70%">
|
|
|
<el-date-picker v-model="dismissCountMonth" type="month" style="width: 110px" placeholder="请选择" :clearable="false"></el-date-picker>
|
|
|
+ <el-select v-model="dismissCountType" style="width: 120px" @change="dismissCountdata = []">
|
|
|
+ <el-option :value="1" label="按科室计数"></el-option>
|
|
|
+ <el-option :value="2" label="按明细计数"></el-option>
|
|
|
+ <el-option :value="3" label="死亡患者计数"></el-option>
|
|
|
+ </el-select>
|
|
|
<el-divider direction="vertical"></el-divider>
|
|
|
<el-button icon="el-icon-search" type="primary" @click="fetchDismissCount">获取统计数据</el-button>
|
|
|
<el-button icon="el-icon-download" type="primary" @click="exportDismissCount">导出Excel</el-button>
|
|
|
- <el-table :data="dismissCountdata" stripe height="300">
|
|
|
- <el-table-column prop="deptName" label="科室"></el-table-column>
|
|
|
- <el-table-column prop="dismissCount" label="出院人数"></el-table-column>
|
|
|
- <el-table-column prop="signedCount" label="已签收"></el-table-column>
|
|
|
- <el-table-column prop="unsignCount" label="未签收"></el-table-column>
|
|
|
- </el-table>
|
|
|
+ <div v-if="dismissCountType === 1">
|
|
|
+ <el-table :data="dismissCountdata" stripe height="360">
|
|
|
+ <el-table-column prop="deptName" label="科室"></el-table-column>
|
|
|
+ <el-table-column prop="dismissCount" label="出院人数"></el-table-column>
|
|
|
+ <el-table-column prop="signedCount" label="已签收"></el-table-column>
|
|
|
+ <el-table-column prop="unsignCount" label="未签收"></el-table-column>
|
|
|
+ </el-table>
|
|
|
+ </div>
|
|
|
+ <div v-else>
|
|
|
+ <el-table :data="dismissCountdata.slice((currentDismissCountPage - 1) * 10, currentDismissCountPage * 10)" stripe height="360">
|
|
|
+ <el-table-column prop="patNo" label="住院号"></el-table-column>
|
|
|
+ <el-table-column prop="times" label="住院次数"></el-table-column>
|
|
|
+ <el-table-column prop="name" label="姓名"></el-table-column>
|
|
|
+ <el-table-column prop="gender" label="性别"></el-table-column>
|
|
|
+ <el-table-column prop="age" label="年龄"></el-table-column>
|
|
|
+ <el-table-column prop="admissDate" label="入院时间"></el-table-column>
|
|
|
+ <el-table-column v-if="dismissCountType === 2" prop="disDate" label="出院时间"></el-table-column>
|
|
|
+ <el-table-column v-if="dismissCountType === 3" prop="disDate" label="死亡时间"></el-table-column>
|
|
|
+ <el-table-column prop="inHospDays" label="住院天数"></el-table-column>
|
|
|
+ <el-table-column prop="totalCharge" label="住院费用"></el-table-column>
|
|
|
+ <el-table-column prop="admissDept" label="入院科室"></el-table-column>
|
|
|
+ <el-table-column prop="disDept" label="出院科室"></el-table-column>
|
|
|
+ <el-table-column prop="zkWard" label="转科科室"></el-table-column>
|
|
|
+ <el-table-column prop="disDiag" label="出院主诊断"></el-table-column>
|
|
|
+ <el-table-column prop="blfx" label="病例分型"></el-table-column>
|
|
|
+ <el-table-column prop="kzr" label="科主任"></el-table-column>
|
|
|
+ <el-table-column prop="zzys" label="主治医师"></el-table-column>
|
|
|
+ <el-table-column prop="zyys" label="住院医师"></el-table-column>
|
|
|
+ <el-table-column prop="fdcrb" label="法定传染病"></el-table-column>
|
|
|
+ </el-table>
|
|
|
+ <el-pagination
|
|
|
+ :hide-on-single-page="false"
|
|
|
+ :page-size="10"
|
|
|
+ layout="prev, pager, next, total"
|
|
|
+ @current-change="handleCurrentDismissCountPageChange"
|
|
|
+ :total="dismissCountdata.length"
|
|
|
+ >
|
|
|
+ </el-pagination>
|
|
|
+ </div>
|
|
|
</el-dialog>
|
|
|
</el-container>
|
|
|
</template>
|
|
@@ -189,7 +223,6 @@ import femaleIcon from '@/assets/female-icon.png'
|
|
|
import { ElMessage, ElMessageBox } from 'element-plus'
|
|
|
import { shortcuts } from '@/data/shortcuts'
|
|
|
import { formatDate, getOneMonthOffset } from '@/utils/date'
|
|
|
-import router from '@/router'
|
|
|
import { initLodop, getLodop } from '@/utils/c-lodop'
|
|
|
import { formatMonth } from '@/utils/date'
|
|
|
import { createWorkSheet, writeExcelFile } from '@/utils/excel'
|
|
@@ -279,11 +312,11 @@ export default {
|
|
|
const searchContent = ref('')
|
|
|
const currentSRPage = ref(1)
|
|
|
const lastPage = () => {
|
|
|
- currentSRPage.value--
|
|
|
+ currentSRPage.value -= 1
|
|
|
fetchSearchData()
|
|
|
}
|
|
|
const nextPage = () => {
|
|
|
- currentSRPage.value++
|
|
|
+ currentSRPage.value += 1
|
|
|
fetchSearchData()
|
|
|
}
|
|
|
const fetchSearchData = () => {
|
|
@@ -313,9 +346,10 @@ export default {
|
|
|
const showDismissCount = ref(false)
|
|
|
const dismissCountdata = ref([])
|
|
|
const dismissCountMonth = ref(formatMonth(new Date()))
|
|
|
+ const dismissCountType = ref(1)
|
|
|
const fetchDismissCount = () => {
|
|
|
dismissCountMonth.value = formatMonth(dismissCountMonth.value)
|
|
|
- analyzeDismissCount(dismissCountMonth.value).then((res) => {
|
|
|
+ analyzeDismissCount(dismissCountType.value, dismissCountMonth.value).then((res) => {
|
|
|
dismissCountdata.value = res
|
|
|
})
|
|
|
}
|
|
@@ -329,35 +363,71 @@ export default {
|
|
|
})
|
|
|
return
|
|
|
}
|
|
|
- const fileName = `【${dismissCountMonth.value}】出院人数统计.xlsx`
|
|
|
- setTimeout(() => {
|
|
|
- const title = {
|
|
|
+
|
|
|
+ let name = ''
|
|
|
+ let title = {}
|
|
|
+ let fields = []
|
|
|
+ if (dismissCountType.value === 1) {
|
|
|
+ title = {
|
|
|
deptName: '科室',
|
|
|
dismissCount: '出院人数',
|
|
|
signedCount: '已签收',
|
|
|
unsignCount: '未签收',
|
|
|
}
|
|
|
- const fields = ['deptName', 'dismissCount', 'signedCount', 'unsignCount']
|
|
|
+ fields = ['deptName', 'dismissCount', 'signedCount', 'unsignCount']
|
|
|
+ name = '科室出院人数统计'
|
|
|
+ } else {
|
|
|
+ title = {
|
|
|
+ patNo: '住院号',
|
|
|
+ times: '住院次数',
|
|
|
+ name: '姓名',
|
|
|
+ gender: '性别',
|
|
|
+ age: '年龄',
|
|
|
+ admissDate: '入院时间',
|
|
|
+ admissDept: '入院科室',
|
|
|
+ zkWard: '转科科室',
|
|
|
+ disDate: dismissCountType.value === 2 ? '出院时间' : '死亡时间',
|
|
|
+ inHospDays: '住院天数',
|
|
|
+ totalCharge: '住院费用',
|
|
|
+ disDept: '出院科室',
|
|
|
+ disDiag: '出院主诊断',
|
|
|
+ blfx: '病例分型',
|
|
|
+ kzr: '科主任',
|
|
|
+ zzys: '主治医师',
|
|
|
+ zyys: '住院医师',
|
|
|
+ fdcrb: '法定传染病',
|
|
|
+ }
|
|
|
+ fields = [
|
|
|
+ 'patNo',
|
|
|
+ 'times',
|
|
|
+ 'name',
|
|
|
+ 'gender',
|
|
|
+ 'age',
|
|
|
+ 'admissDate',
|
|
|
+ 'disDate',
|
|
|
+ 'inHospDays',
|
|
|
+ 'admissDept',
|
|
|
+ 'zkWard',
|
|
|
+ 'totalCharge',
|
|
|
+ 'disDept',
|
|
|
+ 'disDiag',
|
|
|
+ 'blfx',
|
|
|
+ 'kzr',
|
|
|
+ 'zzys',
|
|
|
+ 'zyys',
|
|
|
+ 'fdcrb',
|
|
|
+ ]
|
|
|
+
|
|
|
+ name = dismissCountType.value === 2 ? '出院明细统计' : '死亡患者统计'
|
|
|
+ }
|
|
|
+ const fileName = `【${dismissCountMonth.value}】${name}.xlsx`
|
|
|
+ setTimeout(() => {
|
|
|
const workSheet = createWorkSheet(dismissCountdata.value, fields, title)
|
|
|
writeExcelFile(workSheet, fileName)
|
|
|
}, 50)
|
|
|
}
|
|
|
const handleCommand = (val) => {
|
|
|
switch (val) {
|
|
|
- case 'save':
|
|
|
- saveVerify(1)
|
|
|
- break
|
|
|
- case 'sign':
|
|
|
- archiveBa()
|
|
|
- break
|
|
|
- case 'lend':
|
|
|
- lend()
|
|
|
- break
|
|
|
- case 'unLend':
|
|
|
- lend()
|
|
|
- break
|
|
|
- case 'allLate':
|
|
|
- break
|
|
|
case 'dismissCount':
|
|
|
showDismissCount.value = true
|
|
|
break
|
|
@@ -373,8 +443,6 @@ export default {
|
|
|
case 'unSign':
|
|
|
unArchiveBa()
|
|
|
break
|
|
|
- case 'exportExcel':
|
|
|
- break
|
|
|
}
|
|
|
}
|
|
|
|
|
@@ -450,25 +518,6 @@ export default {
|
|
|
}
|
|
|
return false
|
|
|
}
|
|
|
- const saveVerify = (opType) => {
|
|
|
- if (nullPatient()) return
|
|
|
- const param = {
|
|
|
- opType,
|
|
|
- sheet: sheet.value,
|
|
|
- }
|
|
|
- executeSaveVerify(param)
|
|
|
- .then((res) => {
|
|
|
- ElMessage({
|
|
|
- message: '操作成功。',
|
|
|
- type: 'success',
|
|
|
- duration: 2500,
|
|
|
- showClose: true,
|
|
|
- })
|
|
|
- })
|
|
|
- .catch((e) => {
|
|
|
- forceVerifies.value = e.data
|
|
|
- })
|
|
|
- }
|
|
|
const beforePrint = (flag) => {
|
|
|
if (nullPatient()) return
|
|
|
const param = {
|
|
@@ -504,7 +553,22 @@ export default {
|
|
|
if (nullPatient()) {
|
|
|
return
|
|
|
}
|
|
|
- saveVerify(2)
|
|
|
+ const param = {
|
|
|
+ opType: 2,
|
|
|
+ sheet: sheet.value,
|
|
|
+ }
|
|
|
+ executeSaveVerify(param)
|
|
|
+ .then((res) => {
|
|
|
+ ElMessage({
|
|
|
+ message: '操作成功。',
|
|
|
+ type: 'success',
|
|
|
+ duration: 2500,
|
|
|
+ showClose: true,
|
|
|
+ })
|
|
|
+ })
|
|
|
+ .catch((e) => {
|
|
|
+ forceVerifies.value = e.data
|
|
|
+ })
|
|
|
}
|
|
|
|
|
|
const unArchiveBa = () => {
|
|
@@ -563,30 +627,6 @@ export default {
|
|
|
.catch(() => {})
|
|
|
}
|
|
|
|
|
|
- const lend = () => {
|
|
|
- ElMessage({
|
|
|
- message: '此功能正在努力开发中...',
|
|
|
- type: 'warning',
|
|
|
- duration: 3000,
|
|
|
- showClose: true,
|
|
|
- })
|
|
|
- }
|
|
|
-
|
|
|
- const handleEvent = (event) => {
|
|
|
- if (router.currentRoute.value.path !== '/allCaseFrontSheet') {
|
|
|
- return
|
|
|
- }
|
|
|
- if ((event.key === 's' && event.ctrlKey) || (event.key === 'S' && event.ctrlKey)) {
|
|
|
- event.preventDefault()
|
|
|
- event.returnValue = false
|
|
|
- saveVerify(1)
|
|
|
- } else if ((event.key === 'a' && event.ctrlKey) || (event.key === 'A' && event.ctrlKey)) {
|
|
|
- event.preventDefault()
|
|
|
- event.returnValue = false
|
|
|
- archiveBa()
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
const messageArea = {
|
|
|
width: windowSize.w - 1380 + 'px',
|
|
|
height: windowSize.h - 65 + 'px',
|
|
@@ -621,12 +661,16 @@ export default {
|
|
|
}, 500)
|
|
|
}
|
|
|
|
|
|
+ const currentDismissCountPage = ref(1)
|
|
|
+ const handleCurrentDismissCountPageChange = (val) => {
|
|
|
+ currentDismissCountPage.value = val
|
|
|
+ }
|
|
|
+
|
|
|
onActivated(() => {
|
|
|
initLodop()
|
|
|
})
|
|
|
|
|
|
onMounted(() => {
|
|
|
- document.addEventListener('keydown', handleEvent)
|
|
|
getAllDictionary().then((res) => {
|
|
|
res.getOperations = operations
|
|
|
res.getYesOrNo = yesOrNo
|
|
@@ -676,7 +720,6 @@ export default {
|
|
|
nextPage,
|
|
|
beforePrint,
|
|
|
handleSelectSearch,
|
|
|
- saveVerify,
|
|
|
dateRange,
|
|
|
shortcuts,
|
|
|
handleCommand,
|
|
@@ -686,8 +729,12 @@ export default {
|
|
|
showDismissCount,
|
|
|
dismissCountdata,
|
|
|
dismissCountMonth,
|
|
|
+ dismissCountType,
|
|
|
fetchDismissCount,
|
|
|
exportDismissCount,
|
|
|
+ archiveBa,
|
|
|
+ currentDismissCountPage,
|
|
|
+ handleCurrentDismissCountPageChange,
|
|
|
}
|
|
|
},
|
|
|
}
|