|
@ -4,7 +4,7 @@ |
|
|
<navbar title="地址管理" leftClick @leftClick="leftClick" /> |
|
|
<navbar title="地址管理" leftClick @leftClick="leftClick" /> |
|
|
|
|
|
|
|
|
<view v-if="addressList.length > 0" class="address-list"> |
|
|
<view v-if="addressList.length > 0" class="address-list"> |
|
|
<uv-radio-group v-model="selectAddress"> |
|
|
|
|
|
|
|
|
<!-- <uv-radio-group v-model="selectAddress"> |
|
|
<view v-for="item in addressList" :key="item.id" class="address-item"> |
|
|
<view v-for="item in addressList" :key="item.id" class="address-item"> |
|
|
|
|
|
|
|
|
<view class="address-item-top"> |
|
|
<view class="address-item-top"> |
|
@ -39,19 +39,23 @@ |
|
|
|
|
|
|
|
|
<view class="edit-btn"> |
|
|
<view class="edit-btn"> |
|
|
<uv-icon name="edit-pen"></uv-icon> |
|
|
<uv-icon name="edit-pen"></uv-icon> |
|
|
<!-- <image src="@/static/address/edit-icon.png" mode="aspectFill"></image> --> |
|
|
|
|
|
<text @click="getAddressDetail(item.id)" class="control-title">编辑</text> |
|
|
<text @click="getAddressDetail(item.id)" class="control-title">编辑</text> |
|
|
</view> |
|
|
</view> |
|
|
|
|
|
|
|
|
<view class="del-btn"> |
|
|
<view class="del-btn"> |
|
|
<uv-icon name="trash"></uv-icon> |
|
|
<uv-icon name="trash"></uv-icon> |
|
|
<!-- <image src="@/static/address/delete-icon.png" mode="aspectFill"></image> --> |
|
|
|
|
|
<text class="control-title" @click="deleteAddress(item.id)">删除</text> |
|
|
<text class="control-title" @click="deleteAddress(item.id)">删除</text> |
|
|
</view> |
|
|
</view> |
|
|
|
|
|
|
|
|
</view> |
|
|
</view> |
|
|
</view> |
|
|
</view> |
|
|
</uv-radio-group> |
|
|
|
|
|
|
|
|
</uv-radio-group> --> |
|
|
|
|
|
<addressList |
|
|
|
|
|
controls |
|
|
|
|
|
@deleteAddress="deleteAddress" |
|
|
|
|
|
@editAddress="getAddressDetail" |
|
|
|
|
|
@editDefault="addDefault" |
|
|
|
|
|
:addressList="addressList"/> |
|
|
</view> |
|
|
</view> |
|
|
|
|
|
|
|
|
<view |
|
|
<view |
|
@ -81,12 +85,13 @@ |
|
|
|
|
|
|
|
|
<script> |
|
|
<script> |
|
|
import redactAddress from '../components/address/redactAddress.vue' |
|
|
import redactAddress from '../components/address/redactAddress.vue' |
|
|
|
|
|
|
|
|
|
|
|
import addressList from '../components/address/addressList.vue' |
|
|
import Position from '@/utils/position.js' |
|
|
import Position from '@/utils/position.js' |
|
|
|
|
|
|
|
|
export default { |
|
|
export default { |
|
|
components: { |
|
|
components: { |
|
|
redactAddress |
|
|
|
|
|
|
|
|
redactAddress, |
|
|
|
|
|
addressList |
|
|
}, |
|
|
}, |
|
|
data() { |
|
|
data() { |
|
|
return { |
|
|
return { |
|
@ -351,114 +356,114 @@ |
|
|
.address-list { |
|
|
.address-list { |
|
|
padding: 40rpx 20rpx 120rpx 20rpx; |
|
|
padding: 40rpx 20rpx 120rpx 20rpx; |
|
|
|
|
|
|
|
|
.address-item { |
|
|
|
|
|
background: white; |
|
|
|
|
|
border-radius: 20rpx; |
|
|
|
|
|
overflow: hidden; |
|
|
|
|
|
margin-bottom: 20rpx; |
|
|
|
|
|
padding: 15rpx 15rpx 0rpx 15rpx; |
|
|
|
|
|
width: 680rpx; |
|
|
|
|
|
|
|
|
|
|
|
.address-item-top { |
|
|
|
|
|
border-bottom: 1px dashed #D3D1D1; |
|
|
|
|
|
display: flex; |
|
|
|
|
|
align-items: center; |
|
|
|
|
|
padding: 0rpx 0rpx 15rpx 0rpx; |
|
|
|
|
|
|
|
|
|
|
|
.img-box { |
|
|
|
|
|
width: 120rpx; |
|
|
|
|
|
height: 120rpx; |
|
|
|
|
|
|
|
|
|
|
|
image { |
|
|
|
|
|
width: 75%; |
|
|
|
|
|
height: 75%; |
|
|
|
|
|
display: block; |
|
|
|
|
|
margin: 12.5% auto; |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.address-info { |
|
|
|
|
|
width: calc(100% - 120rpx); |
|
|
|
|
|
height: 100%; |
|
|
|
|
|
display: flex; |
|
|
|
|
|
flex-direction: column; |
|
|
|
|
|
justify-content: space-between; |
|
|
|
|
|
|
|
|
|
|
|
.user-info { |
|
|
|
|
|
display: flex; |
|
|
|
|
|
align-items: center; |
|
|
|
|
|
|
|
|
|
|
|
text { |
|
|
|
|
|
display: block; |
|
|
|
|
|
line-height: 40rpx; |
|
|
|
|
|
margin-right: 20rpx; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.user-name, |
|
|
|
|
|
.user-phone { |
|
|
|
|
|
font-size: 30rpx; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.is-default { |
|
|
|
|
|
display: flex; |
|
|
|
|
|
align-items: center; |
|
|
|
|
|
justify-content: center; |
|
|
|
|
|
background: #FEB773; |
|
|
|
|
|
color: white; |
|
|
|
|
|
width: 80rpx; |
|
|
|
|
|
height: 35rpx; |
|
|
|
|
|
border-radius: 20rpx; |
|
|
|
|
|
font-size: 22rpx; |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.address-detail { |
|
|
|
|
|
color: #4a4a4a; |
|
|
|
|
|
font-size: 26rpx; |
|
|
|
|
|
overflow: hidden; |
|
|
|
|
|
display: -webkit-box; |
|
|
|
|
|
-webkit-box-orient: vertical; |
|
|
|
|
|
-webkit-line-clamp: 2; |
|
|
|
|
|
text-overflow: ellipsis; |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.controls { |
|
|
|
|
|
display: flex; |
|
|
|
|
|
align-items: center; |
|
|
|
|
|
justify-content: space-between; |
|
|
|
|
|
align-items: center; |
|
|
|
|
|
font-size: 26rpx; |
|
|
|
|
|
padding: 15rpx 15rpx 25rpx 15rpx; |
|
|
|
|
|
|
|
|
|
|
|
.default-checkbox { |
|
|
|
|
|
display: flex; |
|
|
|
|
|
|
|
|
|
|
|
text { |
|
|
|
|
|
margin-left: 8rpx; |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.control-title { |
|
|
|
|
|
height: 30rpx; |
|
|
|
|
|
line-height: 30rpx; |
|
|
|
|
|
color: #666666; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
view { |
|
|
|
|
|
display: flex; |
|
|
|
|
|
align-items: center; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
image { |
|
|
|
|
|
width: 23rpx; |
|
|
|
|
|
height: 23rpx; |
|
|
|
|
|
vertical-align: middle; |
|
|
|
|
|
margin-right: 8rpx; |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
// .address-item { |
|
|
|
|
|
// background: white; |
|
|
|
|
|
// border-radius: 20rpx; |
|
|
|
|
|
// overflow: hidden; |
|
|
|
|
|
// margin-bottom: 20rpx; |
|
|
|
|
|
// padding: 15rpx 15rpx 0rpx 15rpx; |
|
|
|
|
|
// width: 680rpx; |
|
|
|
|
|
|
|
|
|
|
|
// .address-item-top { |
|
|
|
|
|
// border-bottom: 1px dashed #D3D1D1; |
|
|
|
|
|
// display: flex; |
|
|
|
|
|
// align-items: center; |
|
|
|
|
|
// padding: 0rpx 0rpx 15rpx 0rpx; |
|
|
|
|
|
|
|
|
|
|
|
// .img-box { |
|
|
|
|
|
// width: 120rpx; |
|
|
|
|
|
// height: 120rpx; |
|
|
|
|
|
|
|
|
|
|
|
// image { |
|
|
|
|
|
// width: 75%; |
|
|
|
|
|
// height: 75%; |
|
|
|
|
|
// display: block; |
|
|
|
|
|
// margin: 12.5% auto; |
|
|
|
|
|
// } |
|
|
|
|
|
// } |
|
|
|
|
|
|
|
|
|
|
|
// .address-info { |
|
|
|
|
|
// width: calc(100% - 120rpx); |
|
|
|
|
|
// height: 100%; |
|
|
|
|
|
// display: flex; |
|
|
|
|
|
// flex-direction: column; |
|
|
|
|
|
// justify-content: space-between; |
|
|
|
|
|
|
|
|
|
|
|
// .user-info { |
|
|
|
|
|
// display: flex; |
|
|
|
|
|
// align-items: center; |
|
|
|
|
|
|
|
|
|
|
|
// text { |
|
|
|
|
|
// display: block; |
|
|
|
|
|
// line-height: 40rpx; |
|
|
|
|
|
// margin-right: 20rpx; |
|
|
|
|
|
// } |
|
|
|
|
|
|
|
|
|
|
|
// .user-name, |
|
|
|
|
|
// .user-phone { |
|
|
|
|
|
// font-size: 30rpx; |
|
|
|
|
|
// } |
|
|
|
|
|
|
|
|
|
|
|
// .is-default { |
|
|
|
|
|
// display: flex; |
|
|
|
|
|
// align-items: center; |
|
|
|
|
|
// justify-content: center; |
|
|
|
|
|
// background: #FEB773; |
|
|
|
|
|
// color: white; |
|
|
|
|
|
// width: 80rpx; |
|
|
|
|
|
// height: 35rpx; |
|
|
|
|
|
// border-radius: 20rpx; |
|
|
|
|
|
// font-size: 22rpx; |
|
|
|
|
|
// } |
|
|
|
|
|
// } |
|
|
|
|
|
|
|
|
|
|
|
// .address-detail { |
|
|
|
|
|
// color: #4a4a4a; |
|
|
|
|
|
// font-size: 26rpx; |
|
|
|
|
|
// overflow: hidden; |
|
|
|
|
|
// display: -webkit-box; |
|
|
|
|
|
// -webkit-box-orient: vertical; |
|
|
|
|
|
// -webkit-line-clamp: 2; |
|
|
|
|
|
// text-overflow: ellipsis; |
|
|
|
|
|
// } |
|
|
|
|
|
// } |
|
|
|
|
|
// } |
|
|
|
|
|
|
|
|
|
|
|
// .controls { |
|
|
|
|
|
// display: flex; |
|
|
|
|
|
// align-items: center; |
|
|
|
|
|
// justify-content: space-between; |
|
|
|
|
|
// align-items: center; |
|
|
|
|
|
// font-size: 26rpx; |
|
|
|
|
|
// padding: 15rpx 15rpx 25rpx 15rpx; |
|
|
|
|
|
|
|
|
|
|
|
// .default-checkbox { |
|
|
|
|
|
// display: flex; |
|
|
|
|
|
|
|
|
|
|
|
// text { |
|
|
|
|
|
// margin-left: 8rpx; |
|
|
|
|
|
// } |
|
|
|
|
|
// } |
|
|
|
|
|
|
|
|
|
|
|
// .control-title { |
|
|
|
|
|
// height: 30rpx; |
|
|
|
|
|
// line-height: 30rpx; |
|
|
|
|
|
// color: #666666; |
|
|
|
|
|
// } |
|
|
|
|
|
|
|
|
|
|
|
// view { |
|
|
|
|
|
// display: flex; |
|
|
|
|
|
// align-items: center; |
|
|
|
|
|
// } |
|
|
|
|
|
|
|
|
|
|
|
// image { |
|
|
|
|
|
// width: 23rpx; |
|
|
|
|
|
// height: 23rpx; |
|
|
|
|
|
// vertical-align: middle; |
|
|
|
|
|
// margin-right: 8rpx; |
|
|
|
|
|
// } |
|
|
|
|
|
// } |
|
|
|
|
|
// } |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
.add-btn { |
|
|
.add-btn { |
|
|