Initial commit

This commit is contained in:
南宁网宿科技
2023-06-03 23:57:39 +08:00
commit 13bed2bafb
1017 changed files with 175796 additions and 0 deletions
+21
View File
@@ -0,0 +1,21 @@
/** 用于刷新的路由组件 */
import { defineComponent, unref, h } from 'vue';
import { useRouter } from 'vue-router';
import { setRouteReload } from '@/utils/page-tab-util';
export default defineComponent({
name: 'RedirectLayout',
setup() {
const { currentRoute, replace } = useRouter();
const { params, query } = unref(currentRoute);
const from = Array.isArray(params.path)
? params.path.join('/')
: params.path;
const path = '/' + from;
setTimeout(() => {
setRouteReload(null);
replace({ path, query });
}, 100);
return () => h('div');
}
});