Commit 40aa3f2c77a38581131f8b88fccc41a6d403174c

Authored by yvan.ni
1 parent ce9392ed

收藏价的零售价显示

packageB/pages/user/collect_list/collect_list.js
... ... @@ -26,12 +26,28 @@ Page({
26 26 total_collects: 0,
27 27 is_goods: 0,
28 28 pageSize: 8, //分页数量
29   - isdelete: 0
  29 + isdelete: 0,
  30 +
  31 + is_retail_price:0
30 32 },
31 33 onLoad: function() {
32 34  
  35 + var th=this;
  36 +
33 37 o.init(this, "", "collects"),
34 38 this.requestCollectList();
  39 +
  40 +
  41 + getApp().getConfig2(function(rs){
  42 + //计算等级价相关
  43 + var swithc_list=rs.switch_list;
  44 + var sw_arr=JSON.parse(swithc_list);
  45 + if(sw_arr.is_retail_price){
  46 + th.setData({is_retail_price:1});
  47 + }
  48 +
  49 + });
  50 +
35 51 },
36 52 requestCollectList: function() {
37 53 var th = this;
... ...
packageB/pages/user/collect_list/collect_list.wxml
... ... @@ -49,10 +49,10 @@
49 49 <view class="fs40">{{item.prom_price?item.prom_price:item.final_price}}</view>
50 50 </view>
51 51 <!-- 原价 -->
52   -<!-- <view class="flex fs24 line through xc-ash">-->
53   -<!-- <view>零售价:</view>-->
54   -<!-- <view>¥{{item.market_price}}</view>-->
55   -<!-- </view>-->
  52 + <view wx:if="{{is_retail_price}}" class="flex fs24 line through xc-ash">
  53 + <view>零售价:</view>
  54 + <view>¥{{item.market_price}}</view>
  55 + </view>
56 56 </view>
57 57  
58 58 <view class="money_right flex line" wx:if="{{!editEd}}">
... ...