Commit f44c678b by 李嘉林

fix

parent aed04ee7
...@@ -23,7 +23,7 @@ module.exports = merge(prodEnv, {//zjgyl ...@@ -23,7 +23,7 @@ module.exports = merge(prodEnv, {//zjgyl
OLSHOP_URL:'"https://m.xinhuabest.com/innerApi/shopApiService"', OLSHOP_URL:'"https://m.xinhuabest.com/innerApi/shopApiService"',
// OLSHOP_URL:'"https://shop.mayi888.com/innerApi/shopApiService"', // OLSHOP_URL:'"https://shop.mayi888.com/innerApi/shopApiService"',
IMG_DOMAIN: '"https://new-xhyx.obs.cidc-rp-2005.joint.cmecloud.cn"', IMG_DOMAIN: '"https://prod-xhyx.obs.cidc-rp-12.joint.cmecloud.cn"',
POSTHOG_KEY: '"phc_nTr1oY7NkSuDMZsqCskE6iUIGKgWPmFHlRAKFVuZD2B"', POSTHOG_KEY: '"phc_nTr1oY7NkSuDMZsqCskE6iUIGKgWPmFHlRAKFVuZD2B"',
POSTHOG_HOST: '"https://posthog.mayi118.com"', POSTHOG_HOST: '"https://posthog.mayi118.com"',
MANALYTICS_HOST: '"https://bi.xinhuabest.com/log/xinhua.gif"', MANALYTICS_HOST: '"https://bi.xinhuabest.com/log/xinhua.gif"',
......
...@@ -67,7 +67,10 @@ export default { ...@@ -67,7 +67,10 @@ export default {
loadComponents(index) { loadComponents(index) {
this.contentList.push(this.pageData[index]); this.contentList.push(this.pageData[index]);
index++; index++;
if (index > this.pageData.length) return console.log("-微页面渲染结束-"); if (index > this.pageData.length) {
console.log("-微页面渲染结束-");
return;
}
setTimeout(() => { setTimeout(() => {
this.loadComponents(index); this.loadComponents(index);
}, 30); }, 30);
......
...@@ -10,9 +10,6 @@ ...@@ -10,9 +10,6 @@
<StoreAddr @toUpdate="reloadEnterShopRule" @toPageLoading="toPageLoading" ref="StoreAddr"></StoreAddr> <StoreAddr @toUpdate="reloadEnterShopRule" @toPageLoading="toPageLoading" ref="StoreAddr"></StoreAddr>
<ThemeDataPlant></ThemeDataPlant> <ThemeDataPlant></ThemeDataPlant>
<div v-for="(item,index) in pageData" :key="index"> <div v-for="(item,index) in pageData" :key="index">
<div v-if="item.componentCode == 'embed-module' && item.componentInfo.visible == 1">
<embedModule :datas="item" :componentIndex="index"></embedModule>
</div>
<div v-if="item.componentCode=='banner' && item.componentInfo.visible == 1"> <div v-if="item.componentCode=='banner' && item.componentInfo.visible == 1">
<banner :datas="item"></banner> <banner :datas="item"></banner>
</div> </div>
...@@ -119,6 +116,9 @@ ...@@ -119,6 +116,9 @@
<div v-if="item.componentCode == 'brand-list' && item.componentInfo.visible == 1"> <div v-if="item.componentCode == 'brand-list' && item.componentInfo.visible == 1">
<brandList :datas="item"></brandList> <brandList :datas="item"></brandList>
</div> </div>
<div v-if="item.componentCode == 'embed-module' && item.componentInfo.visible == 1">
<embedModule :datas="item" :componentIndex="index"></embedModule>
</div>
</div> </div>
<template> <template>
</template> </template>
...@@ -206,7 +206,8 @@ export default { ...@@ -206,7 +206,8 @@ export default {
data() { data() {
return { return {
pageInfo: {}, pageInfo: {},
pageData: {}, pageData: [],
contentList: [],
themeColor:{ themeColor:{
'--main-color':"", '--main-color':"",
'--minor-color':"", '--minor-color':"",
...@@ -744,7 +745,11 @@ export default { ...@@ -744,7 +745,11 @@ export default {
this.active=checkTabbarPage('/'); this.active=checkTabbarPage('/');
this.setVisible(this.mpApp.globalData.pageList,(res)=>{ this.setVisible(this.mpApp.globalData.pageList,(res)=>{
this.pageInfo = res; this.pageInfo = res;
this.pageData = JSON.parse(this.pageInfo.pageData); this.contentList = JSON.parse(this.pageInfo.pageData);
this.pageData.push(this.contentList[0]);
console.log(this.pageData,'--this.pageData')
let i = 1;
this.loadComponents(i);
}); });
setTimeout(() => { setTimeout(() => {
this.showbottomCont = true; this.showbottomCont = true;
...@@ -809,6 +814,17 @@ export default { ...@@ -809,6 +814,17 @@ export default {
} }
} }
}, },
loadComponents(index) {
this.pageData.push(this.contentList[index]);
index++;
if (index > this.contentList.length - 1) {
console.log("-页面渲染结束-");
return;
}
setTimeout(() => {
this.loadComponents(index);
}, 30);
},
getSpokesmanInit(extConfig) { getSpokesmanInit(extConfig) {
log.info(extConfig,'getSpokesmanInit-extConfig'); log.info(extConfig,'getSpokesmanInit-extConfig');
//绑定上下级关系 //绑定上下级关系
......
...@@ -540,7 +540,7 @@ const componentOptions = { ...@@ -540,7 +540,7 @@ const componentOptions = {
var that = this var that = this
let storageDatasList = this.getStorageSync('storageDatasList') || [] let storageDatasList = this.getStorageSync('storageDatasList') || []
let { style } = storageDatasList[that.data.datasIndex]; let style = storageDatasList[that.data.datasIndex].style || "";
if (!style) return; if (!style) return;
let type = '' let type = ''
if(style == 'list' || style == 'rowList'){ if(style == 'list' || style == 'rowList'){
......
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