页面跳转添加loading,添加全局loading

This commit is contained in:
李志鹏
2025-12-12 10:34:10 +08:00
parent 652d89d3be
commit ed83044f81
6 changed files with 50 additions and 21 deletions

View File

@@ -498,6 +498,7 @@ function isTimeRangePassed(timeRange) {
}
router.beforeEach((to: any, from, next) => {
store.commit("set_view_loading", true);
//系统维护时间
const time = '2025-11-21T23:00:00 - 2025-11-22T00:00:00';
if (isTimeRangePassed(time) == 'in_progress') {
@@ -540,5 +541,7 @@ router.beforeEach((to: any, from, next) => {
// if(systemUser == 0){//游客用户只能进入这两个页面
});
router.afterEach((to, from) => {
store.commit("set_view_loading", false);
});
export default router;