diff --git a/src/components/Breadcrumb/index.vue b/src/components/Breadcrumb/index.vue index 2d684f0..7e0f311 100644 --- a/src/components/Breadcrumb/index.vue +++ b/src/components/Breadcrumb/index.vue @@ -3,7 +3,7 @@ {{ item.meta.title }} - {{ item.meta.title }} + {{ item.meta.title }} @@ -44,6 +44,14 @@ export default { const { params } = this.$route var toPath = pathToRegexp.compile(path) return toPath(params) + }, + handleLink(item) { + const { redirect, path } = item + if (redirect) { + this.$router.push(redirect) + return + } + this.$router.push(this.pathCompile(path)) } } }