diff --git a/zero.Web/App/app.vue b/zero.Web/App/app.vue index c29ac6e7..52c03942 100644 --- a/zero.Web/App/app.vue +++ b/zero.Web/App/app.vue @@ -21,9 +21,6 @@ import AuthApi from 'zeroservices/auth.js' import 'zero/axios.config.js' - console.info(Router); - console.dir(Router.options.routes); - export default { name: 'app', diff --git a/zero.Web/Plugins/MyPlugin/myplugin-settings.vue b/zero.Web/Plugins/MyPlugin/myplugin-settings.vue new file mode 100644 index 00000000..02af0eb4 --- /dev/null +++ b/zero.Web/Plugins/MyPlugin/myplugin-settings.vue @@ -0,0 +1,13 @@ + + + + \ No newline at end of file diff --git a/zero.Web/Plugins/MyPlugin/myplugin.vue b/zero.Web/Plugins/MyPlugin/myplugin.vue index d1a51c17..d276fda4 100644 --- a/zero.Web/Plugins/MyPlugin/myplugin.vue +++ b/zero.Web/Plugins/MyPlugin/myplugin.vue @@ -1,13 +1,20 @@  \ No newline at end of file diff --git a/zero.Web/Plugins/MyPlugin/routes.js b/zero.Web/Plugins/MyPlugin/routes.js index dd19cb41..6dfa1411 100644 --- a/zero.Web/Plugins/MyPlugin/routes.js +++ b/zero.Web/Plugins/MyPlugin/routes.js @@ -1,6 +1,8 @@  import View from './myplugin'; +import ViewSettings from './myplugin-settings'; export default [ - { path: '/myplugin', component: View } + { path: '/myplugin', component: View, name: 'MyPlugin' }, + { path: '/myplugin/settings', component: ViewSettings, name: 'MyPluginSettings' } ]; \ No newline at end of file diff --git a/zero.Web/router.js b/zero.Web/router.js index d04b0e45..b3b62073 100644 --- a/zero.Web/router.js +++ b/zero.Web/router.js @@ -5,23 +5,23 @@ import ViewSettings from 'zeropages/settings'; import ViewSettingsUser from 'zeropages/settings/user'; import ViewDefault from 'zeropages/page'; import ViewLists from 'zeropages/lists'; -import MyPluginRoutes from './Plugins/MyPlugin/Routes' +//import MyPluginRoutes from './Plugins/MyPlugin/Routes'; Vue.use(VueRouter); history.scrollRestoration = 'manual'; -const routes = [ +let routes = [ { path: '/settings/user', component: ViewSettingsUser }, { path: '/settings*', component: ViewSettings }, { path: '/lists', component: ViewLists }, { path: '*', component: ViewDefault } ]; -MyPluginRoutes.forEach(route => -{ - routes.push(route); -}); +//MyPluginRoutes.forEach(route => +//{ +// routes.push(route); +//}); const router = new VueRouter({ mode: 'history',