diff --git a/package.json b/package.json
index fe479a6..dd0850b 100644
--- a/package.json
+++ b/package.json
@@ -12,7 +12,8 @@
"core-js": "^3.6.5",
"element-ui": "^2.13.2",
"vue": "^2.6.11",
- "vue-router": "^3.2.0"
+ "vue-router": "^3.2.0",
+ "vue-table-with-tree-grid": "^0.2.4"
},
"devDependencies": {
"@vue/cli-plugin-babel": "~4.4.0",
diff --git a/src/components/access/access.vue b/src/components/access/access.vue
index a1fbc97..f49983e 100644
--- a/src/components/access/access.vue
+++ b/src/components/access/access.vue
@@ -12,7 +12,7 @@
-
+
等级{{['一','二','三'][scope.row.level]}}
diff --git a/src/components/access/roles.vue b/src/components/access/roles.vue
index bc4f7c4..61f8682 100644
--- a/src/components/access/roles.vue
+++ b/src/components/access/roles.vue
@@ -15,7 +15,7 @@
-
+
@@ -41,7 +41,7 @@
-
+
编辑
删除
分配权限
diff --git a/src/components/goods/categories.vue b/src/components/goods/categories.vue
new file mode 100644
index 0000000..f25e451
--- /dev/null
+++ b/src/components/goods/categories.vue
@@ -0,0 +1,186 @@
+
+
+
+ 首页
+ 商品管理
+ 商品分类
+
+
+
+
+
+ 添加分类
+
+
+
+
+
+
+
+
+
+
+ {{['一','二','三'][scope.row.cat_level]}}级
+
+
+
+ 编辑
+ 删除
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/components/goods/goods.vue b/src/components/goods/goods.vue
new file mode 100644
index 0000000..0f2fe1e
--- /dev/null
+++ b/src/components/goods/goods.vue
@@ -0,0 +1,12 @@
+
+
+
+
+
diff --git a/src/main.js b/src/main.js
index 02e65fc..2980fa1 100644
--- a/src/main.js
+++ b/src/main.js
@@ -5,8 +5,10 @@ import ElementUI from 'element-ui'
import 'element-ui/lib/theme-chalk/index.css'
import './assets/fonts/iconfont.css'
import './assets/css/globel.css'
+import tableTree from 'vue-table-with-tree-grid'
import axios from 'axios'
+Vue.component('table-tree', tableTree)
axios.defaults.baseURL = 'http://127.0.0.1:8888/api/private/v1/'
axios.interceptors.request.use(config => {
config.headers.Authorization = sessionStorage.getItem('token')
diff --git a/src/router/router.js b/src/router/router.js
index bc9bb45..83df9f9 100644
--- a/src/router/router.js
+++ b/src/router/router.js
@@ -6,6 +6,7 @@ import welcome from '../components/welcome'
import users from '../components/users/users'
import access from '../components/access/access'
import roles from '../components/access/roles'
+import categories from '../components/goods/categories'
Vue.use(VueRouter)
@@ -20,7 +21,8 @@ const routes = [
{ path: '/welcome', component: welcome },
{ path: '/users', component: users },
{ path: '/rights', component: access },
- { path: '/roles', component: roles }
+ { path: '/roles', component: roles },
+ { path: '/categories', component: categories }
]
}
]