forked from integrated_whb/integrated_whb_vue
提示当前路由文件位置
parent
4976baad59
commit
83dd3a57a9
|
@ -3,7 +3,28 @@
|
||||||
style="display: flex; justify-content: space-between; align-items: center"
|
style="display: flex; justify-content: space-between; align-items: center"
|
||||||
>
|
>
|
||||||
<div class="breadcrumb">
|
<div class="breadcrumb">
|
||||||
|
<el-tooltip
|
||||||
|
v-if="isDEV"
|
||||||
|
placement="top"
|
||||||
|
:content="
|
||||||
|
route.matched
|
||||||
|
.at(-1)
|
||||||
|
.components.default.__file.substring(
|
||||||
|
route.matched
|
||||||
|
.at(-1)
|
||||||
|
.components.default.__file.indexOf('src/views')
|
||||||
|
)
|
||||||
|
"
|
||||||
|
>
|
||||||
<icon-local theme="filled" size="22" fill="#10a7e5" :stroke-width="3" />
|
<icon-local theme="filled" size="22" fill="#10a7e5" :stroke-width="3" />
|
||||||
|
</el-tooltip>
|
||||||
|
<icon-local
|
||||||
|
v-else
|
||||||
|
theme="filled"
|
||||||
|
size="22"
|
||||||
|
fill="#10a7e5"
|
||||||
|
:stroke-width="3"
|
||||||
|
/>
|
||||||
<el-breadcrumb class="app-breadcrumb" separator=">">
|
<el-breadcrumb class="app-breadcrumb" separator=">">
|
||||||
<transition-group name="breadcrumb">
|
<transition-group name="breadcrumb">
|
||||||
<el-breadcrumb-item
|
<el-breadcrumb-item
|
||||||
|
@ -23,15 +44,15 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="return">
|
<div class="return">
|
||||||
<el-button
|
<el-button
|
||||||
type="primary"
|
|
||||||
text
|
|
||||||
link
|
|
||||||
@click="$router.back()"
|
|
||||||
v-if="
|
v-if="
|
||||||
route.meta?.activeMenu &&
|
route.meta?.activeMenu &&
|
||||||
route.path &&
|
route.path &&
|
||||||
route.meta?.activeMenu !== route.path
|
route.meta?.activeMenu !== route.path
|
||||||
"
|
"
|
||||||
|
type="primary"
|
||||||
|
text
|
||||||
|
link
|
||||||
|
@click="$router.back()"
|
||||||
>
|
>
|
||||||
返回上一页
|
返回上一页
|
||||||
</el-button>
|
</el-button>
|
||||||
|
@ -46,6 +67,7 @@ import { useRoute } from "vue-router";
|
||||||
defineOptions({
|
defineOptions({
|
||||||
name: "LayoutBreadcrumb",
|
name: "LayoutBreadcrumb",
|
||||||
});
|
});
|
||||||
|
const isDEV = import.meta.env.DEV;
|
||||||
const route = useRoute();
|
const route = useRoute();
|
||||||
const data = reactive({
|
const data = reactive({
|
||||||
breadcrumbList: [],
|
breadcrumbList: [],
|
||||||
|
|
Loading…
Reference in New Issue