add link urls in navbar

This commit is contained in:
j3d1 2019-11-30 00:59:04 +01:00
parent fd094ff62b
commit 69cc17f6df

View file

@ -37,7 +37,7 @@
<div class="collapse navbar-collapse" id="navbarSupportedContent"> <div class="collapse navbar-collapse" id="navbarSupportedContent">
<ul class="navbar-nav ml-auto"> <ul class="navbar-nav ml-auto">
<li class="nav-item" v-for="(link, index) in links" v-bind:key="index"> <li class="nav-item" v-for="(link, index) in links" v-bind:key="index">
<a class="nav-link text-nowrap" href="#">{{ link }}</a> <a class="nav-link text-nowrap" :href="link.path">{{ link.title }}</a>
</li> </li>
</ul> </ul>
</div> </div>
@ -52,7 +52,12 @@ import { mapState, mapActions, mapMutations } from 'vuex';
export default { export default {
name: 'Navbar', name: 'Navbar',
data: () => ({ data: () => ({
links: ['items', 'boxes', 'mass-edit', 'howto engel'], links: [
{'title':'items','path':'/'},
{'title':'boxes','path':'/boxes/'},
{'title':'mass-edit','path':'#'},
{'title':'howto engel','path':'/howto/'}
],
buttons: [ buttons: [
{ title: 'Add', icon: 'plus', color: 'success' }, { title: 'Add', icon: 'plus', color: 'success' },
{ title: 'Refresh', icon: 'sync-alt', color: 'primary' }, { title: 'Refresh', icon: 'sync-alt', color: 'primary' },