Selaa lähdekoodia

fix: 修复打包错误问题

曾坤森 3 kuukautta sitten
vanhempi
commit
b0010ff2ea
2 muutettua tiedostoa jossa 3 lisäystä ja 4 poistoa
  1. 1 2
      src/hooks/request.ts
  2. 2 2
      src/views/list/card/components/card-wrap.vue

+ 1 - 2
src/hooks/request.ts

@@ -1,6 +1,5 @@
 import { ref, UnwrapRef } from 'vue';
 import { AxiosResponse } from 'axios';
-import { HttpResponse } from '@/api/interceptor';
 import useLoading from './loading';
 
 // use to fetch list
@@ -9,7 +8,7 @@ import useLoading from './loading';
 // example: useRequest(api.bind(null, {}))
 
 export default function useRequest<T>(
-  api: () => Promise<AxiosResponse<HttpResponse>>,
+  api: () => Promise<AxiosResponse>,
   defaultValue = [] as unknown as T,
   isLoading = true
 ) {

+ 2 - 2
src/views/list/card/components/card-wrap.vue

@@ -61,10 +61,10 @@
         </a-space>
         <div v-else>
           <a-space>
-            <a-button @click="toggle(false)">
+            <a-button @click="handleToggle()">
               {{ closeTxt }}
             </a-button>
-            <a-button type="primary" @click="toggle(true)">
+            <a-button type="primary" @click="handleToggle()">
               {{ openTxt }}
             </a-button>
           </a-space>