Refact: Reoganise components and router
This commit is contained in:
parent
0bb3572ec7
commit
c06b834580
@ -7,10 +7,8 @@
|
||||
</b-navbar-brand>
|
||||
|
||||
<b-collapse is-nav id="nav_collapse">
|
||||
<b-navbar-nav>
|
||||
<b-nav-item :to="{ name: 'analysis' }">Analyse</b-nav-item>
|
||||
<b-nav-item :to="{ name: 'import' }">Import</b-nav-item>
|
||||
<b-nav-item :to="{ name: 'postes' }">Postes</b-nav-item>
|
||||
<b-navbar-nav class="ml-auto">
|
||||
<b-nav-item :to="{ name: 'config' }">Config</b-nav-item>
|
||||
</b-navbar-nav>
|
||||
</b-collapse>
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
import Vue from 'vue'
|
||||
import Router from 'vue-router'
|
||||
import home from './views/Home.vue'
|
||||
import home from './views/home.vue'
|
||||
|
||||
Vue.use(Router)
|
||||
|
||||
@ -12,28 +12,12 @@ export default new Router({
|
||||
component: home
|
||||
},
|
||||
{
|
||||
path: '/analysis',
|
||||
name: 'analysis',
|
||||
path: '/config',
|
||||
name: 'config',
|
||||
// route level code-splitting
|
||||
// this generates a separate chunk (import.[hash].js) for this route
|
||||
// this generates a separate chunk (config.[hash].js) for this route
|
||||
// which is lazy-loaded when the route is visited.
|
||||
component: () => import(/* webpackChunkName: "import" */ './views/analysis.vue')
|
||||
},
|
||||
{
|
||||
path: '/import',
|
||||
name: 'import',
|
||||
// route level code-splitting
|
||||
// this generates a separate chunk (import.[hash].js) for this route
|
||||
// which is lazy-loaded when the route is visited.
|
||||
component: () => import(/* webpackChunkName: "import" */ './views/import.vue')
|
||||
},
|
||||
{
|
||||
path: '/postes',
|
||||
name: 'postes',
|
||||
// route level code-splitting
|
||||
// this generates a separate chunk (postes.[hash].js) for this route
|
||||
// which is lazy-loaded when the route is visited.
|
||||
component: () => import(/* webpackChunkName: "postes" */ './views/postes.vue')
|
||||
component: () => import(/* webpackChunkName: "config" */ './views/config.vue')
|
||||
}
|
||||
]
|
||||
})
|
||||
|
@ -1,20 +0,0 @@
|
||||
<template>
|
||||
<div class="home">
|
||||
<h1>Comptes </h1>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
// @ is an alias to /src
|
||||
export default {
|
||||
name: 'home',
|
||||
components: {
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
}
|
||||
}
|
||||
</script>
|
@ -20,7 +20,7 @@
|
||||
import { mapGetters } from 'vuex'
|
||||
|
||||
export default {
|
||||
name: 'analysis',
|
||||
name: 'home',
|
||||
components: {
|
||||
},
|
||||
data () {
|
@ -1,5 +0,0 @@
|
||||
<template>
|
||||
<div class="import">
|
||||
<h1>Import</h1>
|
||||
</div>
|
||||
</template>
|
Loading…
Reference in New Issue
Block a user