index.wxml 1.1 KB

12345678910111213141516171819202122
  1. <view class="address-container">
  2. <view class="address-list" wx:if="{{addressList.length > 0}}">
  3. <block wx:for="{{addressList}}" wx:for-index="index" wx:for-item="address" wx:key="addressId">
  4. <t-addritem isDrawLine="{{index+1 !== addressList.length}}" extra-space="{{selectMode}}" address="{{address}}" data-id="{{address.id}}" bind:onSelect="selectHandle" bind:onDelete="deleteAddressHandle" bind:onEdit="editAddressHandle" />
  5. </block>
  6. </view>
  7. <view wx:else class="no-address">
  8. <t-empty icon="" description="暂无收货地址,赶快添加吧" />
  9. </view>
  10. <view class="bottom-fixed">
  11. <view class="btn-wrap">
  12. <view />
  13. <view class="address-btn {{addressList.length >= 20 ? 'btn-default':''}}" bind:tap="addAddress">
  14. <t-icon name="add" size="32rpx" color="#fff" t-class="custom-class" />
  15. <view style="font-size: 30rpx;">新建收货地址</view>
  16. </view>
  17. </view>
  18. <view class="footer" wx:if="{{addressList.length >= 20}}">最多支持添加20个收货地址</view>
  19. </view>
  20. </view>
  21. <t-toast id="t-toast" />
  22. <n-wait loading="{{wait}}" />