add-address.wxml
1.5 KB
<!--pages/add-address/add-address.wxml-->
<view class="container">
<van-cell-group class="addContent">
<van-field value="{{ username }}" clearable label="姓名" icon="question-o" placeholder="请输入姓名"
bind:click-icon="onClickIcon" bindinput="inputName" />
<van-field value="{{ phone }}" label="电话" placeholder="请输入电话" bindinput="inputDel" bindblur="blurPhone" />
<view class="location" catchtap="map">
<text style="width:200rpx">收货地址</text>
<text class="locationItem">{{location}}</text>
</view>
<!-- </van-cell> -->
<van-popup show="{{ show }}" bind:close="onClose" position="bottom" custom-style="height: 30%">
<van-area area-list="{{ areaList }}" value="area" columns-placeholder="{{ ['请选择', '请选择', '请选择'] }}"
bind:change="changeAddress" bind:confirm="chooseAddress" bind:cancel="cancelChoose">{{city}}</van-area>
</van-popup>
<van-field value="{{ value }}" label="详细地址" placeholder="请输入详细地址" bindinput="inputAddress" />
</van-cell-group>
<!-- 默认地址 -->
<view class="defaultAddress">
<view class="defaultText">设为默认地址</view>
<view class="switch">
<van-switch checked="{{ checked }}" bind:change="onChange" inactive-color="#d3d3d3" size="48rpx"
style="margin-left:-60rpx" />
</view>
</view>
<!-- 保存删除 -->
<view class="save" bindtap="save">保存</view>
<view class="del">删除</view>
</view>