address api

This commit is contained in:
2020-06-23 17:21:01 +08:00
parent fe995ced2d
commit 8c993da2cd
12 changed files with 390 additions and 55 deletions

View File

@@ -10,10 +10,10 @@
<view v-for="(item, index) in orderList" :key="index" class="order-item">
<view class="order-title">
<view class="order-text">订单</view>
<view class="order-status">已预约</view>
<view class="order-status">{{ item.status }}</view>
</view>
<view class="order-name">美甲人姓名xxx</view>
<view class="order-date">时间2020-04-12</view>
<view class="order-name">美甲人姓名{{ item.manicure_name }}</view>
<view class="order-date">时间{{ item.manicure_time | dateFormat }}</view>
</view>
<u-loadmore :status="loadStatus" bgColor="#ECECEC" margin-bottom="20"></u-loadmore>
</view>
@@ -39,20 +39,33 @@ export default {
current: 0,
swiperCurrent: 0,
page: 1,
orderList: 5,
orderList: [],
loadStatus: 'loadmore',
}
},
onShow() {
this.current = 0;
this.swiperCurrent = 0;
this.getManicureList();
},
filters: {
dateFormat(value) {
let date = new Date(value * 1000);
let year, month, day;
year = date.getFullYear();
month = date.getMonth() + 1;
day = date.getDate();
return year + "-" + month + "-" + day;
}
},
methods: {
getManicureList() {
this.$u.api.getManicureList({
page: this.page
}).then((res)=>{
if (res.errCode == 0) {}
if (res.errCode == 0) {
this.orderList = res.data.list;
}
})
},
reachBottom() {