提交 991c714d 编写于 作者: tony001's avatar tony001

调整面包屑分隔符可自由配置

上级 e6a44e4c
<template>
<el-breadcrumb class="app-breadcrumb" separator="/">
<el-breadcrumb class="app-breadcrumb" :separator="separator">
<transition-group name="breadcrumb">
<template v-if="Object.is(this.navModel,'route')">
<el-breadcrumb-item v-for="(item, index) in breadcrumbs" :key="item.id">
......@@ -34,6 +34,7 @@
import { Component, Vue, Watch, Prop } from 'vue-property-decorator'
import { RouteRecord, Route } from 'vue-router'
import { Environment } from "@/environments/environment";
import { appConfig } from '@/config/appConfig';
import NavDataService from '@/service/app/navdata-service';
import {Subscription } from 'rxjs';
......@@ -48,6 +49,13 @@ export default class Breadcrumb extends Vue {
*/
private breadcrumbs: Array<any> = [];
/**
* 面包屑分隔符
*
* @memberof Breadcrumb
*/
private separator:string = appConfig.breadcrumbSeparator;
/**
* 导航服务
*
......
......@@ -35,5 +35,7 @@ export const appConfig = {
label: 'YouYuan',
value: 'YouYuan',
},
]
],
// 面包屑分隔符
breadcrumbSeparator:"/"
}
\ No newline at end of file
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册