cart.wxml 9.0 KB
<!--pages/cart/cart.wxml-->
<view class='page'>
        <view class='cart_box'>
                <view class='top_label'>
                        购物车
                        <view class='del_btn' bindtap='del_btn'>删除 </view>
                </view>
                <view class='tips'>
                        <view class='left'>
                                <view class='note'>提示</view>满{{listlist.shipment.free}}元包邮,还差{{ship_balance}}包邮
                        </view>
                        <view class='right' catchtap='get_return'>再逛逛
                                <icon class='iconfont icon-icondayu'></icon>
                        </view>
                </view> 
                <!-- 商品列表 -->
                <view class='da'>
                        <view class='product_list' wx:if='{{goodsList.length>0||promotion.length>0}}'>
                                <view class='singlepart' wx:for='{{goodsList}}' wx:for-item='cell' wx:for-index='cellindex' wx:key='{{cellindex}}'>
                                        <view class='single_part_top'>
                                                <view class='single_part_left'>
                                                        <view class='iconfont icon-weixuanzhong {{cell.chooseAll?"active":""}}' bindtap='chooseAll'></view>
                                                        {{cell.name}}
                                                </view>
                                                <!-- <view class='single_part_right'>
                                        鲜橙促销 买1送1
                                        <view class='iconfont icon-icondayu'></view>
                                </view> -->
                                        </view>
                                        <view class='single_part_items'>
                                                <view class='single_part_item' wx:for='{{cell.list}}' wx:key='*this' wx:for-index='index' wx:for-item='value' data-id='{{value.product_id}}' bindtap='goDetail'>
                                                        <view class='iconfont icon-weixuanzhong {{value.flag?"active":""}}' data-cell='{{cellindex}}' catchtap='choose' data-id='{{value.id}}' data-flag='{{value.flag}}' data-index='{{index}}'></view>
                                                        <view class='single_part_imgbox'>
                                                                <image src='{{value.more.thumbnail}}' mode='widthFix'></image>
                                                        </view>
                                                        <view class='single_part_detail'>
                                                                <view class='product_title'>{{value.title}}</view>
                                                                <view class='product_type'>{{value.sku_values}}</view>
                                                                <view class='product_action'>
                                                                        <view class='price'>¥
                                                                                 <text class='detail_price'>{{value.goods_price}}</text>
                                                                        </view>
                                                                        <view class='action_box'>
                                                                                <view class='short action_btn' catchtap='dec' data-number='{{value.number}}' data-index='{{index}}' data-cellindex='{{cellindex}}'>-</view>
                                                                                <view class='detail_num'>{{value.number}}</view>
                                                                                <view class='action_btn' catchtap='add' data-limit='{{value.limit_numer}}' data-number='{{value.number}}' data-index='{{index}}' data-cellindex='{{cellindex}}'>+</view>
                                                                        </view>
                                                                </view>
                                                        </view>
                                                </view>
                                        </view>
                                </view>
                                <view class='singlepart' data-id='{{cell.id}}' bindtap='goDetail2' wx:for='{{promotion}}' wx:for-item='cell' wx:for-index='cellindex' wx:key='{{cellindex}}'>
                                        <view class='single_part_top'>
                                                <view class='single_part_left'>
                                                        <view class='iconfont icon-weixuanzhong {{cell.chooseAll?"active":""}}' catchtap='chooseAll2'></view>
                                                        {{cell.name}}
                                                </view>
                                                <!-- <view class='single_part_right'>
                                        鲜橙促销 买1送1
                                        <view class='iconfont icon-icondayu'></view>
                                </view> -->
                                        </view>
                                        <view class='single_part_items'>
                                                <view class='single_part_item' wx:for='{{cell.list}}' wx:key='*this' wx:for-index='index' wx:for-item='value'>
                                                        <view class='iconfont icon-weixuanzhong {{value.flag?"active":""}}' catchtap='choose2' data-cell='{{cellindex}}' data-id='{{value.id}}' data-flag='{{value.flag}}' data-index='{{index}}'></view>
                                                        <view class='single_part_imgbox'>
                                                                <image src='{{value.more.thumbnail}}' mode='widthFix'></image>
                                                        </view>
                                                        <view class='single_part_detail'>
                                                                <view class='product_title'>{{value.title}}</view>
                                                                <view class='product_type'>{{value.sku_values}}</view>
                                                                <view class='product_action'>
                                                                        <view class='price'>¥
                                                                                <text class='detail_price'>{{value.goods_price}}</text>
                                                                        </view>
                                                                        <!-- <view class='action_box'>
                                                                                <view class='short action_btn' catchtap='dec2' data-number='{{value.number}}' data-index='{{index}}' data-cellindex='{{cellindex}}'>-</view>
                                                                                <view class='detail_num'>{{value.number}}</view>
                                                                                <view class='action_btn' catchtap='add2' data-limit='{{value.limit_numer}}'  data-number='{{value.number}}' data-index='{{index}}' data-cellindex='{{cellindex}}'>+</view>
                                                                        </view> -->
                                                                </view>
                                                        </view>
                                                </view>
                                        </view>
                                </view>
                        </view>
                        <view wx:if='{{goodsList.length==0&&promotion.length==0}}' class='gogogo'>
                                <image src='../imgs/noCart.png'></image>
                                <view>您暂时没有需要结算的商品哦~</view>
                        </view>
                </view>


        </view>
        <view class='bottom_ac'>
                <view class='choose' bindtap='allBothChoose'>
                        <view class='iconfont icon-weixuanzhong {{all_both_choose?"active":""}}'></view> 全选
                </view>
                <view class='count'>
                        <view class='count_top'>
                                合计:
                                <view class='price'>¥
                                        <text class='detail_price'>{{totalPrice}} </text>
                                </view>
                        </view>
                        <view class='fee'>
                                含运费{{shipPrice}}元
                        </view>
                </view>
                <view class='count_btn' bindtap='settleAccountGoods'>
                        <!-- 原来是account -->
                        结算
                </view>
        </view>
</view>