item.wxml
3.54 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
<wxs src="../../../wxs/helper.wxs" module="helper" />
<view class="goods-item" bindtouchstart="touchStartAction" bindtouchend="touchEndAction">
<scroll-view scroll-x="true" scroll-left="{{scrollLeft}}" scroll-with-animation="true" bindscroll="onScoll">
<view class="scoll-wrap" style="padding-right: {{slideWidth}}px;">
<view class="goods-item-wrap">
<view class="choose-btn" bindtap="chooseItemAction">
<block wx:if="{{item.goods_type !== 'gift' && !item.batch_no && !item.bundle_activity_id && !isInvalid}}">
<text class="iconfont icon-duihao-fill" wx:if="{{item.selected === 'Y'}}"></text>
<text class="iconfont icon-round" wx:else></text>
</block>
<view class="invalid-tag" wx:if="{{isInvalid}}">失效</view>
</view>
<image class="thumb" src="{{helper.image(item.goods_images || item.goods_image, 152, 200, 2, 100)}}" bindtap="navToDetailAction">
<block wx:if="{{!isInvalid}}">
<view class="goods-type price-gift-tag" wx:if="{{item.goods_type === 'price_gift'}}">
<text>加价购</text>
</view>
<view class="goods-type gift-tag" wx:if="{{item.goods_type === 'gift'}}">
<text>赠品</text>
</view>
<view class="goods-type virtual-tag" wx:if="{{item.goods_type === 'ticket'}}">
<text>虚拟商品</text>
</view>
<view class="goods-type advance-tag" wx:if="{{item.goods_type === 'advance'}}">
<text>预售</text>
</view>
<view class="goods-type low-storage-tag" wx:if="{{item.goods_type === 'lowStorage'}}">
<text>库存不足</text>
</view>
</block>
</image>
<view class="info">
<view class="info-wrap">
<view class="name" bindtap="navToDetailAction">{{item.product_name}}</view>
<block wx:if="{{!isInvalid}}">
<view class="color-size">颜色:{{item.factory_goods_name}} 尺码:{{item.size_name}}</view>
<view class="price">
<text class="sale-price">¥ {{helper.round(item.sales_price)}}</text>
<text wx:if="{{item.mark_price}}" class="mark-price">¥ {{helper.round(item.mark_price)}}</text>
<text class="vip-price-tig" wx:if="{{item.isVipPrice}}">VIP</text>
</view>
<!-- <view class="price-down" wx:if="{{item.price_down > 0}}">
<text>已降¥{{item.price_down}}</text>
</view> -->
<view class="info-edit" wx:if="{{isEditing}}">
<view class="edit-block">
<cart-edit goods="{{item}}" bind:editGoodsNum="editGoodsNum" bind:editGoodsColorSize="editGoodsColorSize"></cart-edit>
<view class="price">
<text class="sale-price">¥ {{helper.round(item.sales_price)}}</text>
<text wx:if="{{item.mark_price}}" class="mark-price">¥ {{helper.round(item.mark_price)}}</text>
<text class="vip-price-tig" wx:if="{{item.isVipPrice}}">VIP</text>
</view>
</view>
</view>
</block>
</view>
</view>
<view class="buy-num">
<text>x {{item.buy_number}}</text>
</view>
</view>
<view id="del-btn" class="del-btn" bindtap="removeItemAction" style="padding-right: {{slideWidth}}px;"></view>
</view>
</scroll-view>
<view class="del-text" style="width: {{slideWidth}}px;">
<text>删除</text>
</view>
</view>