路由变动

This commit is contained in:
JenniferW 2025-11-26 15:03:37 +08:00
parent 7bbcff0dc7
commit 88abfab093
3 changed files with 64 additions and 52 deletions

View File

@ -60,13 +60,13 @@ export const constantRoutes = [
{
path: '',
component: Layout,
redirect: 'index',
redirect: 'search',
children: [
{
path: '/index',
component: () => import('@/views/index.vue'),
name: 'Index',
meta: { title: '首页', icon: 'dashboard', affix: true }
path: '/search',
component: () => import('@/views/order/intention/search.vue'),
name: 'Search',
// meta: { title: '首页', icon: 'dashboard', affix: true }
}
]
},
@ -99,10 +99,8 @@ export const constantRoutes = [
}
]
}
// 业务路由(订单管理、系统管理等)将从后端动态获取
];
// 动态路由将从后端接口获取,不再在此处定义
const router = createRouter({
history: createWebHistory(),

View File

@ -87,7 +87,7 @@ service.interceptors.response.use(res => {
ElMessageBox.confirm('登录状态已过期,您可以继续留在该页面,或者重新登录', '系统提示', { confirmButtonText: '重新登录', cancelButtonText: '取消', type: 'warning' }).then(() => {
isRelogin.show = false;
useUserStore().logOut().then(() => {
location.href = '/index';
location.href = '';
})
}).catch(() => {
isRelogin.show = false;

View File

@ -2,22 +2,36 @@
<div class="wscn-http404-container">
<div class="wscn-http404">
<div class="pic-404">
<img class="pic-404__parent" src="@/assets/404_images/404.png" alt="404">
<img class="pic-404__child left" src="@/assets/404_images/404_cloud.png" alt="404">
<img class="pic-404__child mid" src="@/assets/404_images/404_cloud.png" alt="404">
<img class="pic-404__child right" src="@/assets/404_images/404_cloud.png" alt="404">
<img
class="pic-404__parent"
src="@/assets/404_images/404.png"
alt="404"
/>
<img
class="pic-404__child left"
src="@/assets/404_images/404_cloud.png"
alt="404"
/>
<img
class="pic-404__child mid"
src="@/assets/404_images/404_cloud.png"
alt="404"
/>
<img
class="pic-404__child right"
src="@/assets/404_images/404_cloud.png"
alt="404"
/>
</div>
<div class="bullshit">
<div class="bullshit__oops">
404错误!
</div>
<div class="bullshit__oops">404错误!</div>
<div class="bullshit__headline">
{{ message }}
</div>
<div class="bullshit__info">
对不起您正在寻找的页面不存在尝试检查URL的错误然后按浏览器上的刷新按钮或尝试在我们的应用程序中找到其他内容
</div>
<router-link to="/index" class="bullshit__return-home">
<router-link to="/search" class="bullshit__return-home">
返回首页
</router-link>
</div>
@ -27,8 +41,8 @@
<script setup>
let message = computed(() => {
return '找不到网页!'
})
return "找不到网页!";
});
</script>
<style lang="scss" scoped>