index.wxml 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. <!-- 导航栏 -->
  2. <van-nav-bar custom-style="background-color: #407DB8">
  3. <van-icon slot="left" name="arrow-left" size="25px" color="#fff" bind:click="backToParent"/>
  4. <text slot="title" style="color: #fff;">收货地址管理</text>
  5. </van-nav-bar>
  6. <van-cell-group>
  7. <!-- 收货人 -->
  8. <van-field model:value="{{ username }}" adjust-position required clearable label="收货人" placeholder="请输入收货人" />
  9. <!-- 联系电话 -->
  10. <van-field model:value="{{ mobile }}" adjust-position type="number" required clearable label="联系电话" placeholder="请输入收货人联系电话"/>
  11. <!-- 收货地区 -->
  12. <view class="region">
  13. <text class="label">*收货地区</text>
  14. <view class="region-selsct" id="region-selsct" bindtap="onButtonPressed">{{region}}</view>
  15. <van-icon name="arrow" size="10px" color="#666" />
  16. </view>
  17. <view class="default" wx:if="{{autoid != 0}}">
  18. <text class="label">设为默认</text>
  19. <van-switch checked="{{ checked }}" active-color="#07c160" bind:change="onChange"/>
  20. </view>
  21. <!-- 详细地址 -->
  22. <van-field model:value="{{ detailAddress }}" adjust-position required clearable autosize label="详细地址" placeholder="请输入详细地址"/>
  23. </van-cell-group>
  24. <!-- 底部视图 -->
  25. <view class="buttom_view">
  26. <van-button round id = "confirm" color="#407DB8" block style="width: 90%; padding-top: 5px; padding-top: 10px;" bind:click="onButtonPressed">确定</van-button>
  27. <van-button wx:if="{{ autoid != 0}}" id="delete" round color="linear-gradient(to right, #999, #aaa)" block style="width: 90%; padding-top: 5px; padding-top: 10px;" bind:click="onButtonPressed">删除地址</van-button>
  28. </view>
  29. <!-- 地区选择 -->
  30. <van-popup show="{{ show }}" position="bottom" custom-style="height: 45%" bind:click-overlay="cancelArea">
  31. <van-area area-list="{{ areaList }}" value="110101" title="地区选择" bind:cancel="cancelArea" bind:confirm="confirmArea"/>
  32. </van-popup>
  33. <!-- toast -->
  34. <van-toast id="van-toast" />