add:增加全局loading

This commit is contained in:
chenpingsen
2024-08-22 16:00:04 +08:00
parent ca74de5b37
commit 7b4f22222d
18 changed files with 401 additions and 251 deletions

View File

@@ -1,6 +1,8 @@
<template>
<a-config-provider :locale="locale">
<router-view />
<a-spin :spinning="state.isLoading" size="large">
<router-view />
</a-spin>
</a-config-provider>
</template>
@@ -10,6 +12,7 @@
import { useRouter } from 'vue-router';
import Cookies from 'js-cookie';
import { message } from 'ant-design-vue';
import { items } from '/@/store/item';
export default defineComponent({
name: 'App',
@@ -37,6 +40,8 @@
return {
cachedViews,
locale: zhCN,
// 获得全局变量
state: items(),
};
},
});