diff --git a/app.js b/app.js index c7f1316..ada7707 100644 --- a/app.js +++ b/app.js @@ -38,7 +38,7 @@ App({ // 获取前端配置文件 commonApi._post("pbservice/Other/getClientConfig", {unique_key: "wechatxcx"}).then(res => { let data = JSON.parse(res.data); - data.isTest = data.isTest156? true : false; + data.isTest = data.isTest158? true : false; data.indexSeason = null this.globalData.configJson = data }).then(() => { diff --git a/pages/index/index.js b/pages/index/index.js index 933286c..dd5bdeb 100644 --- a/pages/index/index.js +++ b/pages/index/index.js @@ -541,8 +541,8 @@ Page({ func_data: (app.globalData.configJson.func_data||{}) }) } else { - // 小程序是3 - commonApi._post("adv/get_home_ui", {type_id: 15}).then(res => { + // 小程序是3 测试H5 15 + commonApi._post("adv/get_home_ui", {type_id: 3}).then(res => { let obj = {}; (res.data.content||[]).forEach(item => { obj[item.id] = item.image diff --git a/pages/order/road/index.js b/pages/order/road/index.js index 560b19a..7a18266 100644 --- a/pages/order/road/index.js +++ b/pages/order/road/index.js @@ -98,20 +98,22 @@ Page({ stock = stock+i.stock; }) item.stock = stock; - if(item.stock>0){ + // if(item.stock>0){ + if (item.info.some(x=>x.stock!=null)){ let date = item.date.split("-").splice(1,2),newDate=[]; console.log(date) date.map(d=>{ d = parseInt(d); newDate.push(d) }) - if(!selectDate){ + if(!selectDate&&item.stock>0){ selectDate = newDate[1]; selectMonth = newDate[0]; } prices[newDate.join("-")] = item; } }) + console.log(prices, "---------------") this.setData({ prices:prices }) diff --git a/pages/order/road/index.wxml b/pages/order/road/index.wxml index 2805bf9..f35be0e 100644 --- a/pages/order/road/index.wxml +++ b/pages/order/road/index.wxml @@ -23,9 +23,9 @@ - {{(index+1)>=10?(index+1):("0"+(index+1))}} - ¥{{prices[month[monthIndex]+'-'+(index+1)].m_price/100}} - 售罄 + {{(index+1)>=10?(index+1):("0"+(index+1))}} + ¥{{prices[month[monthIndex]+'-'+(index+1)].m_price/100}} + 售罄 diff --git a/project.private.config.json b/project.private.config.json index 0ac6dc1..e6ba547 100644 --- a/project.private.config.json +++ b/project.private.config.json @@ -9,10 +9,17 @@ { "name": "pages/info/roadInfo/index", "pathName": "pages/info/roadInfo/index", - "query": "id=3897", + "query": "id=457033", "scene": null, "launchMode": "default" }, + { + "name": "pages/info/roadInfo/index", + "pathName": "pages/info/roadInfo/index", + "query": "id=3897", + "launchMode": "default", + "scene": null + }, { "name": "pages/user/order/postOrderInfo/index", "pathName": "pages/user/order/showOrderInfo/index",