Comments (3)
在 544b75a 修复
from d2-admin-xiya-go-cms.
你好,还是有点不准确,需要判断是否有值,不然还是会导致路由加载失败。
/**
* @description 检验是否为合法路由
* @param {Object} sourceItem 原始数据的一项
*/
function isEffectiveRoute (sourceItem) {
if (sourceItem.menu_type !== context.env.VUE_APP_DICT_MENU_TYPE_MENU) return
const sourceItemKeys = keys(sourceItem)
const hasAllRequiredProperties = [
'menu_name',
'route_name',
'route_path',
'route_component'
].reduce((res, keyname) => res && sourceItemKeys.includes(keyname) && sourceItem[keyname], true) <--- 还需要判断是否有值,特别是 route_component ,不然路由会加载失败
if (!hasAllRequiredProperties) return
return true
}
from d2-admin-xiya-go-cms.
感谢提出 已经修改 e629340
from d2-admin-xiya-go-cms.
Related Issues (20)
- 🔩 功能开发 | d2-tree 组件的默认值
- 🔩 功能开发 | d2-tree-popover 增加设置项 是否每次打开时都重新请求数据
- 🔩 功能开发 | d2-tree-popover 增加 loading 状态
- 🔩 功能开发 | d2-tree-popover 增加搜索
- 🔩 功能开发 | d2-dict-select 清空选项和选择全部功能
- 🔩 功能开发 | 自定义 form 标题
- 👾 BUG | removeHalf 方法不能正确处理深层半选节点
- 🎮 示例相关 | 能否提供一个演示的账号?想看一下你的权限呈现方式 HOT 1
- 谷歌浏览器-列设置显示有问题
- 👾 BUG | api 地址设置了不生效 HOT 1
- 👾 BUG | 设置菜单缓存为true,前端并未进入keepAlive
- # index 最小的地址被默认激活 VUE_APP_API HOT 1
- 👾 BUG | 修复菜单组件文件不存在时页面空白的问题 HOT 1
- 预览示例网站进不去
- 🤔 提问 | 这个项目停止维护了吗? HOT 2
- 登录页的验证码注释掉了,还是会获取验证码的js;请问在哪里注释掉?
- 👾 BUG | 页面开启缓存之后只显示第一个访问的页面
- 🌈 显示优化 | button 间距 build 之后显示错误
- 👾 BUG | 源码组件数据不对
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from d2-admin-xiya-go-cms.