Browse Source

bug

jly/task001
井乐禹 2 years ago
parent
commit
b97d021615
  1. 23
      src/views/main-content.vue

23
src/views/main-content.vue

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

Loading…
Cancel
Save