item.wxml
625 Bytes
<wxs src="../../wxs/helper.wxs" module="helper" />
<view class="product-item" bindtap="goDetail">
<image class="item-image" mode="aspectFit" src="{{helper.image(item.defaultImages, 860, 644)}}"></image>
<view class="item-detail">
<text class="item-title">{{item.productName}}</text>
<view class="item-price">
<text class="price1" style="color:{{item.showOriginPrice ? '#d0021b' : '#444444'}}">¥{{helper.round(item.salePriceStr)}}</text>
<text class="price2" wx:if="{{item.showOriginPrice}}">¥{{helper.round(item.originPriceStr)}}</text>
</view>
</view>
</view>