36 lines
930 B
HTML
36 lines
930 B
HTML
{{template "header" }}
|
|
<div id="app" style="width:100%">
|
|
<template>
|
|
<el-container>
|
|
|
|
<el-main class="mainMain">
|
|
|
|
<iframe id="fastGptIframe" src="http://101.132.103.143:3000/autologin" width="100%" height="100%"></iframe>
|
|
|
|
|
|
</el-main>
|
|
|
|
</el-container>
|
|
</template>
|
|
|
|
</div>
|
|
</body>
|
|
<script>
|
|
console.log("执行p1")
|
|
document.addEventListener('DOMContentLoaded', (event) => {
|
|
|
|
|
|
console.log("执行p2")
|
|
const iframe = document.getElementById('fastGptIframe').contentWindow;
|
|
|
|
console.log("执行p3")
|
|
setInterval(function () {
|
|
|
|
console.log("执行p4")
|
|
console.log("执行postMessage")
|
|
iframe.postMessage('{username:root,pwd:1234}', '*'); // '*' 表示允许所有源接收消息,出于安全考虑,应指定具体的目标源
|
|
}, 10000);
|
|
|
|
});
|
|
</script>
|
|
{{template "setting_bottom" .}} |