router.addRoute("index", { path: r.path, name: r.path, / 把名字改成我们页面的名称 例如CategoriesVie w.vue */ component: () => import(@/views/${r.path.substring(0,1).toUpperCase()+r.path.substring(1)}View.vue), }); }) }); console.log(this.router) } else { /* 防止数据获取失败,给出相应的后台提示 */ this.message.error(meta.msg); } }) .catch((err) => { console.log(err); }); }, }, }; .el-header { background-color: #b3c0d1; color: #333; line-height: 60px; } .el-aside { color: #333; }