@lambo-design/shared 1.0.0-beta.13 → 1.0.0-beta.14
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 +3 -3
package/package.json
CHANGED
package/utils/menu/index.js
CHANGED
|
@@ -12,12 +12,12 @@ export const hasRoute = ($router, name) => {
|
|
|
12
12
|
/**
|
|
13
13
|
* 判断是否存在路由并且页面存在
|
|
14
14
|
* @param $router
|
|
15
|
-
* @param
|
|
15
|
+
* @param path
|
|
16
16
|
* @returns {*|boolean}
|
|
17
17
|
*/
|
|
18
|
-
export const
|
|
18
|
+
export const hasRoutePath = ($router, path) => {
|
|
19
19
|
let routes = $router.getRoutes();
|
|
20
|
-
let res = routes.filter(item => item.
|
|
20
|
+
let res = routes.filter(item => item.path === path)
|
|
21
21
|
return res && res.length > 0
|
|
22
22
|
}
|
|
23
23
|
/**
|