From 84ddc30f2b221e6a7f057590b5701121b90ba6b7 Mon Sep 17 00:00:00 2001 From: Faris Ansari Date: Tue, 23 Oct 2018 22:58:26 +0530 Subject: [PATCH] Add Tree route and Chart of Accounts to sidebar --- src/components/Sidebar.vue | 8 ++++++-- src/router/index.js | 10 +++++++++- 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/src/components/Sidebar.vue b/src/components/Sidebar.vue index 2442a79b..0149dd7b 100644 --- a/src/components/Sidebar.vue +++ b/src/components/Sidebar.vue @@ -24,8 +24,8 @@ export default { dbFileName: '', items: [ { - label: 'Invoices', - route: '/list/Invoice' + label: 'Chart of Accounts', + route: '/tree/Account' }, { label: 'Customers', @@ -35,6 +35,10 @@ export default { label: 'Items', route: '/list/Item' }, + { + label: 'Invoices', + route: '/list/Invoice' + }, { label: 'Reports', route: '/reportList' diff --git a/src/router/index.js b/src/router/index.js index 6e6c92e1..c4c32602 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -14,6 +14,8 @@ import Settings from '../pages/Settings/Settings'; import ReportList from '../pages/Report'; +import Tree from 'frappejs/ui/components/Tree'; + Vue.use(Router); const routes = [ @@ -62,7 +64,13 @@ const routes = [ path: '/reportList', name: 'Report', component: ReportList - } + }, + { + path: '/tree/:doctype', + name: 'Tree', + component: Tree, + props: true + }, ]; export default new Router({ routes });