This commit is contained in:
2019-04-30 00:01:31 +00:00
parent 6e54a92ccb
commit 6391ea3a12
2 changed files with 52 additions and 8 deletions

View File

@@ -172,6 +172,32 @@ function clickHandler(menuItem) {
}
export default {
//https://router.vuejs.org/guide/advanced/navigation-guards.html#in-component-guards
// /*eslint-disable-next-line*/
// beforeRouteEnter(to, from, next) {
// //check rights here!!!
// /*eslint-disable-next-line*/
// var v = { t: to, f: from, n: next };
// // called before the route that renders this component is confirmed.
// // does NOT have access to `this` component instance,
// // because it has not been created yet when this guard is called!
// },
// /*eslint-disable-next-line*/
// beforeRouteUpdate(to, from, next) {
// // called when the route that renders this component has changed,
// // but this component is reused in the new route.
// // For example, for a route with dynamic params `/foo/:id`, when we
// // navigate between `/foo/1` and `/foo/2`, the same `Foo` component instance
// // will be reused, and this hook will be called when that happens.
// // has access to `this` component instance.
// },
// /*eslint-disable-next-line*/
// beforeRouteLeave(to, from, next) {
// // called when the route that renders this component is about to
// // be navigated away from.
// // has access to `this` component instance.
// },
beforeCreate() {
//Cache all required lt keys
var ltKeysRequired = [