Kaynağa Gözat

修改加载数据

lex-xin 3 ay önce
ebeveyn
işleme
8c31c11692

+ 1 - 1
src/views/cloudPractice/cloudPractice.tsx

@@ -751,7 +751,7 @@ export default defineComponent({
       }
 
       const __init = async () => {
-         await getInstrumentCodes()
+         getInstrumentCodes()
          await handleAllSearchList()
          await handleAllGetSubject()
          await handleAllGetList()

+ 2 - 2
src/views/cloudPractice/useData.ts

@@ -6,7 +6,7 @@ import { getToken } from "@/libs/auth"
 import { httpAjax } from "@/plugin/httpAjax"
 
 import userStore from "@/store/modules/user"
-import { ref } from "vue"
+import { ref, shallowRef } from "vue"
 
 /**
  * 搜索数据
@@ -14,7 +14,7 @@ import { ref } from "vue"
 export const useFunction = () => {
    const userStoreHook = userStore()
    const loading = ref(false)
-   const instrumentCodes = ref<any>({}) // 乐器code
+   const instrumentCodes = shallowRef<any>({}) // 乐器code
 
    /** 跳转云教练 */
    const isPracticeShow = ref(false)