金融产品设计及数字化营销沙盘
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

61 lines
2.1 KiB

2 years ago
import { Component } from 'vue';
import { createRouter, createWebHashHistory, RouteRecordRaw } from 'vue-router';
import { Document, Tools, UserFilled, Operation } from '@element-plus/icons-vue';
import Layout from '@/layout/index.vue';
declare module 'vue-router' {
interface RouteMeta {
hidden?: boolean;
title?: string;
icon?: Component;
// requiresPermission?: string;
2 years ago
}
}
export const routes: Array<RouteRecordRaw> = [
// { path: '/product', component: () => import('@/views/product/index.vue'), meta: { hidden: true } },
2 years ago
{ path: '/404', component: () => import('@/views/404.vue'), meta: { hidden: true } },
{ path: '/403', component: () => import('@/views/403.vue'), meta: { hidden: true } },
{
path: '',
component: Layout,
meta: { hidden: true },
children: [{ path: '', component: () => import('@/views/Home.vue'), meta: { title: 'menu.home' } }],
},
{
path: '/product',
redirect: '/product/index',
component: Layout,
meta: { title: '产品经理' },
children: [
{ path: 'index', component: () => import('@/views/product/List.vue'), meta: { title: '产品列表' } },
{ path: 'cardList/:action', component: () => import('@/views/product/CardList.vue'), meta: { title: '配置风控' } },
],
},
{
path: '/finance',
// redirect: '/finance/index',
component: Layout,
meta: { title: '金融市场' },
children: [
{ path: 'publish', component: () => import('@/views/finance/Publish.vue'), meta: { title: '发布' } },
{ path: 'account', component: () => import('@/views/finance/Account.vue'), meta: { title: '我的账户' } },
{ path: 'order', component: () => import('@/views/finance/Order.vue'), meta: { title: '我的订单' } },
{ path: 'armory', component: () => import('@/views/finance/Armory.vue'), meta: { title: '英雄榜' } },
],
2 years ago
},
// 404 page must be placed at the end !!!
{
path: '/:pathMatch(.*)*',
name: 'not-found',
redirect: '/404',
meta: { hidden: true },
},
];
const router = createRouter({
history: createWebHashHistory(),
scrollBehavior: () => ({ top: 0 }),
routes,
});
export default router;