疯狂的狮子li
2023-02-17 2aabdb83ad578b0c9213a18d1fb1257349e2bc3f
ruoyi-ui/src/router/index.js
@@ -155,7 +155,7 @@
    permissions: ['tool:gen:edit'],
    children: [
      {
        path: 'index',
        path: 'index/:tableId(\\d+)',
        component: () => import('@/views/tool/gen/editTable'),
        name: 'GenEdit',
        meta: { title: '修改生成配置', activeMenu: '/tool/gen' }
@@ -164,7 +164,14 @@
  }
]
// 防止连续点击多次路由报错
let routerPush = Router.prototype.push;
Router.prototype.push = function push(location) {
  return routerPush.call(this, location).catch(err => err)
}
export default new Router({
  base: process.env.VUE_APP_CONTEXT_PATH,
  mode: 'history', // 去掉url中的#
  scrollBehavior: () => ({ y: 0 }),
  routes: constantRoutes