diff --git a/components/diy_goodsGroup/diy_goodsGroup.js b/components/diy_goodsGroup/diy_goodsGroup.js index e34e511..8d10972 100644 --- a/components/diy_goodsGroup/diy_goodsGroup.js +++ b/components/diy_goodsGroup/diy_goodsGroup.js @@ -443,7 +443,9 @@ Component({ item.cardprice1 = val.cardprice1; item.cardprice2 = val.cardprice2; item.cardprice3 = val.cardprice3; - + item.prom_type = val.prom_type; + item.prom_id = val.prom_id; + if(val.prom_price) item.prom_price = val.prom_price; if(val.prom_integral) item.prom_integral = val.prom_integral; diff --git a/components/diy_goodsGroup/diy_goodsGroup.wxml b/components/diy_goodsGroup/diy_goodsGroup.wxml index 2c0e9bc..849c7a7 100644 --- a/components/diy_goodsGroup/diy_goodsGroup.wxml +++ b/components/diy_goodsGroup/diy_goodsGroup.wxml @@ -15,7 +15,7 @@ - + @@ -169,7 +169,7 @@ - + @@ -328,7 +328,7 @@ - + @@ -485,7 +485,7 @@ - + @@ -662,7 +662,7 @@ - + diff --git a/components/goods_list/goods_list.js b/components/goods_list/goods_list.js index cb4fb85..371b5c5 100644 --- a/components/goods_list/goods_list.js +++ b/components/goods_list/goods_list.js @@ -98,6 +98,9 @@ Component({ get_list: function () { var that = this; if (that.data.is_no_more == 0) return false; + var user_id=getApp().globalData.user_id; + if(!user_id) user_id=0; + var curPage = that.data.curPage; getApp().request.get('/api/weshop/goods/page?page', { isShowLoading: false, @@ -111,6 +114,7 @@ Component({ pageSize: 6, orderField: "sort", orderType: 'asc', + user_id: user_id, }, success: function (res) { var data = res.data; @@ -124,6 +128,13 @@ Component({ } //加载完成 if (data.data.pageData) { + + for(let i in data.data.pageData){ + let item=data.data.pageData[i]; + if(item.user_price) + item.prom_price=item.user_price; + } + that.setData({ load_complete: 1 }); diff --git a/pages/goods/goodsInfo/goodsInfo.js b/pages/goods/goodsInfo/goodsInfo.js index ad88c50..04986b3 100644 --- a/pages/goods/goodsInfo/goodsInfo.js +++ b/pages/goods/goodsInfo/goodsInfo.js @@ -4441,7 +4441,7 @@ Page({ var pri0 = th.data.data.shop_price; if (th.data.prom_act) - pri0 = th.data.prom_act.price; + pri0 = th.data.prom_price; pri0 = parseFloat(pri0).toFixed(2); var wd1 = th.data.screenWidth - ut.measureText(pri0, 31 * unit) - 25; context.fillText("¥", wd1 - 15, 185 * unit);