shopping-cart.wxml
3.7 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
<!--pages/shopping-cart/shopping-cart.wxml-->
<view class="container">
<!-- 地址 -->
<view class="userInfo" bindtap="goAddress">
<view class="addHint" wx:if="{{addHint==false}}">
<view class="addItem1">暂未获取到收获地址</view>
<view class="addItem2"> 请选择收货地址</view>
</view>
<view wx:if="{{addHint==true}}">
<view class="userName">{{userData.name}}</view>
<view class="userTell">{{userData.phone}}</view>
<view class="default" wx:if="{{userData.delFlag==1}}">默认</view>
<view class="userAddress">{{userData.area}}{{userData.address}}</view>
<view class="arrow">
<image src="/images/04-01/arrow.png"></image>
</view>
</view>
</view>
<!-- 配送时间 -->
<view class="timeBox">
<view class="calendar ">
<image src="/images/04-01/rili.png"></image>
</view>
<view class="section">
<picker mode="date" value="{{date}}" bindchange="bindDateChange" start="{{startTime}}">
<view class="picker">
配送时间: {{date}}
</view>
</picker>
</view>
</view>
<!-- 购物车 -->
<view class="main">
<view wx:if="{{hasList}}">
<view class="cart-box">
<view class="cart-list" wx:for="{{carts}}" wx:key="{{index}}" data-goodsid="{{item.goodsId}}"
bindtap="goDetail">
<icon wx:if="{{item.selected}}" type="success" color="#FF4903" data-index="{{index}}" class="cart-pro-select"
catchtap="selectList" />
<icon wx:else type="circle" class="cart-pro-select" data-index="{{index}}" catchtap="selectList" />
<navigator url="../details/details?id={{item.id}}">
<image class="cart-thumb" src="{{item.goodsImg}}"></image>
</navigator>
<text class="cart-pro-name">{{item.goodsName}}</text>
<text class="cart-pro-desc">{{item.goodsAttributes}}</text>
<text class="cart-pro-price">¥{{item.goodsPrice}}</text>
<view class="cart-count-box">
<text class="cart-count-down" catchtap="minusCount" data-obj="{{obj}}" data-index="{{index}}"
data-goodSkuId="{{item.goodsSkuId}}">-</text>
<text class="cart-count-num">{{item.num}}</text>
<text class="cart-count-add" catchtap="addCount" data-index="{{index}}"
data-goodSkuId="{{item.goodsSkuId}}">+</text>
</view>
<text class="cart-del" catchtap="deleteList" data-index="{{index}}" data-cartId="{{item.cartId}}"
data-goodSkuId="{{item.goodsSkuId}}">×</text>
</view>
</view>
<!-- <view class="cart-footer">
<icon wx:if="{{selectAllStatus}}" type="success_circle" color="#fff" class="total-select" bindtap="selectAll" />
<icon wx:else type="circle" color="#fff" class="total-select" bindtap="selectAll" />
<view class="order-icon">
<navigator url="../orders/orders">
<image src="/image/icon3.png"></image>
</navigator>
</view>
<text>全选</text>
<text class="cart-toatl-price">¥{{totalPrice}}</text>
</view> -->
</view>
<view wx:if="{{carts.length==0}}">
<view class="cart-no-data">一件商品都没有呢</view>
<view class="cart-no-data-btn" bindtap="goHome">去逛逛</view>
</view>
</view>
<!-- 立即购买 -->
<view class="bottom">
<!-- <view class="checkPic">
<image src="/images/04-01/uncheck.png"></image>
</view> -->
<view class="checkText">
已选({{checkNum}})
</view>
<view class="totalText">合计:</view>
<view class="totalPrice">
<view class="icon">¥</view>
<view class="number">{{totalPrice}}</view>
</view>
<view class="buyText" catchtap='immediatelyPay'>
立即购买
</view>
</view>
</view>