cart.wxml
4.2 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
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
<!-- 删除购物车成功 -->
<view class="register" bindtap="hidedel" wx:if="{{delshow}}">
<view class="delwrap">
<view class="delsuccess">
<image src='/img/delsuccess.png'></image>
</view>
<view class="delname">删除成功</view>
</view>
</view>
<!-- 是否删除购物车 -->
<view class="register" wx:if="{{hidedelcart}}" bindtap="hidecart">
<view class="delcartwrap">
<view class="delcatname">确认你已选中的商品删除吗</view>
<view class="delbottom">
<view class="delbottomleft" catchtap='cancelhidecar'>取消</view>
<view class="delbottomright" catchtap='surecancelcar'>确定</view>
</view>
</view>
</view>
<view class="manage" bindtap="manage">
<view class="manageitem">
<view class="manageimg">
<image src="/img/seetingimger.png"></image>
</view>
<view class="guanli" wx:if="{{delalldshow==false}}">管理</view>
<view class="guanli" wx:else>完成</view>
</view>
</view>
<view class="nodata" wx:if="{{cartlist.length==0}}">暂无数据</view>
<view class="cartbox" wx:else>
<view class="cartboxitem" wx:for="{{cartlist}}" wx:key=''>
<view class="xuancar" bindtap="selcart" data-id="{{item.id}}">
<view class="cartboxitemleft" >
<image src="/img/nosel.png" wx:if="{{item.sel==false}}"></image>
<image src="/img/selcart.png" wx:else></image>
</view>
</view>
<view class="cartboxitemright">
<view class="goodkindbox">
<view class='goodkindrightitemleft'>
<view class="goodkindleftimg">
<image src="{{item.image}}"></image>
</view>
<view class="xiename">
<view class="xienameleft">
<image src="/img/good.png"></image>
</view>
<view class="goodname">{{item.goods_name}}</view>
</view>
<view class="attr" wx:for="{{goods_standard}}" wx:key=''>
<view class="goodbottomright attritem">{{item}}</view>
</view>
</view>
<view class="songk">
<image src="/img/send.png"></image>
</view>
<view class='goodkindrightitemleft'>
<view class="goodkindleftimg">
<image src="{{item.gift.image}}"></image>
</view>
<view class="xiename">
<view class="xienameleft">
<image src="/img/zeng.png"></image>
</view>
<view class="goodname">{{item.gift.goods_name}}</view>
</view>
<view class="attr" wx:for="{{goods_standard}}" wx:key=''>
<view class="goodbottomright attritem">{{item}}</view>
</view>
</view>
</view>
<view class="goodkindprice">
<view class="goodkindpriceleft">
¥{{item.price}}
</view>
<view class="goodkindpriceright" wx:if="{{item.freight=='0.00'}}">运费:免运费</view>
<view class="goodkindpriceright" wx:else>运费:{{item.freight}}元</view>
<view class="goodkindpriceright" wx:if="{{item.gift.freight=='0.00'}}">运费:免运费</view>
<view class="goodkindpriceright" wx:else>运费:{{item.gift.freight}}元</view>
</view>
<view class="goodkind">
<view class="goodkindnum">
<view class="goodkindnumleft" bindtap="reducecartnum" data-id="{{item.id}}">
<image src="/img/jian.png"></image>
</view>
<view class="goodnum">{{item.number}}</view>
<view class="goodkindnumleft" bindtap="addcartnum" data-id="{{item.id}}">
<image src="/img/add.png"></image>
</view>
</view>
</view>
</view>
</view>
</view>
<view class="cartbottom" wx:if="{{delalldshow}}">
<view class="cartbottomleft">
<view class="cartbottomleftsel" bindtap="selquan">
<image src="/img/selcart.png" wx:if="{{selall}}"></image>
<image src="/img/nosel.png" wx:else></image>
</view>
<view class="cartbottomleftname">全选</view>
</view>
<view class="cartbottomright" bindtap="delcart">删除</view>
</view>
<view class="cartbottom" wx:else>
<view class="cartbottomleft">
<view class="totalmoney">总计:{{totalmoney}}</view>
</view>
<view class="cartbottomright" bindtap="jiesuan">结算</view>
</view>