Commit 4cd91f55 authored by tianhongyang's avatar tianhongyang

fix

parent d368e244
...@@ -354,7 +354,7 @@ export default { ...@@ -354,7 +354,7 @@ export default {
methods: { methods: {
financial(id) { financial(id) {
financial({ cid: String(id) }).then(res => { financial({ cid: String(id) }).then(res => {
if (res.code == 200 && !res.data) { if ((res.code == 200 && !res.data) || !res.data?.totalAssets) {
this.sideRoute[1].disabled = true; this.sideRoute[1].disabled = true;
this.defaultRoute = JSON.parse(JSON.stringify(this.sideRoute)); this.defaultRoute = JSON.parse(JSON.stringify(this.sideRoute));
} }
......
...@@ -32,14 +32,14 @@ export default { ...@@ -32,14 +32,14 @@ export default {
timelongs: 7200,//刷新token时间 timelongs: 7200,//刷新token时间
tokentimer: null, tokentimer: null,
showMaxPageTip: false, showMaxPageTip: false,
iframeIns : null, iframeIns: null,
}; };
}, },
created() { created() {
if (window.location.host === 'http://szh.jiansheku.com' || window.location.host === 'szh.jiansheku.com') { if (window.location.host === 'http://szh.jiansheku.com' || window.location.host === 'szh.jiansheku.com') {
this.domain = 'https://plug.jiansheku.com'; this.domain = 'https://plug.jiansheku.com';
} else { } else {
this.domain='https://pre-plug.jiansheku.com' this.domain = 'https://pre-plug.jiansheku.com';
// this.domain = 'http://192.168.60.104:3400'; // this.domain = 'http://192.168.60.104:3400';
} }
this.gettokens(); this.gettokens();
...@@ -49,7 +49,6 @@ export default { ...@@ -49,7 +49,6 @@ export default {
mounted() { mounted() {
this.iframeLoading(); // 判断iframe页面是否加载完成-当前页控制 this.iframeLoading(); // 判断iframe页面是否加载完成-当前页控制
// steerScroll('companyIframe', this.navigation, this.footHeight, true); // iframeId: iframe的id;navigation:页面排除iframe后剩下的顶部高度;footHeight: 页面排除iframe后剩下的底部高度;state:监听or移除监听;parentId: 父级id[不带默认就是铺满整个页面]];_this:指向当前实例(可忽略) // steerScroll('companyIframe', this.navigation, this.footHeight, true); // iframeId: iframe的id;navigation:页面排除iframe后剩下的顶部高度;footHeight: 页面排除iframe后剩下的底部高度;state:监听or移除监听;parentId: 父级id[不带默认就是铺满整个页面]];_this:指向当前实例(可忽略)
console.log(document.querySelector(".market-iframe").contentWindow.document.documentElement.scrollHeight);
}, },
beforeDestroy() { beforeDestroy() {
clearInterval(this.iframeTimer); // -当前页控制 clearInterval(this.iframeTimer); // -当前页控制
...@@ -57,7 +56,7 @@ export default { ...@@ -57,7 +56,7 @@ export default {
clearInterval(this.tokentimer); clearInterval(this.tokentimer);
window.removeEventListener("message", this.pagecapListener, { passive: true }); window.removeEventListener("message", this.pagecapListener, { passive: true });
// 移除layout样式 // 移除layout样式
this.iframeIns.contentWindow.postMessage("",{}) this.iframeIns.contentWindow.postMessage("removeHtmlLayoutStyle", { targetOrigin: this.domain, });
}, },
methods: { methods: {
async iframeObserver() { async iframeObserver() {
...@@ -71,7 +70,7 @@ export default { ...@@ -71,7 +70,7 @@ export default {
// 列表翻页上限 // 列表翻页上限
pagecapListener(e) { pagecapListener(e) {
const { origin, data } = e; const { origin, data } = e;
if (origin.indexOf(this.domain) < 0) return; if (origin != this.domain) return;
if (data == "pageCurrentMaxSize") { if (data == "pageCurrentMaxSize") {
this.showMaxPageTip = true; this.showMaxPageTip = true;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment