Explorar el Código

drg路由问题

xiaochan hace 1 año
padre
commit
d5252dd2c2

+ 15 - 0
src/layout/LayoutRouterView.vue

@@ -0,0 +1,15 @@
+<script setup lang="ts">
+import {getKeepAliveNames} from "@/pinia/use-tabs";
+</script>
+
+<template>
+  <router-view v-slot="{ Component }">
+    <transition name="fade-transform" mode="out-in">
+      <keep-alive :include="getKeepAliveNames">
+        <component :is="Component"/>
+      </keep-alive>
+    </transition>
+  </router-view>
+</template>
+
+ 

+ 2 - 8
src/layout/default-layout/index.vue

@@ -34,13 +34,7 @@
         <DefaultTabs/>
       </div>
       <div class="layout_main layout-default_main">
-        <router-view v-slot="{ Component }">
-          <transition name="fade-transform" mode="out-in">
-            <keep-alive :include="getKeepAliveNames">
-              <component :is="Component"/>
-            </keep-alive>
-          </transition>
-        </router-view>
+        <LayoutRouterView/>
       </div>
     </div>
   </div>
@@ -55,7 +49,7 @@ import ToolInfoBar from "@/layout/fillet-layout/ToolInfoBar.vue";
 import DefaultTabs from "@/layout/default-layout/DefaultTabs.vue";
 import router, {routerMenus} from "@/router";
 import {find, toTreeArray} from "xe-utils";
-import {getKeepAliveNames} from "@/pinia/use-tabs";
+import LayoutRouterView from "@/layout/LayoutRouterView.vue";
 
 const systemStore = useSystemStore()
 const isCollapse = computed<boolean>(() => systemStore.getCollapse)

+ 4 - 1
src/views/hospitalization/case-front-sheet/DrgCoding.vue

@@ -899,6 +899,10 @@ async function checkPathParams() {
   }
 }
 
+onActivated(() => {
+  checkPathParams()
+})
+
 onMounted(() => {
   getInsutypes().then((res) => {
     insutypes.value = res
@@ -922,7 +926,6 @@ onMounted(() => {
     }
   }))
   clrOptins.value = clrOptinsData
-  checkPathParams()
 })
 
 const ybSfData = [

+ 2 - 5
src/views/hospitalization/zhu-yuan-yi-sheng/Home.vue

@@ -15,11 +15,7 @@
               <yz-tag :patient-info="patientInfo"/>
             </template>
             <div style="height:100%; width: 100%">
-              <router-view v-slot="{ Component }">
-                <keep-alive>
-                  <component :is="Component"/>
-                </keep-alive>
-              </router-view>
+              <LayoutRouterView/>
             </div>
           </CyFlex>
         </div>
@@ -42,6 +38,7 @@ import router from "@/router";
 import {shortcutTrigger, xcEvent} from "@/utils/xckeydown";
 import CyFlex from "@/components/cy/flex/src/CyFlex.vue";
 import YzSidebar from "@/views/hospitalization/zhu-yuan-yi-sheng/comp/sidebar/YzSidebar.vue";
+import LayoutRouterView from "@/layout/LayoutRouterView.vue";
 
 let keyWatch = null
 let shortcutKeyRegistration = {

+ 4 - 8
src/views/medical-insurance/inpatient/Home.vue

@@ -22,13 +22,7 @@
         <Overview ref="overview" :showSelection="isUploadPage"/>
       </div>
       <div class="layout_flex_1-x">
-        <router-view v-slot="{ Component }">
-          <transition name="fade-transform" mode="out-in">
-            <keep-alive>
-              <component :is="Component"/>
-            </keep-alive>
-          </transition>
-        </router-view>
+        <LayoutRouterView/>
         <Registinfo v-if="showRegisterInfo" :params="patient" @close="showRegisterInfo = false"></Registinfo>
         <IdentifyImage v-if="showIdCardImg" :pat-no="patient.inpatientNo" :times="patient.admissTimes"
                        @close="showIdCardImg = false"></IdentifyImage>
@@ -61,6 +55,7 @@ import {getLodop, initLodop} from "@/utils/c-lodop";
 import {useMedinsStore} from "@/pinia/medins-store";
 import BloodSugar from "@/views/hospitalization/zhu-yuan-yi-sheng/yi-zhu-lu-ru/components/BloodSugar.vue";
 import {useCompRef} from "@/utils/useCompRef";
+import LayoutRouterView from "@/layout/LayoutRouterView.vue";
 
 const search = initSearchParam()
 const permission = getGreatestRole()
@@ -164,7 +159,7 @@ const checkTreatmentinfos = (row) => {
   showTreatmentinfos.value = true
 }
 
-const childrenDepts = ['1040000','1040100', '1700015']
+const childrenDepts = ['1040000', '1040100', '1700015']
 
 function printWristStrap() {
   if (nullPatient()) return
@@ -176,6 +171,7 @@ function printWristStrap() {
 }
 
 let LODOP;
+
 function printNormalWristStrap() {
   LODOP = getLodop();
   LODOP.PRINT_INIT('inpatient_info2')