@@ -61,6 +61,7 @@ Component({
} catch (error) {
}
+ v.isShowOldPrice = v.marketprice > v.defaultprice
v.defaultprice = CNY(v.defaultprice)
v.marketprice = CNY(v.marketprice)
v.defaultamount = CNY(v.defaultamount)
@@ -29,7 +29,7 @@
</view>
<view style="margin-top: 8rpx;">
<text class="price">{{item.defaultprice}}{{language['元']||'元'}}</text>
- <text class="old-price">{{item.marketprice}}{{language['元']||'元'}}</text>
+ <text class="old-price" wx:if="{{item.isShowOldPrice}}">{{item.marketprice}}{{language['元']||'元'}}</text>
<view wx:if="{{!disabled}}" class="delete" data-item="{{item}}" catchtap="deleteProduct">