|
@ -129,14 +129,16 @@ export default { |
|
|
if (!from) { |
|
|
if (!from) { |
|
|
return |
|
|
return |
|
|
} |
|
|
} |
|
|
console.log(this.$store.state.contentTabs); |
|
|
|
|
|
if (from.path == "/main/i-1672924097874173953") { |
|
|
if (from.path == "/main/i-1672924097874173953") { |
|
|
let iframes = document.querySelector("#iframes") |
|
|
let iframes = document.querySelector("#iframes") |
|
|
|
|
|
console.log(iframes, 97998); |
|
|
|
|
|
if (iframes) { |
|
|
iframes.src = 'about:blank'; |
|
|
iframes.src = 'about:blank'; |
|
|
iframes.contentWindow.document.write(''); |
|
|
iframes.contentWindow.document.write(''); |
|
|
iframes.contentWindow.document.close(); |
|
|
iframes.contentWindow.document.close(); |
|
|
iframes.parentNode.removeChild(iframes); |
|
|
iframes.parentNode.removeChild(iframes); |
|
|
} |
|
|
} |
|
|
|
|
|
} |
|
|
if (to.path == "/main/i-1672924097874173953") { |
|
|
if (to.path == "/main/i-1672924097874173953") { |
|
|
let url; |
|
|
let url; |
|
|
this.$store.state.contentTabs.forEach(f => { |
|
|
this.$store.state.contentTabs.forEach(f => { |
|
@ -146,9 +148,10 @@ export default { |
|
|
}) |
|
|
}) |
|
|
let iframe = document.createElement('iframe'); |
|
|
let iframe = document.createElement('iframe'); |
|
|
iframe.src = url + this.urlTokenSymbol + 'token=' + this.token + '&customerId=' + this.customerId; |
|
|
iframe.src = url + this.urlTokenSymbol + 'token=' + this.token + '&customerId=' + this.customerId; |
|
|
iframe.unselectable = "on"; |
|
|
iframe.frameborder = "0" |
|
|
iframe.name = "container"; |
|
|
iframe.id = "iframes" |
|
|
iframe.id = "iframes"; |
|
|
iframe.height = "100%" |
|
|
|
|
|
iframe.width = "100%" |
|
|
//添加到原来的iframe位置 |
|
|
//添加到原来的iframe位置 |
|
|
if (document.querySelector("#iframeBox")) { |
|
|
if (document.querySelector("#iframeBox")) { |
|
|
document.querySelector("#iframeBox").appendChild(iframe); |
|
|
document.querySelector("#iframeBox").appendChild(iframe); |
|
@ -332,7 +335,7 @@ export default { |
|
|
overflow: hidden; |
|
|
overflow: hidden; |
|
|
} |
|
|
} |
|
|
#iframeBox { |
|
|
#iframeBox { |
|
|
width: "100%"; |
|
|
width: 100%; |
|
|
height: "100%"; |
|
|
height: 100%; |
|
|
} |
|
|
} |
|
|
</style> |
|
|
</style> |
|
|