Sfoglia il codice sorgente

调整获取消息通知时机

yuanmingze 2 mesi fa
parent
commit
559d486fe3
1 ha cambiato i file con 2 aggiunte e 2 eliminazioni
  1. 2 2
      src/pages/mine/index.vue

+ 2 - 2
src/pages/mine/index.vue

@@ -169,7 +169,7 @@
 <script setup lang="ts">
 import { computed, ref } from 'vue'
 
-import { onLoad } from '@dcloudio/uni-app'
+import { onShow } from '@dcloudio/uni-app'
 
 import { getInternalMsgCountUnreadApi } from '@/services/modules/mine/common'
 
@@ -191,7 +191,7 @@ const hasUnreadNotification = ref(false)
 const companyList = ref<{ name: string; color: string }[]>([])
 const handleCompanyShow = ref(false)
 
-onLoad(() => {
+onShow(() => {
   if (!isLoggedIn.value) return
   getInternalMsgCountUnread()
 })