Jelajahi Sumber

医保费用明细添加导出功能

lighter 9 bulan lalu
induk
melakukan
19a6675018
1 mengubah file dengan 25 tambahan dan 0 penghapusan
  1. 25 0
      src/components/medical-insurance/medfee-analyse/Index.vue

+ 25 - 0
src/components/medical-insurance/medfee-analyse/Index.vue

@@ -2,6 +2,7 @@
   <div class="component-box-wrapper__fullscreen layout_container" :style="{zIndex}">
     <div style="font-size: 18px !important; margin-bottom: 20px">医保费用明细</div>
     <div style="position: fixed; top: 12px; right: 20px; width: 100%; text-align: right">
+      <el-button circle icon="Download" title="导出Excel" type="primary" @click="exportExcel"></el-button>
       <el-button circle icon="Close" title="关闭" type="danger" @click="close"></el-button>
     </div>
     <div class="layout_main layout_container layout-horizontal">
@@ -84,6 +85,7 @@
 import {queryFeeDetails} from '@/api/medical-insurance/si-query'
 import {computed, onMounted, ref} from 'vue'
 import {useZIndex} from "element-plus";
+import {Export} from "@/utils/ExportExcel";
 
 const props = defineProps({
   type: {
@@ -151,6 +153,29 @@ const fetchFeedtle = () => {
   })
 }
 
+function exportExcel() {
+  const field = {
+    feedetlSn: '流水号',
+    feeOcurTime: '费用发生时间',
+    medinsListCodg: '院内码',
+    medinsListName: '收费名称',
+    medListCodg: '国家编码',
+    medListName: '国家名称',
+    cnt: '数量',
+    pric: '单价',
+    detItemFeeSumamt: '金额',
+    fulamtOwnpayAmt: '全自费金额',
+    overlmtAmt: '超限价金额',
+    preselfpayAmt: '先行自付金额',
+    inscpScpAmt: '符合政策范围金额',
+    chrgitmLvName: '收费项目等级',
+    bilgDeptName: '科室',
+    bilgDrName: '医生',
+  }
+  const fileName = `医保费用明细(${psninfo.value.psnName}-${psninfo.value.patNo}_${psninfo.value.times}_${psninfo.value.ledgerSn})`
+  Export(feedtle.value, field, fileName)
+}
+
 const close = () => {
   emits('close')
 }