From 6bcc725d31c34866c290bf69d785aef3fec93dbc Mon Sep 17 00:00:00 2001 From: xdrm-brackets Date: Mon, 4 Dec 2017 22:57:24 +0100 Subject: [PATCH] updated ''router'' engine (without vue-router) --- view/vue-config.js | 2 +- view/vue/menu.vue | 3 ++- view/vue/wrapper.vue | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/view/vue-config.js b/view/vue-config.js index 1968300..09f86e1 100644 --- a/view/vue-config.js +++ b/view/vue-config.js @@ -25,7 +25,7 @@ window.gstore.add('menu_item', { label: 'Profil', icon: 'profile' }, inbox: { - label: 'Boîte de réception', + label: 'Messagerie instantannée', icon: 'messages' } }); diff --git a/view/vue/menu.vue b/view/vue/menu.vue index e3160a9..46940fc 100644 --- a/view/vue/menu.vue +++ b/view/vue/menu.vue @@ -22,8 +22,9 @@ export default { methods: { navigate_menu(page){ - // (1) Manage action + // (1) Update URL console.log('Loading page \''+page+'\''); + window.history.pushState(page, page, '/'+page+'/'); // (2) Activate current element this.gstore.menu_item_active = page; diff --git a/view/vue/wrapper.vue b/view/vue/wrapper.vue index 6988fc8..fc79c59 100755 --- a/view/vue/wrapper.vue +++ b/view/vue/wrapper.vue @@ -8,7 +8,7 @@ - +