@lambo-design/shared 1.0.0-beta.113 → 1.0.0-beta.115
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/utils/menu/index.js +2 -0
- package/utils/platform.js +8 -4
package/package.json
CHANGED
package/utils/menu/index.js
CHANGED
|
@@ -83,6 +83,7 @@ const listToMenuTree = (list, menuTree, pageNode, parentId, crumbs, root, appId)
|
|
|
83
83
|
notCache: item.notCache ? true : false,
|
|
84
84
|
hideInMenu: item.hideInMenu ? true : false
|
|
85
85
|
},
|
|
86
|
+
permissionId: item.permissionId,
|
|
86
87
|
type: item.type,
|
|
87
88
|
pid: item.pid,
|
|
88
89
|
component: item.name,
|
|
@@ -132,6 +133,7 @@ const listToMenuTree = (list, menuTree, pageNode, parentId, crumbs, root, appId)
|
|
|
132
133
|
crumbs: [...crumbs],
|
|
133
134
|
type: item.type
|
|
134
135
|
},
|
|
136
|
+
permissionId: item.permissionId,
|
|
135
137
|
type: item.type,
|
|
136
138
|
pid: item.pid,
|
|
137
139
|
component: item.name,
|
package/utils/platform.js
CHANGED
|
@@ -700,6 +700,7 @@ export const turnToPage = (vm, name ,url) =>{
|
|
|
700
700
|
}
|
|
701
701
|
}
|
|
702
702
|
|
|
703
|
+
|
|
703
704
|
/**
|
|
704
705
|
* 获取上级节点的方法
|
|
705
706
|
* @param vm
|
|
@@ -707,11 +708,14 @@ export const turnToPage = (vm, name ,url) =>{
|
|
|
707
708
|
* @returns {*}
|
|
708
709
|
*/
|
|
709
710
|
export const getParentMethod = (vm,methodName) => {
|
|
710
|
-
if (vm.$parent
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
711
|
+
if (vm.$parent) {
|
|
712
|
+
if (vm.$parent[methodName]) {
|
|
713
|
+
return vm.$parent[methodName];
|
|
714
|
+
} else {
|
|
715
|
+
return getParentMethod(vm.$parent,methodName)
|
|
716
|
+
}
|
|
714
717
|
}
|
|
718
|
+
return undefined;
|
|
715
719
|
}
|
|
716
720
|
|
|
717
721
|
/**
|