improve: iframe模式判断

This commit is contained in:
From-wh 2023-04-21 11:53:43 +08:00
parent 149798bbe4
commit f78daf877d
5 changed files with 7 additions and 7 deletions

View File

@ -86,7 +86,7 @@ export default {
sm: 24,
xs: 24,
},
iframeUrl: `${location.origin}/pages/index/index?type=iframeWindow`,
iframeUrl: `${location.origin}/pages/index/index?mdType=iframeWindow`,
is_live: 1,
pageData: {
code: '',

View File

@ -284,7 +284,7 @@ export default {
},
created() {
this.getList();
this.imgUrl = `${location.origin}/pages/index/index?type=iframeWindow`;
this.imgUrl = `${location.origin}/pages/index/index?mdType=iframeWindow`;
},
mounted: function () {},
methods: {
@ -294,7 +294,7 @@ export default {
refreshFrame() {
this.imgUrl = '';
setTimeout((e) => {
this.imgUrl = `${location.origin}/pages/index/index?type=iframeWindow`;
this.imgUrl = `${location.origin}/pages/index/index?mdType=iframeWindow`;
}, 200);
},
getChildData(e) {

View File

@ -47,7 +47,7 @@ export default {
this.setConfig = 'admin/' + names + '/setConfig';
this.updataConfig = 'admin/' + names + '/updataConfig';
this.pageId = parseInt(pageId);
this.iframeUrl = `${location.origin}/pages/index/index?type=iframeWindow`;
this.iframeUrl = `${location.origin}/pages/index/index?mdType=iframeWindow`;
diyGetInfo(parseInt(pageId)).then((datas) => {
let data = datas.data.info.value;
this.upData(data);

View File

@ -53,11 +53,11 @@ export default {
this.pageId = parseInt(pageId);
let moveLink = getCookies('moveLink');
if (Number(this.$route.query.type) === 1) {
this.iframeUrl = `${moveLink}/pages/index/index?type=iframeWindow`;
this.iframeUrl = `${moveLink}/pages/index/index?mdType=iframeWindow`;
} else {
// this.iframeUrl = `https://v4.wuht.net/pages/index/index?type=iframeWindow`;
this.iframeUrl = `${location.origin}/pages/index/index?type=iframeWindow`;
this.iframeUrl = `${location.origin}/pages/index/index?mdType=iframeWindow`;
}
diyGetInfo(parseInt(pageId)).then((datas) => {
let data = datas.data.info.value;

View File

@ -124,7 +124,7 @@
uni.hideTabBar()
let that = this;
// #ifdef H5
if (option.query.hasOwnProperty('type') && option.query.type == "iframeWindow") {
if (option.query.hasOwnProperty('mdType') && option.query.mdType == "iframeWindow") {
this.globalData.isIframe = true;
} else {
this.globalData.isIframe = false;