cart.wxml 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. <view>
  2. <view class="manage">
  3. <text bindtap="manageBut">{{isManage?"完 成":"管 理"}}</text>
  4. </view>
  5. <!-- 暂无可管理商品 -->
  6. <view class="empty" wx:if="{{false}}">
  7. <image class="emptyIcon" src="/images/cart/empty.png" alt=""/>
  8. <text>暂无可管理商品</text>
  9. </view>
  10. <!-- 商品列表 -->
  11. <view class="prodsList">
  12. <checkbox-group bindchange="handleCheckboxChange">
  13. <view class="itemProd" wx:for="{{cartList}}" wx:key="id">
  14. <checkbox value="{{item.id}}" checked="{{item.checkFlag === '1'}}"></checkbox>
  15. <view class="goods-info">
  16. <image src="/images/index/category-item.png" mode="aspectFill"></image>
  17. <view class="info">
  18. <text>{{item.prodName}}</text>
  19. <text>{{item.prodAttrName}}</text>
  20. <text>¥{{item.price}}</text>
  21. </view>
  22. <view class="count">
  23. <text class="reduceNum" bindtap="decreaseCount" data-id="{{item.id}}">-</text>
  24. <text class="num">{{item.quantity}}</text>
  25. <text class="addNum" bindtap="increaseCount" data-id="{{item.id}}">+</text>
  26. </view>
  27. </view>
  28. </view>
  29. </checkbox-group>
  30. </view>
  31. <!-- 推荐 -->
  32. <view class="recommend">
  33. <view class="divider">
  34. <text class="line"></text>
  35. <text class="text">更多个性化推荐</text>
  36. <text class="line"></text>
  37. </view>
  38. <product-list position="hot"></product-list>
  39. </view>
  40. <!-- 底部全选和总价 -->
  41. <view class="footer {{isManage && 'manageFooter'}}" >
  42. <label class="checkBoxAll">
  43. <checkbox value="all" checked="{{isAllChecked}}" bindtap="toggleAll">全 选</checkbox>
  44. </label>
  45. <text wx:if="{{!isManage}}">合计:¥{{totalPrice}}</text>
  46. <text wx:if="{{!isManage}}">确认下单</text>
  47. <view class="delete" wx:if="{{isManage}}" catchtap="deleteProd">删 除</view>
  48. </view>
  49. </view>