Add a new dashboard page.
This commit is contained in:
parent
89150e1164
commit
fd24b1898e
133 changed files with 17303 additions and 11112 deletions
26
webui/src/router/index.js
Normal file
26
webui/src/router/index.js
Normal file
|
@ -0,0 +1,26 @@
|
|||
import Vue from 'vue'
|
||||
import VueRouter from 'vue-router'
|
||||
|
||||
import routes from './routes'
|
||||
|
||||
Vue.use(VueRouter)
|
||||
|
||||
/*
|
||||
* If not building with SSR mode, you can
|
||||
* directly export the Router instantiation
|
||||
*/
|
||||
|
||||
export default function (/* { store, ssrContext } */) {
|
||||
const Router = new VueRouter({
|
||||
scrollBehavior: () => ({ x: 0, y: 0 }),
|
||||
routes,
|
||||
|
||||
// Leave these as is and change from quasar.conf.js instead!
|
||||
// quasar.conf.js -> build -> vueRouterMode
|
||||
// quasar.conf.js -> build -> publicPath
|
||||
mode: process.env.VUE_ROUTER_MODE,
|
||||
base: process.env.VUE_ROUTER_BASE
|
||||
})
|
||||
|
||||
return Router
|
||||
}
|
31
webui/src/router/routes.js
Normal file
31
webui/src/router/routes.js
Normal file
|
@ -0,0 +1,31 @@
|
|||
const LayoutDefault = () => import('layouts/Default.vue')
|
||||
|
||||
const routes = [
|
||||
{
|
||||
path: '/',
|
||||
component: LayoutDefault,
|
||||
children: [
|
||||
{
|
||||
path: '',
|
||||
name: 'dashboard',
|
||||
component: () => import('pages/dashboard/Index.vue'),
|
||||
meta: {
|
||||
title: 'Dashboard'
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
|
||||
// Always leave this as last one
|
||||
if (process.env.MODE !== 'ssr') {
|
||||
routes.push({
|
||||
path: '*',
|
||||
component: () => import('pages/_commons/Error404.vue'),
|
||||
meta: {
|
||||
title: '404'
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
export default routes
|
Loading…
Add table
Add a link
Reference in a new issue