mirror of
https://github.com/pure-admin/vue-pure-admin.git
synced 2025-06-07 08:57:19 +08:00
perf: 优化iframe
缓存 (#879)
This commit is contained in:
parent
b13d745474
commit
c5e280307e
@ -48,14 +48,17 @@ function init() {
|
|||||||
watch(
|
watch(
|
||||||
() => currentRoute.fullPath,
|
() => currentRoute.fullPath,
|
||||||
path => {
|
path => {
|
||||||
|
if (
|
||||||
|
currentRoute.name === "Redirect" &&
|
||||||
|
path.includes(props.frameInfo?.fullPath)
|
||||||
|
) {
|
||||||
|
frameSrc.value = path; // redirect时,置换成任意值,待重定向后 重新赋值
|
||||||
|
loading.value = true;
|
||||||
|
}
|
||||||
|
// 重新赋值
|
||||||
if (props.frameInfo?.fullPath === path) {
|
if (props.frameInfo?.fullPath === path) {
|
||||||
frameSrc.value = props.frameInfo?.frameSrc;
|
frameSrc.value = props.frameInfo?.frameSrc;
|
||||||
}
|
}
|
||||||
// 重新加载
|
|
||||||
if (path.indexOf("/redirect/") > -1) {
|
|
||||||
frameSrc.value = props.frameInfo?.fullPath;
|
|
||||||
loading.value = true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user