|
|
|
@ -48,113 +48,29 @@
|
|
|
|
|
@change="tabsScChange" |
|
|
|
|
></u-tabs> |
|
|
|
|
</view> |
|
|
|
|
|
|
|
|
|
<view class="lists-container row"> |
|
|
|
|
<view class="item"> |
|
|
|
|
<view class="item-header row"> |
|
|
|
|
<view class="title">2023-08-03</view> |
|
|
|
|
<view class="status green">已完成</view> |
|
|
|
|
</view> |
|
|
|
|
<view class="item-body row"> |
|
|
|
|
<view class="body-main row"> |
|
|
|
|
<view class="thumb"> |
|
|
|
|
<u-image :src="staticImage.shopThumb" :lazy-load="true" radius="24" width="176" height="176" mode="aspectFill"></u-image> |
|
|
|
|
</view> |
|
|
|
|
<view class="info row col"> |
|
|
|
|
<view class="info-left"> |
|
|
|
|
<view class="info-title">美迪惠尔水润保湿面膜10片水库针剂</view> |
|
|
|
|
</view> |
|
|
|
|
<view class="info-right"> |
|
|
|
|
<view class="info-price">¥369.00</view> |
|
|
|
|
<view class="info-number">x2</view> |
|
|
|
|
</view> |
|
|
|
|
<view class="info-ext row"> |
|
|
|
|
<view class="label">暖新币</view> |
|
|
|
|
<view class="price">369币</view> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
|
|
|
|
|
</view> |
|
|
|
|
<view class="item-footer row"> |
|
|
|
|
<view class="phone"> |
|
|
|
|
<view class="phone-button" @click="callPhone('15012345678')"> |
|
|
|
|
<u-icon name="phone-fill" size="45" color="#ffffff"></u-icon> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
<view class="button-group row col"> |
|
|
|
|
<view class="button"> |
|
|
|
|
<u-button text="查看详情" shape="circle" custom-style="height:64rpx;border: 2rpx solid #AFB5BE;padding:0rpx 42rpx;"></u-button> |
|
|
|
|
</view> |
|
|
|
|
<view class="button"> |
|
|
|
|
<u-button text="查看物流" shape="circle" custom-style="height:64rpx;border: 2rpx solid #AFB5BE;padding:0rpx 42rpx;"></u-button> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
<view class="item"> |
|
|
|
|
<view class="item-header row"> |
|
|
|
|
<view class="title">2023-08-03</view> |
|
|
|
|
<view class="status orange">待发货</view> |
|
|
|
|
</view> |
|
|
|
|
<view class="item-body row"> |
|
|
|
|
<view class="body-main row"> |
|
|
|
|
<view class="thumb"> |
|
|
|
|
<u-image :src="staticImage.shopThumb" :lazy-load="true" radius="24" width="176" height="176" mode="aspectFill"></u-image> |
|
|
|
|
</view> |
|
|
|
|
<view class="info row col"> |
|
|
|
|
<view class="info-left"> |
|
|
|
|
<view class="info-title">美迪惠尔水润保湿面膜10片水库针剂</view> |
|
|
|
|
</view> |
|
|
|
|
<view class="info-right"> |
|
|
|
|
<view class="info-price">¥369.00</view> |
|
|
|
|
<view class="info-number">x2</view> |
|
|
|
|
</view> |
|
|
|
|
<view class="info-ext row"> |
|
|
|
|
<view class="label">暖新币</view> |
|
|
|
|
<view class="price">369币</view> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
|
|
|
|
|
</view> |
|
|
|
|
<view class="item-footer row"> |
|
|
|
|
<view class="phone"> |
|
|
|
|
<view class="phone-button" @click="callPhone('15012345678')"> |
|
|
|
|
<u-icon name="phone-fill" size="45" color="#ffffff"></u-icon> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
<view class="button-group row col"> |
|
|
|
|
<view class="button"> |
|
|
|
|
<u-button text="查看详情" shape="circle" custom-style="height:64rpx;border: 2rpx solid #AFB5BE;padding:0rpx 42rpx;"></u-button> |
|
|
|
|
</view> |
|
|
|
|
<view class="button"> |
|
|
|
|
<u-button text="查看物流" shape="circle" custom-style="height:64rpx;border: 2rpx solid #AFB5BE;padding:0rpx 42rpx;"></u-button> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
<view class="item"> |
|
|
|
|
<view class="lists-group row"> |
|
|
|
|
<view class="lists-container row" v-if="tabCheck === 'shop'"> |
|
|
|
|
<view class="item" v-for="(item,index) in listsSc"> |
|
|
|
|
<view class="item-header row"> |
|
|
|
|
<view class="title">2023-08-03</view> |
|
|
|
|
<view class="status blue">待收货</view> |
|
|
|
|
<view class="title">{{ item.create_time }}</view> |
|
|
|
|
<view class="status" :class="getScStatus(item.status).color">{{getScStatus(item.status).name}}</view> |
|
|
|
|
</view> |
|
|
|
|
<view class="item-body row"> |
|
|
|
|
<view class="body-main row"> |
|
|
|
|
<view class="thumb"> |
|
|
|
|
<u-image :src="staticImage.shopThumb" :lazy-load="true" radius="24" width="176" height="176" mode="aspectFill"></u-image> |
|
|
|
|
<u-image :src="item.goods_cover" :lazy-load="true" radius="24" width="176" height="176" mode="aspectFill"></u-image> |
|
|
|
|
</view> |
|
|
|
|
<view class="info row col"> |
|
|
|
|
<view class="info-left"> |
|
|
|
|
<view class="info-title">美迪惠尔水润保湿面膜10片水库针剂</view> |
|
|
|
|
<view class="info-title">{{item.goods_name}}</view> |
|
|
|
|
</view> |
|
|
|
|
<view class="info-right"> |
|
|
|
|
<view class="info-price">¥369.00</view> |
|
|
|
|
<view class="info-number">x2</view> |
|
|
|
|
<view class="info-price">¥{{item.coin_number}}</view> |
|
|
|
|
<view class="info-number">x{{item.goods_number}}</view> |
|
|
|
|
</view> |
|
|
|
|
<view class="info-ext row"> |
|
|
|
|
<view class="label">暖新币</view> |
|
|
|
|
<view class="price">369币</view> |
|
|
|
|
<view class="price">{{item.coin_number}}币</view> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
@ -162,7 +78,7 @@
|
|
|
|
|
</view> |
|
|
|
|
<view class="item-footer row"> |
|
|
|
|
<view class="phone"> |
|
|
|
|
<view class="phone-button" @click="callPhone('15012345678')"> |
|
|
|
|
<view class="phone-button" @click="callPhone(item.take_phone)"> |
|
|
|
|
<u-icon name="phone-fill" size="45" color="#ffffff"></u-icon> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
@ -176,24 +92,26 @@
|
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
<view class="item"> |
|
|
|
|
</view> |
|
|
|
|
<view class="lists-container row" v-if="tabCheck === 'room'"> |
|
|
|
|
<view class="item" v-for="(item,index) in listsGy"> |
|
|
|
|
<view class="item-header row"> |
|
|
|
|
<view class="title">2023-08-03</view> |
|
|
|
|
<view class="status blue">待收货</view> |
|
|
|
|
<view class="title">{{item.create_time}}</view> |
|
|
|
|
<view class="status" :class="getGyStatus(item.status).color">{{getGyStatus(item.status).name}}</view> |
|
|
|
|
</view> |
|
|
|
|
<view class="item-body room row"> |
|
|
|
|
<view class="body-main row"> |
|
|
|
|
<view class="thumb"> |
|
|
|
|
<u-image :src="staticImage.shopThumb" :lazy-load="true" radius="24" width="176" height="176" mode="aspectFill"></u-image> |
|
|
|
|
<u-image :src="item.cover" :lazy-load="true" radius="24" width="176" height="176" mode="aspectFill"></u-image> |
|
|
|
|
</view> |
|
|
|
|
<view class="info row col"> |
|
|
|
|
<view class="info-left"> |
|
|
|
|
<view class="info-title">合租 北新润苑二期4居室 南卧</view> |
|
|
|
|
<view class="info-desc">桂溪街道 50㎡ | 朝南</view> |
|
|
|
|
<view class="info-title">{{item.name}}</view> |
|
|
|
|
<view class="info-desc">{{ item.street }} {{ item.area }}㎡ | 朝{{item.toward}}</view> |
|
|
|
|
</view> |
|
|
|
|
<view class="info-ext row"> |
|
|
|
|
<view class="label">暖新币</view> |
|
|
|
|
<view class="price">369币</view> |
|
|
|
|
<view class="label">租期{{item.month}}个月</view> |
|
|
|
|
<view class="price">{{item.price}}元/月</view> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
@ -205,15 +123,26 @@
|
|
|
|
|
</view> |
|
|
|
|
<view class="button-group row col"> |
|
|
|
|
<view class="button"> |
|
|
|
|
<u-button text="查看详情" shape="circle" custom-style="height:64rpx;border: 2rpx solid #AFB5BE;padding:0rpx 42rpx;"></u-button> |
|
|
|
|
<u-button |
|
|
|
|
@click="navTo('/pages/Order/detail?id='+item.id+'&type=detail')" |
|
|
|
|
text="租房详情" |
|
|
|
|
shape="circle" |
|
|
|
|
custom-style="height:64rpx;border: 2rpx solid #AFB5BE;padding:0rpx 42rpx;"></u-button> |
|
|
|
|
</view> |
|
|
|
|
<view class="button"> |
|
|
|
|
<u-button text="查看物流" shape="circle" custom-style="height:64rpx;border: 2rpx solid #AFB5BE;padding:0rpx 42rpx;"></u-button> |
|
|
|
|
<u-button text="兑换详情" shape="circle" custom-style="height:64rpx;border: 2rpx solid #AFB5BE;padding:0rpx 42rpx;"></u-button> |
|
|
|
|
<!-- <u-button text="我要兑换" shape="circle" custom-style="height:64rpx;border: 2rpx solid #FF9545;padding:0rpx 42rpx; color:#FF9545;"></u-button>--> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
|
|
|
|
|
</view> |
|
|
|
|
<u-loadmore v-if="(tabCheck==='room')" :status="statusGy" fontSize="28" marginBottom="50" marginTop="30" @loadmore="getRoomOrderList()"/> |
|
|
|
|
<u-loadmore v-if="(tabCheck==='shop')" :status="statusSc" fontSize="28" marginBottom="50" marginTop="30" @loadmore="getGoodsOrderList()"/> |
|
|
|
|
</view> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</template> |
|
|
|
|
|
|
|
|
@ -223,6 +152,7 @@ import {
|
|
|
|
|
} from '@/config/host.js' |
|
|
|
|
import MzSubsection from '@/components/MzSubsection/Index.vue'; |
|
|
|
|
import api from '@/utils/functions.js'; |
|
|
|
|
import {goodsOrder, roomOrder, tabCount} from "@/api/user"; |
|
|
|
|
|
|
|
|
|
export default { |
|
|
|
|
components: { |
|
|
|
@ -238,37 +168,34 @@ export default {
|
|
|
|
|
id:'shop' |
|
|
|
|
}], |
|
|
|
|
listGy: [{ |
|
|
|
|
name: '全部' |
|
|
|
|
name: '全部', |
|
|
|
|
status:'' |
|
|
|
|
}, { |
|
|
|
|
name: '租赁中', |
|
|
|
|
badge: { |
|
|
|
|
value: 2, |
|
|
|
|
bgColor:'#FF9545', |
|
|
|
|
color:'#3D3D3D' |
|
|
|
|
} |
|
|
|
|
status:2, |
|
|
|
|
}, { |
|
|
|
|
name: '已完成' |
|
|
|
|
name: '已完成', |
|
|
|
|
status:4 |
|
|
|
|
}], |
|
|
|
|
listSc: [{ |
|
|
|
|
name: '全部' |
|
|
|
|
name: '全部', |
|
|
|
|
status:'' |
|
|
|
|
|
|
|
|
|
}, { |
|
|
|
|
name: '待发货', |
|
|
|
|
badge: { |
|
|
|
|
value: 5, |
|
|
|
|
bgColor:'#FF9545', |
|
|
|
|
color:'#3D3D3D', |
|
|
|
|
} |
|
|
|
|
status:1, |
|
|
|
|
}, { |
|
|
|
|
name: '待收货' |
|
|
|
|
name: '待收货', |
|
|
|
|
status:2, |
|
|
|
|
}, { |
|
|
|
|
name: '已完成' |
|
|
|
|
name: '已完成', |
|
|
|
|
status:3 |
|
|
|
|
}], |
|
|
|
|
tabCheck:'room', |
|
|
|
|
tabGyCheck:'all', |
|
|
|
|
tabScCheck:'all', |
|
|
|
|
tabGyCheck:'', |
|
|
|
|
tabScCheck:'', |
|
|
|
|
current: 1, |
|
|
|
|
title: '编辑资料', |
|
|
|
|
title: '我的订单', |
|
|
|
|
loading: true, |
|
|
|
|
staticImage: { |
|
|
|
|
bg: imghost + '/static/image/BG.png', |
|
|
|
@ -282,33 +209,21 @@ export default {
|
|
|
|
|
id: 88685, |
|
|
|
|
}, |
|
|
|
|
isTop: false, |
|
|
|
|
lists: [ |
|
|
|
|
{ |
|
|
|
|
id: 1, |
|
|
|
|
thumb: imghost + '/static/image/new-1.png', |
|
|
|
|
title: '全市公安机关夏季治安打击整治“彭安行动”新闻发布会召开', |
|
|
|
|
desc: '需要您带一点猫砂上门,谢谢', |
|
|
|
|
time: '2023/06/16', |
|
|
|
|
is_new: true |
|
|
|
|
}, { |
|
|
|
|
id: 2, |
|
|
|
|
thumb: imghost + '/static/image/new-2.png', |
|
|
|
|
title: '全市公安机关夏季治安打击整治“彭安行动”新闻发布会召开', |
|
|
|
|
desc: '需要您带一点猫砂上门,谢谢', |
|
|
|
|
time: '2023/06/16', |
|
|
|
|
is_new: true |
|
|
|
|
}, { |
|
|
|
|
id: 3, |
|
|
|
|
thumb: imghost + '/static/image/new-3.png', |
|
|
|
|
title: '全市公安机关夏季治安打击整治“彭安行动”111开', |
|
|
|
|
desc: '需要您带一点猫砂上门,谢谢', |
|
|
|
|
time: '2023/06/16', |
|
|
|
|
is_new: false |
|
|
|
|
}, |
|
|
|
|
], |
|
|
|
|
listsGy: [], |
|
|
|
|
listsSc: [], |
|
|
|
|
size: { |
|
|
|
|
height: 500, |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
pagesGy:{ |
|
|
|
|
page:1, |
|
|
|
|
limit:10, |
|
|
|
|
}, |
|
|
|
|
statusGy:'loadmore', |
|
|
|
|
pagesSc:{ |
|
|
|
|
page:1, |
|
|
|
|
limit:10, |
|
|
|
|
}, |
|
|
|
|
statusSc:'loadmore' |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
onLoad() { |
|
|
|
@ -340,6 +255,28 @@ export default {
|
|
|
|
|
}, |
|
|
|
|
}, |
|
|
|
|
methods: { |
|
|
|
|
getGyStatus(status){ |
|
|
|
|
switch(status){ |
|
|
|
|
case 1: |
|
|
|
|
return {name:'待审核',color:'orange'} |
|
|
|
|
case 2: |
|
|
|
|
return {name:'租赁中',color:'blue'} |
|
|
|
|
case 3: |
|
|
|
|
return {name:'审核失败',color:'red'} |
|
|
|
|
case 4: |
|
|
|
|
return {name:'已完成',color:'green'} |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
getScStatus(status){ |
|
|
|
|
switch(status){ |
|
|
|
|
case 1: |
|
|
|
|
return {name:'待发货',color:'orange'} |
|
|
|
|
case 2: |
|
|
|
|
return {name:'待收货',color:'blue'} |
|
|
|
|
case 3: |
|
|
|
|
return {name:'已完成',color:'green'} |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
chatDetail(item) { |
|
|
|
|
wx.navigateTo({ |
|
|
|
|
url: '/pages/ChatDetail/index?id=' + item.id |
|
|
|
@ -355,15 +292,111 @@ export default {
|
|
|
|
|
this.tabCheck = e.id |
|
|
|
|
}, |
|
|
|
|
tabsGyChange(e){ |
|
|
|
|
this.tabGyCheck = e.id |
|
|
|
|
this.tabGyCheck = e.status |
|
|
|
|
this.getRoomOrderList(true); |
|
|
|
|
}, |
|
|
|
|
tabsScChange(e){ |
|
|
|
|
this.tabScCheck = e.id |
|
|
|
|
this.tabScCheck = e.status |
|
|
|
|
this.getGoodsOrderList(true); |
|
|
|
|
}, |
|
|
|
|
callPhone(phone){ |
|
|
|
|
uni.makePhoneCall({ |
|
|
|
|
phoneNumber: phone.toString() |
|
|
|
|
}); |
|
|
|
|
}, |
|
|
|
|
getRoomOrderList(clear = false){ |
|
|
|
|
if(clear){ |
|
|
|
|
this.statusGy = 'loadmore' |
|
|
|
|
this.pagesGy = { |
|
|
|
|
page:1, |
|
|
|
|
limit:10 |
|
|
|
|
} |
|
|
|
|
this.listsGy = []; |
|
|
|
|
} |
|
|
|
|
if(this.statusGy === 'nomore'){ |
|
|
|
|
return false; |
|
|
|
|
} |
|
|
|
|
this.statusGy = 'loading'; |
|
|
|
|
let data = this.pagesGy; |
|
|
|
|
if(this.tabGyCheck){ |
|
|
|
|
data.status = this.tabGyCheck; |
|
|
|
|
} |
|
|
|
|
roomOrder(data).then(res => { |
|
|
|
|
if(res.data.length === 0){ |
|
|
|
|
this.statusGy = 'nomore'; |
|
|
|
|
}else{ |
|
|
|
|
this.statusGy = 'loadmore'; |
|
|
|
|
} |
|
|
|
|
this.listsGy = this.listsGy.concat(res.data); |
|
|
|
|
}); |
|
|
|
|
this.pagesGy.page++; |
|
|
|
|
}, |
|
|
|
|
getGoodsOrderList(clear = false){ |
|
|
|
|
if(clear){ |
|
|
|
|
this.statusSc = 'loadmore' |
|
|
|
|
this.pagesSc = { |
|
|
|
|
page:1, |
|
|
|
|
limit:10 |
|
|
|
|
} |
|
|
|
|
this.listsSc = []; |
|
|
|
|
} |
|
|
|
|
if(this.statusSc === 'nomore'){ |
|
|
|
|
return false; |
|
|
|
|
} |
|
|
|
|
this.statusSc = 'loading'; |
|
|
|
|
let data = this.pagesSc; |
|
|
|
|
if(this.tabScCheck){ |
|
|
|
|
data.status = this.tabScCheck; |
|
|
|
|
} |
|
|
|
|
goodsOrder(data).then(res => { |
|
|
|
|
if(res.data.length === 0){ |
|
|
|
|
this.statusSc = 'nomore'; |
|
|
|
|
}else{ |
|
|
|
|
this.statusSc = 'loadmore'; |
|
|
|
|
} |
|
|
|
|
this.listsSc = this.listsSc.concat(res.data); |
|
|
|
|
}); |
|
|
|
|
this.pagesSc.page++; |
|
|
|
|
}, |
|
|
|
|
getTabCount(){ |
|
|
|
|
tabCount({type:'house'}).then(res => { |
|
|
|
|
this.listGy.forEach(item => { |
|
|
|
|
res.data.forEach(row => { |
|
|
|
|
if(item.status === row.type){ |
|
|
|
|
item.badge = { |
|
|
|
|
bgColor:'#FF9545', |
|
|
|
|
color:'#3D3D3D', |
|
|
|
|
} |
|
|
|
|
item.badge.value = row.count; |
|
|
|
|
} |
|
|
|
|
}) |
|
|
|
|
}) |
|
|
|
|
}) |
|
|
|
|
tabCount({type:'goods'}).then(res => { |
|
|
|
|
this.listSc.forEach(item => { |
|
|
|
|
res.data.forEach(row => { |
|
|
|
|
if(item.status === row.type){ |
|
|
|
|
item.badge = { |
|
|
|
|
bgColor:'#FF9545', |
|
|
|
|
color:'#3D3D3D', |
|
|
|
|
} |
|
|
|
|
item.badge.value = row.count; |
|
|
|
|
} |
|
|
|
|
}) |
|
|
|
|
}) |
|
|
|
|
}) |
|
|
|
|
}, |
|
|
|
|
navTo(url){ |
|
|
|
|
wx.navigateTo({ |
|
|
|
|
url:url |
|
|
|
|
}) |
|
|
|
|
}, |
|
|
|
|
}, |
|
|
|
|
onReachBottom() { |
|
|
|
|
if(this.tabCheck === 'room'){ |
|
|
|
|
this.getRoomOrderList(); |
|
|
|
|
}else{ |
|
|
|
|
this.getGoodsOrderList(); |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
onPageScroll(res) { |
|
|
|
@ -373,6 +406,11 @@ export default {
|
|
|
|
|
uni.$emit('isTop', false); |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
mounted() { |
|
|
|
|
this.getRoomOrderList(); |
|
|
|
|
this.getGoodsOrderList(); |
|
|
|
|
this.getTabCount(); |
|
|
|
|
}, |
|
|
|
|
created() { |
|
|
|
|
// this.pagePadding = (api.navHeight().navPaddingTop + |
|
|
|
|
// api.navHeight().navHeight + (api.navHeight().headerPadding * 2)) |
|
|
|
|