tianyi 2 days ago
parent
commit
43af661d4b
  1. 236
      components/tab-bar/delivery.vue

236
components/tab-bar/delivery.vue

@ -63,131 +63,133 @@
</view> </view>
</view> </view>
<view class="content"> <view class="content">
<view class="box1" v-for="(item,index) in deliveryItem" :key="index"> <scroll-view @scrolltolower="onReachPage" scroll-y style="width:100%;height: 620px;overflow: scroll;">
<view class="maotou" v-if="item.deliveryType == 1"> <view class="box1" v-for="(item,index) in pageData" :key="index">
#样式要改<text>{{item.numberCode}}</text> <view class="maotou" v-if="item.deliveryType == 1">
</view> #样式要改<text>{{item.numberCode}}</text>
<view style="width: 100%;line-height: 70rpx;font-size: 28rpx;font-weight: 700;display: flex;">
<view v-if="item.deliveryType == 1"
style="height: 40rpx;line-height: 40rpx;background: rgba(255, 233, 89, 1);padding: 0 16rpx;border-radius: 40rpx;margin: 14rpx 20rpx 0 0;">
外卖
</view>
<view v-if="item.deliveryType == 2" style="height: 40rpx;line-height: 40rpx;background: rgba(255, 220, 199, 1);padding: 0 16rpx;border-radius: 40rpx;margin: 14rpx 20rpx 0 0;">
代取快递
</view>
<view v-if="item.deliveryType == 3" style="height: 40rpx;line-height: 40rpx;background: rgba(130, 255, 130, 1);padding: 0 16rpx;border-radius: 40rpx;margin: 14rpx 20rpx 0 0;">
代跑腿
</view> </view>
{{item.mustFinishTime != null ? item.mustFinishTime : '' | formatHourMinute }}前送达 <view style="width: 100%;line-height: 70rpx;font-size: 28rpx;font-weight: 700;display: flex;">
</view> <view v-if="item.deliveryType == 1"
<view class="" v-if="item.remark != '' && item.remark != null" style="height: 40rpx;line-height: 40rpx;background: rgba(255, 233, 89, 1);padding: 0 16rpx;border-radius: 40rpx;margin: 14rpx 20rpx 0 0;">
style="background: #f5f5f5;height: 80rpx;line-height: 80rpx;font-weight: 500;padding: 0 20rpx;border-radius: 20rpx;"> 外卖
备注{{item.remark}}
</view>
<view class="" v-if="item.deliveryType == 3 || item.deliveryType == 2"
style="background: #f5f5f5;line-height: 80rpx;font-weight: 700;padding: 0 20rpx;border-radius: 20rpx;margin-top: 20rpx;color: #777;">
<view style="display: flex;">
<view style="flex:1">
{{item.allCount != null ? item.allCount : 0}}
</view> </view>
<view class="" v-if="item.getPictures != null"> <view v-if="item.deliveryType == 2" style="height: 40rpx;line-height: 40rpx;background: rgba(255, 220, 199, 1);padding: 0 16rpx;border-radius: 40rpx;margin: 14rpx 20rpx 0 0;">
取件码截图(分割一下) {{item.getPictures}} 代取快递
</view> </view>
<view class="" v-if="item.getCodes != null"> <view v-if="item.deliveryType == 3" style="height: 40rpx;line-height: 40rpx;background: rgba(130, 255, 130, 1);padding: 0 16rpx;border-radius: 40rpx;margin: 14rpx 20rpx 0 0;">
取件码{{item.getCodes}} 代跑腿
</view>
<view style="flex:1;text-align: right;" v-if="item.phoneNumber != null">
手机尾号{{item.phoneNumber}}
</view> </view>
{{item.mustFinishTime != null ? item.mustFinishTime : '' | formatHourMinute }}前送达
</view> </view>
<view class="" v-if="item.remark != '' && item.remark != null"
<view style="display: flex;padding: 20rpx 0;"> style="background: #f5f5f5;height: 80rpx;line-height: 80rpx;font-weight: 500;padding: 0 20rpx;border-radius: 20rpx;">
<img @tap="largeImg" src="https://jewel-shop.oss-cn-beijing.aliyuncs.com/1f77398a73454a6595c12a3c18731599.png" alt="" style="width: 90rpx;height: 106rpx;background-size: 100%;margin-right:20rpx;"/> 备注{{item.remark}}
</view> </view>
<!-- <view style="display: flex;padding: 10px 0;"> <view class="" v-if="item.deliveryType == 3 || item.deliveryType == 2"
<view class="code-box" style="margin-right:10px;"> style="background: #f5f5f5;line-height: 80rpx;font-weight: 700;padding: 0 20rpx;border-radius: 20rpx;margin-top: 20rpx;color: #777;">
1-3-1290 <view style="display: flex;">
<view style="flex:1">
{{item.allCount != null ? item.allCount : 0}}
</view>
<view class="" v-if="item.getPictures != null">
取件码截图(分割一下) {{item.getPictures}}
</view>
<view class="" v-if="item.getCodes != null">
取件码{{item.getCodes}}
</view>
<view style="flex:1;text-align: right;" v-if="item.phoneNumber != null">
手机尾号{{item.phoneNumber}}
</view>
</view> </view>
</view> -->
<!-- <view style="display: flex;padding: 10px 0;"> <view style="display: flex;padding: 20rpx 0;">
<view class="code-box"> <img @tap="largeImg" src="https://jewel-shop.oss-cn-beijing.aliyuncs.com/1f77398a73454a6595c12a3c18731599.png" alt="" style="width: 90rpx;height: 106rpx;background-size: 100%;margin-right:20rpx;"/>
手机尾号 - 5741
</view> </view>
</view> --> <!-- <view style="display: flex;padding: 10px 0;">
</view> <view class="code-box" style="margin-right:10px;">
<view style="display: flex;border-radius: 20rpx;margin-top: 32rpx;"> 1-3-1290
<view class="goods-content">
<view class="goods-name" style="font-size: 24rpx;line-height: 50rpx;display: flex;">
<img src="https://jewel-shop.oss-cn-beijing.aliyuncs.com/1f77398a73454a6595c12a3c18731599.png"
alt="" style="width: 50rpx;height: 50rpx;" />
<view style="flex: 1;">
<view class="">
{{item.shopName}}
</view>
<view @tap="productDetail(item)" v-if="item.deliveryType == 1"
style="width: 32rpx;height: 30rpx;font-weight: 700;font-size: 20rpx;color: #fff;text-align: center;background: #00BFFF;border-radius: 10rpx;margin: 20rpx 0 0 10rpx;line-height: 30rpx;">
</view>
<view style="color: #777;">
{{item.shopAddress}}
</view>
</view> </view>
<view class="right"> </view> -->
<img @tap="makeCall(item.shopPhone)" <!-- <view style="display: flex;padding: 10px 0;">
src="https://jewel-shop.oss-cn-beijing.aliyuncs.com/869a7af6a1c24bf3a0d523c4a18b55c6.png" <view class="code-box">
alt="" style="width: 60rpx;height: 60rpx;" /> 手机尾号 - 5741
</view> </view>
</view> </view> -->
<view class="goods-name" </view>
style="font-size: 24rpx;line-height: 50rpx;display: flex;margin-top: 14rpx;"> <view style="display: flex;border-radius: 20rpx;margin-top: 32rpx;">
<img src="https://jewel-shop.oss-cn-beijing.aliyuncs.com/d0764fb4138747769538cf1cafa3b017.png" <view class="goods-content">
alt="" style="width: 50rpx;height: 50rpx;" /> <view class="goods-name" style="font-size: 24rpx;line-height: 50rpx;display: flex;">
<view style="flex: 1;"> <img src="https://jewel-shop.oss-cn-beijing.aliyuncs.com/1f77398a73454a6595c12a3c18731599.png"
<view class=""> alt="" style="width: 50rpx;height: 50rpx;" />
{{item.receiverName}} <view style="flex: 1;">
<view class="">
{{item.shopName}}
</view>
<view @tap="productDetail(item)" v-if="item.deliveryType == 1"
style="width: 32rpx;height: 30rpx;font-weight: 700;font-size: 20rpx;color: #fff;text-align: center;background: #00BFFF;border-radius: 10rpx;margin: 20rpx 0 0 10rpx;line-height: 30rpx;">
</view>
<view style="color: #777;">
{{item.shopAddress}}
</view>
</view> </view>
<view style="color: #777;"> <view class="right">
{{item.receiverAddress}} <img @tap="makeCall(item.shopPhone)"
src="https://jewel-shop.oss-cn-beijing.aliyuncs.com/869a7af6a1c24bf3a0d523c4a18b55c6.png"
alt="" style="width: 60rpx;height: 60rpx;" />
</view> </view>
</view> </view>
<view class="right"> <view class="goods-name"
<img @tap="makeCall(item.receiverPhone)" style="font-size: 24rpx;line-height: 50rpx;display: flex;margin-top: 14rpx;">
src="https://jewel-shop.oss-cn-beijing.aliyuncs.com/869a7af6a1c24bf3a0d523c4a18b55c6.png" <img src="https://jewel-shop.oss-cn-beijing.aliyuncs.com/d0764fb4138747769538cf1cafa3b017.png"
alt="" style="width: 60rpx;height: 60rpx;" /> alt="" style="width: 50rpx;height: 50rpx;" />
<view style="flex: 1;">
<view class="">
{{item.receiverName}}
</view>
<view style="color: #777;">
{{item.receiverAddress}}
</view>
</view>
<view class="right">
<img @tap="makeCall(item.receiverPhone)"
src="https://jewel-shop.oss-cn-beijing.aliyuncs.com/869a7af6a1c24bf3a0d523c4a18b55c6.png"
alt="" style="width: 60rpx;height: 60rpx;" />
</view>
</view> </view>
</view> </view>
</view> </view>
</view> <view style="display: flex;border-radius: 20rpx;margin-top: 10rpx;">
<view style="display: flex;border-radius: 20rpx;margin-top: 10rpx;"> <view class="goods-content">
<view class="goods-content"> <view class="goods-name" style="font-size: 24rpx;line-height: 50rpx;display: flex;">
<view class="goods-name" style="font-size: 24rpx;line-height: 50rpx;display: flex;"> <img src="" alt="" style="width: 50rpx;height: 50rpx;" />
<img src="" alt="" style="width: 50rpx;height: 50rpx;" /> <view style="flex: 1;display: flex;">
<view style="flex: 1;display: flex;"> <view style="color: #777;display: flex;">
<view style="color: #777;display: flex;"> 配送佣金
配送佣金 <view class="chaoda" v-if="item.isBig != null && item.isBig == 1">
<view class="chaoda" v-if="item.isBig != null && item.isBig == 1"> 超大/超重
超大/超重 </view>
</view>
<view style="flex: 1;text-align: right;">
{{item.deliveryFee}} <text style="color: #777;font-size: 20rpx;"v-if="item.deliveryFeeMarketplace != null">包含{{item.deliveryFeeMarketplace}}平台佣金</text>
</view> </view>
</view>
<view style="flex: 1;text-align: right;">
{{item.deliveryFee}} <text style="color: #777;font-size: 20rpx;"v-if="item.deliveryFeeMarketplace != null">包含{{item.deliveryFeeMarketplace}}平台佣金</text>
</view> </view>
</view> </view>
</view> </view>
</view> </view>
<view v-if="item.isReturn != null && item.isReturn == 1" style="width: 100%;height: 100rpx;margin-top: 32rpx;">
用户申请 退款中
</view>
<view v-else style="width: 100%;height: 100rpx;margin-top: 32rpx;">
<view style="width: 20%;" v-if="item.status == 1 && item.arriveTime == null" @tap="changeStatus(item,1)">已到店</view>
<!-- <view style="width: 20%;" @tap="changeOthers(item,1)">转单</view> -->
<img v-if="item.status == 1 && item.arriveTime != null" src="https://jewel-shop.oss-cn-beijing.aliyuncs.com/c318cf292a4f40b296995c30e5e539ea.png"
alt="" style="width: 80%;height: 100rpx;background-size: 100%;" @tap="changeStatus(item,2)"/>
<img v-if="item.status == 2 && item.arriveTime != null" src="https://jewel-shop.oss-cn-beijing.aliyuncs.com/a8cdd6d86e9140df86d3c3c60356bd53.png"
alt="" style="width: 100%;height: 100rpx;background-size: 100%;" @tap="changeStatus(item,3)" />
</view>
</view> </view>
<view v-if="item.isReturn != null && item.isReturn == 1" style="width: 100%;height: 100rpx;margin-top: 32rpx;"> </scroll-view>
用户申请 退款中
</view>
<view v-else style="width: 100%;height: 100rpx;margin-top: 32rpx;">
<view style="width: 20%;" v-if="item.status == 1 && item.arriveTime == null" @tap="changeStatus(item,1)">已到店</view>
<!-- <view style="width: 20%;" @tap="changeOthers(item,1)">转单</view> -->
<img v-if="item.status == 1 && item.arriveTime != null" src="https://jewel-shop.oss-cn-beijing.aliyuncs.com/c318cf292a4f40b296995c30e5e539ea.png"
alt="" style="width: 80%;height: 100rpx;background-size: 100%;" @tap="changeStatus(item,2)"/>
<img v-if="item.status == 2 && item.arriveTime != null" src="https://jewel-shop.oss-cn-beijing.aliyuncs.com/a8cdd6d86e9140df86d3c3c60356bd53.png"
alt="" style="width: 100%;height: 100rpx;background-size: 100%;" @tap="changeStatus(item,3)" />
</view>
</view>
<!-- 设置指派单规则弹窗 --> <!-- 设置指派单规则弹窗 -->
<uni-popup ref="carPopup" background-color="#fff" style="height: 1600rpx !important;"> <uni-popup ref="carPopup" background-color="#fff" style="height: 1600rpx !important;">
@ -323,7 +325,9 @@
}, },
waimaRuleList: [], waimaRuleList: [],
tab1Checked1:'', tab1Checked1:'',
pageData:[],
deliveryItem:[], deliveryItem:[],
deliveryItem1:[],
selectRuleList: [], selectRuleList: [],
totalPages:1, totalPages:1,
paotuiRuleList: [], paotuiRuleList: [],
@ -380,6 +384,12 @@
this.getDelivery() this.getDelivery()
this.$forceUpdate() this.$forceUpdate()
}, },
onReachPage(){
console.log("11111")
if (this.searchForm.pageNum >= this.totalPages) return;
this.searchForm.pageNum++;
this.getDelivery();
},
chooseType(type){ chooseType(type){
if(this.tab1Checked1 == type){ if(this.tab1Checked1 == type){
this.tab1Checked1 = '' this.tab1Checked1 = ''
@ -403,12 +413,22 @@
this.tui.request("/mall/delivery/pagebyworker", "POST", this.searchForm, false, false).then((res) => { this.tui.request("/mall/delivery/pagebyworker", "POST", this.searchForm, false, false).then((res) => {
that.loadStatus = 'nomore'; that.loadStatus = 'nomore';
if (res.code == 200) { if (res.code == 200) {
that.deliveryItem = res.result.records; if(this.searchForm.status == 1){
if (that.searchForm.pageNum == 1) { if (that.searchForm.pageNum == 1) {
that.deliveryItem = res.result.records; that.deliveryItem1 = res.result.records;
} else { } else {
that.deliveryItem = [...that.deliveryItem, ...res.result.records] that.deliveryItem1 = [...that.deliveryItem, ...res.result.records]
}
that.pageData = that.deliveryItem1
}else{
if (that.searchForm.pageNum == 1) {
that.deliveryItem = res.result.records;
} else {
that.deliveryItem = [...that.deliveryItem, ...res.result.records]
}
that.pageData = that.deliveryItem
} }
that.totalPages = res.result.pages; // pages = that.totalPages = res.result.pages; // pages =
that.$forceUpdate(); that.$forceUpdate();
} else { } else {

Loading…
Cancel
Save