720e5ba4 by lihua

fix

1 parent 6b807be5
......@@ -328,6 +328,20 @@ onBeforeMount(() => {
});
onActivated(() => {
let tab: any = userStore.tabbar.find((tab: any) => tab.fullPath === fullPath);
if (tab) {
if (route.query.detail) {
tab.meta.title = `新建规则(${route.query.planName})`;
if (fullPath === route.fullPath) {
document.title = tab.meta.title;
}
} else if (route.query.planName) {
tab.meta.title = `方案编辑-${route.query.planName}`;
if (fullPath === route.fullPath) {
document.title = tab.meta.title;
}
}
}
if (modelGuid.value || groupGuid.value) {
return;
}
......
......@@ -262,6 +262,16 @@ onBeforeMount(() => {
})
})
onActivated(() => {
let tab: any = userStore.tabbar.find((tab: any) => tab.fullPath === fullPath);
if (tab && detailInfo.value?.ruleConfName) {
tab.meta.title = `编辑-${detailInfo.value.ruleConfName}(${detailInfo.value.subjectZhName})`
if (fullPath === route.fullPath) {
document.title = tab.meta.title;
}
}
});
</script>
<template>
......
......@@ -269,6 +269,16 @@ onBeforeMount(() => {
})
})
onActivated(() => {
let tab: any = userStore.tabbar.find((tab: any) => tab.fullPath === fullPath);
if (tab && route.query.name) {
tab.meta.title = `新建规则(${route.query.name})`;
if (fullPath === route.fullPath) {
document.title = tab.meta.title;
}
}
});
const cancel = () => {
ElMessageBox.confirm(
"当前页面尚未保存,确定放弃修改吗?",
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!