作者 3318410485

021002订单遗留问题处理

... ... @@ -4,7 +4,7 @@
<u-tabs-swiper ref="tabs" :list="list" :is-scroll="false" inactive-color="#969799" active-color="#000000"
bar-width="90" bar-height="3" gutter="56" :current="Tabcurrent" @change="change"></u-tabs-swiper>
</view>
<view v-if="orderstate">
<view v-if="orderList[0].length > 0">
<swiper class="swiper-box" :current="swiperCurrent" @transition="transition" @animationfinish="animationfinish" >
<swiper-item class="swiper-item">
<scroll-view scroll-y style="height: 100%;width: 100%;" >
... ... @@ -485,7 +485,7 @@
tabsHeight: 0,
dx: 0,
orderstateText: '',
orderstate:true, //判断订单是否为空
// orderstate:true, //判断订单是否为空
orderList: [
[],
[],
... ... @@ -501,11 +501,10 @@
self.Getdata();
// this.readorderlist();
// this.tidydata();
},
onShow() {
self.Getdata()
self.isorderstate()
// self.isorderstate()
},
onPullDownRefresh(){
self.Getdata();
... ... @@ -517,7 +516,8 @@
watch:{
bug(a,b){
self.$rqs('/api/order/index',{status:1}).then(res=>{
let updata = res.data.data.data;
// let updata = res.data.data.data;
let updata = res.data.data;
// if(updata == undefined){
// updata = res.data.data;
// }
... ... @@ -541,15 +541,15 @@
status:0
}
self.$rqs('/api/order/index',par).then((res)=>{
console.log(`index`,res);
// console.log(`index`,res);
// console.log('myorder__res',res.data.data);
self.orderList= [[],[],[],[],[]];
let indexData = res.data.data.data;
// let indexData = res.data.data.data;
let indexData = res.data.data;
// if(indexData == undefined){
// indexData = res.data.data;
// }
self.orderList[0] = indexData;
console.dir(self.orderList[0]);
self.orderList[0].forEach((item,index)=>{
if(item.order_status == 1 || item.order_status == 11){
self.orderList[1].push(item)
... ... @@ -565,7 +565,6 @@
}
})
self.$forceUpdate()
})
},
suregoods(e){
... ... @@ -658,10 +657,10 @@
this.swiperCurrent = current;
this.current = current;
},
isorderstate(){
// 判断订单状态有没有
this.orderList[0].length == 0 ? this.orderstate = false:this.orderstate = true
}
// isorderstate(){
// // 判断订单状态有没有
// this.orderList[0].length == 0 ? this.orderstate = false:this.orderstate = true
// }
}
}
... ...
<template>
<view class="containerwys" style="padding-top: 332rpx;">
<view style="height: 310rpx; width: 100%;margin-bottom: 24rpx; z-index: 100;" class="fixed top0 left0">
<view style="height: 310rpx; width: 100%;margin-bottom: 24rpx; z-index: 100;" class="fixed top0 left0" v-if="datas">
<view class="headinforshow">
<view class="headinforshowtext" v-if="data.order_status=='1'">
<view class="headinforshowtext" v-if="datas.order_status=='1'">
待支付
</view>
<view class="headinforshowtext" v-if="data.order_status=='2'">
<view class="headinforshowtext" v-if="datas.order_status=='2'">
待发货
</view>
<view class="headinforshowtext" v-if="data.order_status=='3'">
<view class="headinforshowtext" v-if="datas.order_status=='3'">
待收货
</view>
<view class="headinforshowtext" v-if="data.order_status=='4'">
<view class="headinforshowtext" v-if="datas.order_status=='4'">
已完成
</view>
<view class="headinforshowtext" v-if="data.order_status=='21'">
<view class="headinforshowtext" v-if="datas.order_status=='21'">
后台审核中
</view>
<view class="headinforshowtext" v-if="data.order_status== '11'">
<view class="headinforshowtext" v-if="datas.order_status== '11'">
已取消
</view>
<view class="headinforshowtext" v-if="data.order_status == `21`&&data.refund_status==`1`">
<view class="headinforshowtext" v-if="datas.order_status == `21`&&datas.refund_status==`1`">
退款成功
</view>
<view class="detailsText1" v-show="data.order_status == '1'">
<view class="detailsText1" v-show="datas.order_status == '1'">
<view class="lasttime">
剩余支付时间
</view>
<u-count-down class="counttime" ref="uCountDown" :autoplay='false' font-size="22"
:timestamp="data.countdown" :show-days="false" :show-hours="false" @change="gettimedown">
:timestamp="datas.countdown" :show-days="false" :show-hours="false" @change="gettimedown">
</u-count-down>
<view class="lasttime1">
逾期自动取消
... ... @@ -41,34 +41,34 @@
<view class="addressinfor" style="transform: translateY(-2rpx);">
<image src="/static/order/addressIcon.png" mode="widthFix"></image>
<view class="addressinfortext">
{{data.sh_address}}
{{datas.sh_address}}
</view>
<view class="inforname">
<text class="name" v-cloak>
{{data.sh_name}}
{{datas.sh_name}}
</text>
<text class="phonenumber" v-cloak>
{{data.sh_mobile}}
{{datas.sh_mobile}}
</text>
</view>
</view>
</view>
<view>
<view class="neworderComm" v-if="data.order_status == '3'">
<image :src="data.goods_detail[0].image"></image>
<view class="neworderComm" v-if="datas.order_status == '3'">
<image :src="datas.goods_detail[0].image"></image>
<view class="orderCommtext" v-cloak>
{{data.goods_detail[0].goods_name}}
{{datas.goods_detail[0].goods_name}}
</view>
<view class="smell" v-cloak>
{{data.goods_specc[0].spec_value}}
{{data.goods_specc[1].spec_value}}
{{data.goods_specc[2].spec_value}}
{{datas.goods_specc[0].spec_value}}
{{datas.goods_specc[1].spec_value}}
{{datas.goods_specc[2].spec_value}}
</view>
<view class="orderspnumberv-cloak">
X{{data.goods_detail[0].total_num}}
X{{datas.goods_detail[0].total_num}}
</view>
<view class="price" v-cloak>
¥{{data.total_price}}
¥{{datas.total_price}}
</view>
<view style="position: absolute; width: 168rpx; height: 64rpx;border:1rpx solid #D6D6D6;
color: #D1D1D1; line-height: 64rpx; text-align: center; top: 236rpx;right: 34rpx;
... ... @@ -77,20 +77,20 @@
</view>
</view>
<view class="orderComm" v-else>
<image :src="data.goods_detail[0].image"></image>
<image :src="datas.goods_detail[0].image"></image>
<view class="orderCommtext" v-cloak>
{{data.goods_detail[0].goods_name}}
{{datas.goods_detail[0].goods_name}}
</view>
<view class="smell" v-cloak>
{{data.goods_specc[0].spec_value}}
{{data.goods_specc[1].spec_value}}
{{data.goods_specc[2].spec_value}}
{{datas.goods_specc[0].spec_value}}
{{datas.goods_specc[1].spec_value}}
{{datas.goods_specc[2].spec_value}}
</view>
<view class="orderspnumber" v-cloak>
X{{data.goods_detail[0].total_num}}
X{{datas.goods_detail[0].total_num}}
</view>
<view class="price" v-cloak>
¥{{data.total_price}}
¥{{datas.total_price}}
</view>
</view>
... ... @@ -127,7 +127,7 @@
</view>
</u-popup>
</view>
<!-- <dill :user_coupon_id='data.user_coupon_id' :total_price='total_price' :coupon_price='data.coupon_price' /> -->
<!-- <dill :user_coupon_id='datas.user_coupon_id' :total_price='total_price' :coupon_price='datas.coupon_price' /> -->
<view class="dillbox">
<view>
<view class="row">
... ... @@ -135,7 +135,7 @@
商品总价
</view>
<view class="price" v-cloak>
¥{{data.total_price}}
¥{{datas.total_price}}
</view>
</view>
<view class="row" v-if="true">
... ... @@ -146,28 +146,28 @@
-¥19
</view>
</view>
<view class="row" v-if="true">
<view class="row" v-if="datas.user_coupon_id.length > 0">
<view class="text1">
店铺优惠券
</view>
<view class="price1" v-cloak>
-¥{{data.user_coupon_id[0].price}}
-¥{{datas.user_coupon_id[0].price}}
</view>
</view>
<view class="row" v-if="true">
<view class="row" v-if="datas.user_coupon_id[1]">
<view class="text1" v-cloak>
{{data.user_coupon_id[1].name}}
{{datas.user_coupon_id[1].name}}
</view>
<view class="price1" v-cloak>
-¥{{data.user_coupon_id[1].price}}
-¥{{datas.user_coupon_id[1].price}}
</view>
</view>
<view class="row" v-if="true">
<view class="row" v-if="datas.user_coupon_id[2]">
<view class="text1" v-cloak>
{{data.user_coupon_id[2].name}}
{{datas.user_coupon_id[2].name}}
</view>
<view class="price1">
-¥{{data.user_coupon_id[2].price}}
-¥{{datas.user_coupon_id[2].price}}
</view>
</view>
</view>
... ... @@ -182,25 +182,25 @@
<view class="line1"></view>
<view class="row" style="display: flex;">
<view style="width: 220rpx; height: 40rpx;line-height: 72rpx;text-align: right; flex: 1;">
实付款:<view style="color: #ee0f5d; display: inline-block;">¥{{data.coupon_price}}</view>
实付款:<view style="color: #ee0f5d; display: inline-block;">¥{{datas.coupon_price}}</view>
</view>
</view>
</view>
<!-- <LogisticsInfor :receipt_time='receipt_time' :freight_time='freight_time' :sinNum='q' :order_no='data.order_no' :express_no='data.express_no' :express_company='express_company' :remark='data.remark'/> -->
<!-- <LogisticsInfor :receipt_time='receipt_time' :freight_time='freight_time' :sinNum='q' :order_no='datas.order_no' :express_no='datas.express_no' :express_company='express_company' :remark='datas.remark'/> -->
<!-- 物流信息组件 -->
<view class="box">
<view class="row1 public" v-if="data.order_status !=1">
<view class="row1 public" v-if="datas.order_status !=1">
<view class="sinNumText">快递单号</view>
<view class="sinNum" v-cloak>{{data.express_no}}</view>
<view class="Copy" @click="$clickCopy(data.express_no)">复制</view>
<view class="sinNum" v-cloak>{{datas.express_no}}</view>
<view class="Copy" @click="$clickCopy(datas.express_no)">复制</view>
</view>
<view class="row2 public">
<view class="sinNumText">订单编号</view>
<view class="sinNum" v-cloak>{{data.order_no}}</view>
<view class="sinNum" v-cloak>{{datas.order_no}}</view>
</view>
<view class="row3 public" v-if="data.order_status !=1">
<view class="row3 public" v-if="datas.order_status !=1">
<view class="sinNumText">快递公司</view>
<view class="sinNum" v-cloak>{{data.express_company}}</view>
<view class="sinNum" v-cloak>{{datas.express_company}}</view>
</view>
<view class="row3 public">
<view class="sinNumText">支付方式</view>
... ... @@ -208,50 +208,50 @@
</view>
<view class="row4 public">
<view class="sinNumText">备注</view>
<view class="sinNum" v-cloak>{{data.remark}}</view>
<view class="sinNum" v-cloak>{{datas.remark}}</view>
</view>
<view class="row5 public">
<view class="order_time">下单时间</view>
<view class="orderdatetime" v-cloak>{{$u.timeFormat(data.createtime, 'yyyy-mm-dd hh:M:ss')}}</view>
<view class="orderdatetime" v-cloak>{{$u.timeFormat(datas.createtime, 'yyyy-mm-dd hh:M:ss')}}</view>
</view>
<view class="row5 public" v-if="data.order_status == '11'">
<view class="row5 public" v-if="datas.order_status == '11'">
<view class="order_time">取消时间</view>
<view class="orderdatetime" v-cloak>{{$u.timeFormat(data.qxtime, 'yyyy-mm-dd hh:M:ss')}}</view>
<view class="orderdatetime" v-cloak>{{$u.timeFormat(datas.qxtime, 'yyyy-mm-dd hh:M:ss')}}</view>
</view>
<view class="row5 public" v-if="data.order_status != 1">
<view class="row5 public" v-if="datas.order_status != 1">
<view class="order_time">付款时间</view>
<view class="orderdatetime" v-cloak>{{$u.timeFormat(data.pay_time, 'yyyy-mm-dd hh:M:ss')}}</view>
<view class="orderdatetime" v-cloak>{{$u.timeFormat(datas.pay_time, 'yyyy-mm-dd hh:M:ss')}}</view>
</view>
<view class="row5 public" v-if="data.order_status !=1">
<view class="row5 public" v-if="datas.order_status !=1">
<view class="order_time">发货时间</view>
<view class="orderdatetime" v-cloak>{{$u.timeFormat(data.freight_time, 'yyyy-mm-dd hh:M:ss')}}</view>
<view class="orderdatetime" v-cloak>{{$u.timeFormat(datas.freight_time, 'yyyy-mm-dd hh:M:ss')}}</view>
</view>
<view class="row5 public" v-if="data.order_status !=1&&data.order_status!=21&&data.order_status!=3">
<view class="row5 public" v-if="datas.order_status !=1&&datas.order_status!=21&&datas.order_status!=3">
<view class="order_time">收货时间</view>
<view class="orderdatetime" v-cloak>{{$u.timeFormat(data.receipt_time, 'yyyy-mm-dd hh:M:ss')}}</view>
<view class="orderdatetime" v-cloak>{{$u.timeFormat(datas.receipt_time, 'yyyy-mm-dd hh:M:ss')}}</view>
</view>
<view class="row5 public" v-if="data.order_status!= 1&&data.order_status!=3&&data.order_status!=4">
<view class="row5 public" v-if="datas.order_status!= 1&&datas.order_status!=3&&datas.order_status!=4">
<view class="order_time">申请退款时间</view>
<view class="orderdatetime" v-cloak>{{$u.timeFormat(data.sqtktime, 'yyyy-mm-dd hh:M:ss')}}</view>
<view class="orderdatetime" v-cloak>{{$u.timeFormat(datas.sqtktime, 'yyyy-mm-dd hh:M:ss')}}</view>
</view>
<view class="row5 public"
v-if="data.order_status !=1&&data.order_status!=21&&data.order_status!=3&&data.order_status!=4">
v-if="datas.order_status !=1&&datas.order_status!=21&&datas.order_status!=3&&datas.order_status!=4">
<view class="order_time">退款成功时间</view>
<view class="orderdatetime" v-cloak>{{$u.timeFormat(data.tkcgtime, 'yyyy-mm-dd hh:M:ss')}}</view>
<view class="orderdatetime" v-cloak>{{$u.timeFormat(datas.tkcgtime, 'yyyy-mm-dd hh:M:ss')}}</view>
</view>
</view>
<view class="callWaiter" v-if="data.order_status == '21'">
<view class="callWaiter" v-if="datas.order_status == '21'">
<view class="adj">客服电话:1875623659</view>
<view class="clickCall" @click="$callup(phone)">一键拨号</view>
</view>
<view class="returnbtn">
<view class="btn" @click="DELOrder" v-if="data.order_status == '11'||data.order_status == '4'">删除订单</view>
<view class="btn" @click="SQtuikuan" v-if="data.order_status == '2'">申请退款</view>
<view class="btn" @click="Receipt" v-if="data.order_status == '3'">确认收货</view>
<view class="btn" @click="returnbtn" v-if="data.order_status == '21'">返回列表</view>
<view class="btn" @click="DELOrder" v-if="datas.order_status == '11'||datas.order_status == '4'">删除订单</view>
<view class="btn" @click="SQtuikuan" v-if="datas.order_status == '2'">申请退款</view>
<view class="btn" @click="Receipt" v-if="datas.order_status == '3'">确认收货</view>
<view class="btn" @click="returnbtn" v-if="datas.order_status == '21'">返回列表</view>
<view class="btnYN" v-if=" data.order_status== '1'">
<view class="btnYN" v-if=" datas.order_status== '1'">
<view class="btnNo" @click="open(0)">取消付款</view>
<view class="btnYes" @click="WXpay(currorderid)">支付</view>
</view>
... ... @@ -342,10 +342,8 @@
phone: 1875623659, //客服电话
WXnumber: 1875623659,
q: '98756456876354687',
currorderid: null,
data: null,
currorderid: '',
datas: '',
}
},
onLoad(e) {
... ... @@ -370,7 +368,7 @@
methods: {
SQtuikuan() {
self.$rqs('/api/order/refund', {
id:self.data.id
id:self.datas.id
}).then(res => {
console.log('后台审核');
})
... ... @@ -380,7 +378,7 @@
YnoFK() {
// 点击确认取消付款
self.$rqs('/api/order/cancel', {
id:self.data.id
id:self.datas.id
}).then(res => {
console.log('取消订单成功');
uni.navigateBack({
... ... @@ -396,8 +394,9 @@
self.$rqs('/api/order/detail', {
id:self.currorderid
}).then(res => {
self.data = res.data.data;
console.log('self.data', self.data);
self.datas = res.data.data;
console.log('self.data', self.datas);
console.log('datas.order_status', self.datas.order_status);
})
},
detailsDel() {
... ... @@ -485,7 +484,7 @@
if (e == 0) {
console.log(`倒计时结束`);
let d; //用来保存id
self.data.order_status = 11
self.datas.order_status = 11
self.$rqs('/api/order/text', {
id:self.currorderid
}).then(res => {
... ...