用户的商品自提及回收订单

version/0412
fanfan 9 months ago
parent aeb39fd867
commit 9ccce30bdf
  1. 4
      api/order.js
  2. 8
      pages.json
  3. 2
      pages/news/park/addressList.vue
  4. 166
      pages/news3/addressList.vue
  5. 3
      pages/news3/sendOutGoods.vue
  6. 62
      pages/news3/shopOrder.vue
  7. 33
      pages/news3/shopOrderDetails.vue
  8. 1
      pages/news3/updateAddr.vue
  9. 1
      pages/news3/updatePrice.vue
  10. 40
      pages/order/detail.vue
  11. 89
      pages/order/index.vue
  12. 28
      pages/user/index.vue

@ -14,8 +14,8 @@ const api = {
orderfast:'order/orderfast'
}
// 催单
export function orderfast(param, option) {
return request.get(api.orderfast, param, option)
export function orderfast(orderId, param) {
return request.get(api.orderfast, { orderId, ...param })
}
// 当前用户待处理的订单数量
export function todoCounts(param, option) {

@ -1114,6 +1114,14 @@
"navigationBarTextStyle": "black",
"navigationBarTitleText": "商品发货"
}
},{
"path": "addressList",
"style": {
// "enablePullDownRefresh": true,
"navigationStyle": "default",
"navigationBarTextStyle": "black",
"navigationBarTitleText": "退货地址"
}
},
{
"path": "JoinDistribution",

@ -1,7 +1,7 @@
<template>
<view class="addressList">
<view style="overflow: hidden;" v-if="addressList.length>0">
<u-swipe-action :show="item.show" :index="index" v-for="(item, index) in addressList" :key="item.id"
<u-swipe-action :show="item.show" :index="index" v-for="(item, index) in addressList" :key="item.address_id"
@click="clickDel(item)" @open="open" :options="options">
<view class="title-wrap">
<view class="item" :style="{'border-top':index==0?'none':'1px solid #EEEEEE'}">

@ -0,0 +1,166 @@
<template>
<view class="addressList">
<view style="overflow: hidden;" v-if="addList.length>0">
<view class="title-wrap" v-for="(item, index) in addList" :key="item.address_id">
<view class="item" :style="{'border-top':index==0?'none':'1px solid #EEEEEE'}" @click="changeAdd(item)">
<view class="a">{{item.name}} {{item.phone}}<text v-if="item.address_id==defaultId">默认</text>
</view>
<view class="b">
<view class="d">
{{item.detail}}
</view>
<u-icon @click="changeAdd(item)" name="checkbox-mark" :color="addIndex==item.address_id?'#F34A40':'#979797'" size="42"></u-icon>
</view>
</view>
</view>
</view>
<u-empty text="暂无数据显示哦~" v-else mode="list"></u-empty>
<view class="footer">
<view class="operaBtn" @click="addAddress">
确认
</view>
</view>
<u-toast ref="uToast" />
</view>
</template>
<script>
import * as newFunApi from '@/api/newFun'
export default {
data() {
return {
addList: [],
defaultId: '',
disabled: false,
btnWidth: 180,
show: false,
delShow: false,
options: [{
text: '删除',
style: {
backgroundColor: '#dd524d'
}
}],
addressId: '',
addIndex:''
};
},
onShow() {
this.getAddressList()
},
methods: {
changeAdd(item){
this.addressData=item
this.addIndex=item.address_id
},
getAddressList() {
const that = this
return new Promise((resolve, reject) => {
newFunApi.addressList({
user_id: 10006
})
.then(result => {
this.addressData=result.data.list[0]
that.addIndex=result.data.list[0].address_id
that.addList = result.data.list
})
.catch(reject)
})
},
addAddress() {
let pages = getCurrentPages()//
let nowPage = pages[ pages.length - 1 ] //
let prevPage = pages[ pages.length - 2 ] //
prevPage.$vm.addressData = this.addressData //
uni.navigateBack({
delta:1 //
})
},
}
}
</script>
<style lang="scss" scoped>
::v-deep .u-empty {
padding: 100rpx 0;
}
.addressList {
padding: 0 45rpx;
background-color: #FFFFFF;
overflow: hidden;
margin-top: 2rpx;
.item {
padding: 30rpx 0;
overflow: hidden;
border-top: 1px solid #EEEEEE;
.a {
font-size: 32rpx;
font-weight: 500;
color: #1E1E1E;
padding-bottom: 25rpx;
display: flex;
align-items: center;
text {
width: 66rpx;
line-height: 34rpx;
background: #F32020;
border-radius: 4rpx;
text-align: center;
display: block;
margin-left: 10rpx;
font-size: 24rpx;
font-weight: 400;
color: #FFFFFF;
border-radius: 5rpx;
}
}
.b {
display: flex;
align-items: flex-start;
justify-content: space-between;
.d {
font-size: 32rpx;
font-weight: 400;
color: #979797;
max-width: 600rpx;
}
image {
width: 36rpx;
height: 36rpx;
margin-right: 10rpx;
}
}
}
}
.footer {
display: flex;
width: 100%;
height: 120rpx;
justify-content: center;
position: fixed;
bottom: 0;
left: 0;
.operaBtn {
width: 686rpx;
height: 92rpx;
background: #F34A40;
border-radius: 8rpx 8rpx 8rpx 8rpx;
opacity: 1;
line-height: 92rpx;
font-size: 28rpx;
font-family: PingFang SC, PingFang SC;
font-weight: 600;
color: #FFFFFF;
text-align: center;
}
}
</style>

@ -129,9 +129,10 @@
if (status == 200) {
uni.hideLoading();
uni.showToast({
title: this.source == 1?'修改成功':'发货成功',
title: this.source == 1 ? '修改成功' : '发货成功',
icon: 'none'
})
uni.$emit('refreshData');
uni.navigateBack({
delta: 1
})

@ -21,7 +21,7 @@
</view>
</view>
<view class="shopContent">
<view class="shopItem" v-if="goodsList.length>0" v-for="(item,index) in goodsList" :key="index">
<view class="shopItem" v-if="goodShopsList.length>0" v-for="(item,index) in goodShopsList" :key="index">
<view class="orderInfo">
<text>订单号{{item.order_no}}</text>
<text class="statusText" style="color: #626262;font-weight: 700;">{{item.state_text}}</text>
@ -55,12 +55,12 @@
</view>
<view class="btnGroup">
<view class="btn info"
v-show="!item.order_refund_id&& item.order_status==10&&item.pay_status==20&&item.delivery_status==30"
v-show="!item.order_refund_id&& item.order_status==10&&item.pay_status==20&&item.delivery_status==10"
@click="goJump('/pages/news3/updateAddr',item,0)">修改地址</view>
<view class="btn primary" v-show="!item.order_refund_id&&item.order_status==10&&item.pay_status==10"
@click="goJump('/pages/news3/updatePrice',item)">修改价格</view>
<view class="btn primary"
v-show="!item.order_refund_id&&item.order_status==10&&item.pay_status==20&&item.delivery_status==30"
v-show="!item.order_refund_id&&item.order_status==10&&item.pay_status==20&&item.delivery_status==10"
@click="goJump('/pages/news3/sendOutGoods',item,2)">发货</view>
<view class="btn info" v-show="item.audit_status==0&&(item.order_status!=20)"
@click="refuseOrder(item,20)">拒绝</view>
@ -71,7 +71,7 @@
删除订单</view>
<view class="btn info" @click="refundAfter(item)" v-show="item.state_text=='receipt'">转至售后</view>
<view class="btn primary"
v-show="!item.order_refund_id&&item.order_status==10&&item.pay_status==20&&item.delivery_status==20"
v-show="!item.order_refund_id&&item.order_status==10&&item.pay_status==20&&(item.delivery_status==20||item.delivery_status==30)"
@click="goJump('/pages/news3/sendOutGoods',item,1)">修改物流</view>
</view>
</view>
@ -151,6 +151,13 @@
</view>
</template>
</u-upload> -->
<view class="tuiAdderss" v-if="audit_status==10">
<text>退货地址:</text>
<view class="" @click="goJump('/pages/news3/addressList','',0)"><text :style="{'color': addressData?'#303030':'#EAEAEA'}"></text>
{{addressData?addressData.name+addressData.phone:'请选择退货地址'}}
<u-icon name="arrow-right" color="#979797" size="28"></u-icon>
</view>
</view>
<view class="filterItemContent">
<view class="itemTitle">
备注
@ -209,7 +216,7 @@
id: 'cancel',
name: '已取消',
}, ],
goodsList: [],
goodShopsList: [],
show: false,
timeShow: false,
afterSale: false,
@ -261,7 +268,7 @@
refund_notes: '',
itemInfor: '',
audit_status: 20,
audit_notes: '',
addressData: '',
user_id: '',
delivery_type: ''
}
@ -295,7 +302,7 @@
},
sureOrder() {
this.pageNum = 1
this.goodsList = [];
this.goodShopsList = [];
this.getList()
this.show = false;
},
@ -319,7 +326,7 @@
});
if (status == 200) {
uni.hideLoading();
this.goodsList = this.goodsList.concat(data.list.data)
this.goodShopsList = this.goodShopsList.concat(data.list.data)
this.total = data.list.total
}
},
@ -334,7 +341,7 @@
onClassify(item, index) {
this.pageNum = 1
this.classifyShow = item.id;
this.goodsList = [];
this.goodShopsList = [];
this.getList()
},
setResourceIndex(index) {
@ -368,7 +375,7 @@
//
app.deleteShow = false
app.pageNum = 1
app.goodsList = [];
app.goodShopsList = [];
app.getList()
})
},
@ -397,34 +404,23 @@
return idList.join(',')
},
async getAddressList() {
let {
status,
message,
data
} = await newFunApi.addressList({
user_id: 10006
});
if (status == 200) {
console.log(data)
}
},
//
refuseOrder(item, status) {
this.itemInfor = item;
this.audit_status = status;
this.afterSale = true
this.afterSale = true;
},
async submitRefund() {
if(this.audit_status==10 &&!this.addressData){
return that.$toast('请选择退货地址')
}
let params = {
"orderId": this.itemInfor.order_id,
"orderRefundId": this.itemInfor.order_refund_id,
"form": {
"audit_status": this.audit_status,
"refund_notes": this.refund_notes,
'refuse_desc': this.audit_notes,
'address_id': this.itemInfor.address ? this.itemInfor.address.order_address_id : '',
"refuse_desc": this.refund_notes,
'address_id': this.addressData.address_id,
}
}
let {
@ -436,13 +432,13 @@
this.afterSale = false
uni.hideLoading();
this.pageNum = 1
this.goodsList = [];
this.goodShopsList = [];
this.getList()
}
},
},
onReachBottom() {
if (this.goodsList.length <= this.total) {
if (this.goodShopsList.length <= this.total) {
this.pageNum++;
this.getList();
}
@ -481,6 +477,14 @@
color: #616161;
}
.tuiAdderss {
padding: 30rpx 0;
display: flex;
align-items: center;
justify-content: space-between;
border-bottom: 1rpx solid #EAEAEA;
}
page {
background-color: #F7F8FA;
min-height: 100%;

@ -170,13 +170,13 @@
<!-- 底部按钮 -->
<view class="footer-btn">
<view class="del"
v-show="!orderInfo.order_refund_id&&orderInfo.order_status==10&&orderInfo.pay_status==20&&orderInfo.delivery_status==30"
v-show="!orderInfo.order_refund_id&&orderInfo.order_status==10&&orderInfo.pay_status==20&&orderInfo.delivery_status==10"
@click="goJump('/pages/news3/updateAddr',orderInfo,0)">修改地址</view>
<view class="btn"
v-show="!orderInfo.order_refund_id&&orderInfo.order_status==10&&orderInfo.pay_status==10"
@click="goJump('/pages/news3/updatePrice',orderInfo)">修改价格</view>
<view class="btn"
v-show="!orderInfo.order_refund_id&&orderInfo.order_status==10&&orderInfo.pay_status==20&&orderInfo.delivery_status==30"
v-show="!orderInfo.order_refund_id&&orderInfo.order_status==10&&orderInfo.pay_status==20&&orderInfo.delivery_status==10"
@click="goJump('/pages/news3/sendOutGoods',orderInfo,2)">发货</view>
<view class="del" v-show="orderInfo.audit_status==0" @click="refuseOrder(orderInfo,20)">拒绝</view>
<view class="btn" v-show="orderInfo.audit_status==0" @click="refuseOrder(orderInfo,10)">同意</view>
@ -184,7 +184,7 @@
v-show="(!orderInfo.order_refund_id&&orderInfo.order_status==30&&orderInfo.pay_status==20&&orderInfo.delivery_status==20)||(!orderInfo.order_refund_id&&orderInfo.order_status==20&&orderInfo.pay_status==10&&orderInfo.delivery_status==10)">
删除订单</view>
<view class="btn"
v-show="!orderInfo.order_refund_id&&orderInfo.order_status==10&&orderInfo.pay_status==20&&orderInfo.delivery_status==20"
v-show="!orderInfo.order_refund_id&&orderInfo.order_status==10&&orderInfo.pay_status==20&&(orderInfo.delivery_status==20||orderInfo.delivery_status==30)"
@click="goJump('/pages/news3/sendOutGoods',orderInfo,1)">修改物流</view>
</view>
</view>
@ -194,6 +194,13 @@
{{audit_status==20?'拒绝':'同意'}}转移至售后
</view>
<view class="filterItem c">
<view class="tuiAdderss" v-if="audit_status==10">
<text>退货地址:</text>
<view class="" @click="goJump('/pages/news3/addressList','',0)"><text :style="{'color': addressData?'#303030':'#EAEAEA'}"></text>
{{addressData?addressData.name+addressData.phone:'请选择退货地址'}}
<u-icon name="arrow-right" color="#979797" size="28"></u-icon>
</view>
</view>
<!-- <view class="itemTitle">
上传照片 <text style="color:#FF5042">*</text><text>最多可传5张图片</text>
</view> -->
@ -233,6 +240,7 @@
</template>
<script>
import * as newFunApi from '@/api/newFun'
export default {
data() {
return {
@ -245,7 +253,7 @@
isToggle: false,
refund_image_id: '',
refund_notes: '',
timestamp: 86400,
addressData:''
};
},
onLoad(option) {
@ -306,13 +314,16 @@
this.afterSale = true
},
async submitRefund() {
if (this.audit_status == 10 && !this.addressData) {
return that.$toast('请选择退货地址')
}
let params = {
"orderId": this.orderInfo.order_id,
"orderRefundId": this.itemInfor.order_refund_id,
"form": {
"audit_status": this.audit_status,
"refund_notes": this.refund_notes,
'refuse_desc': this.audit_notes,
'address_id': this.orderInfo.address ? this.orderInfo.address.order_address_id : '',
'refuse_desc': this.refund_notes,
'address_id': this.addressData.address_id,
'orderRefundId': this.orderInfo.order_refund_id
}
}
@ -351,7 +362,13 @@
min-height: 100%;
padding-bottom: 140rpx;
}
.tuiAdderss {
padding: 30rpx 0;
display: flex;
align-items: center;
justify-content: space-between;
border-bottom: 1rpx solid #EAEAEA;
}
.orderInfo {
display: flex;
align-items: center;

@ -234,6 +234,7 @@
.then(result => {
that.$toast(result.message)
setTimeout(() => {
uni.$emit('refreshData');
uni.navigateBack()
}, 1000)

@ -121,6 +121,7 @@
title: '修改价格成功',
icon: 'none'
})
uni.$emit('refreshData');
uni.navigateBack({
delta: 1
})

@ -57,8 +57,8 @@
<view class="code">
核销码
</view>
<view class="codeNum">
<image :src="qrcodeImage" @click="clickImg" mode=""></image>
<view class="codeNum" @click="onQrcodeImage">
<image :src="qrcodeImage" mode=""></image>
</view>
<view class="openCode">
点击放大核销码
@ -231,7 +231,7 @@
{{order.ziti_status==0?'没提':'已提货'}}
</view>
</view>
<view class="orderTitle">
<view class="orderTitle" v-if="order.ziti_time">
<view class="total">
提货日期
</view>
@ -239,11 +239,11 @@
{{order.ziti_time}}
</view>
</view>
<view class="orderTitle">
<view class="orderTitle" v-if="order.ziti_image">
<view class="total">
提货照片
</view>
<view class="price" v-if="order.ziti_image.length">
<view class="price" v-if="order.ziti_image">
<image v-for="(img, idx) in order.ziti_image" :key="idx" :src="img" mode="" class="goodsImag">
</image>
</view>
@ -280,7 +280,7 @@
v-if="order.pay_status == PayStatusEnum.PENDING.value &&order.order_status == OrderStatusEnum.NORMAL.value">
立即支付
</view>
<view class="buyAgain" @click="onExtractQRCode(order.order_id)" v-if="order.pay_status == PayStatusEnum.SUCCESS.value && order.delivery_type == DeliveryTypeEnum.EXTRACT.value
<view class="buyAgain" @click="onQrcodeImage(order.order_id)" v-if="order.pay_status == PayStatusEnum.SUCCESS.value && order.delivery_type == DeliveryTypeEnum.EXTRACT.value
&& order.delivery_status == DeliveryStatusEnum.NOT_DELIVERED.value">
核销码
</view>
@ -324,13 +324,13 @@
</view>
</view>
</view>
<view class="bigCode" v-if="showQRCodePopup" style="display: none;">
<view class="bigCode" v-if="showQRCodePopup" @click="showQRCodePopup=false">
<view class="cm">
<view class="cm_text">
核销码
自提核销二维
</view>
<view class="txm">
<image src="" mode="" class="codeImg"></image>
<image :src="qrcodeImage" @click="clickImg" mode="" class="codeImg"></image>
</view>
<view class="cline">
<u-line border-style="dashed" color="#D0D0D0" />
@ -456,6 +456,7 @@
app.isLoading = true
OrderApi.detail(app.orderId)
.then(result => {
app.onExtractQRCode(result.data.order.order_id)
app.order = result.data.order
app.setting = result.data.setting
app.isLoading = false
@ -580,9 +581,11 @@
})
.then(result => {
app.qrcodeImage = result.data.qrcode
app.showQRCodePopup = true
})
},
onQrcodeImage(){
this.showQRCodePopup = true
},
// 退
onRefund(orderId, order, item) {
uni.navigateTo({
@ -613,12 +616,14 @@
page{
height: 100%;
}
::v-deep .qrcode-popup{
padding: 44rpx 80rpx !important;
}
.detail {
width: 750rpx;
padding-bottom: 150rpx;
background-image: url('https://www.royaum.com.cn/static/home/homeback.png');
background-size: 100% 100%;
height: 100%;
}
.menuarea {
@ -924,7 +929,7 @@
.goodsImg {
width: 162rpx;
height: 148rpx;
height: 160rpx;
border-radius: 0rpx 0rpx 0rpx 0rpx;
opacity: 1;
@ -943,7 +948,7 @@
font-weight: 400;
color: #1E1E1E;
line-height: 40rpx;
margin-bottom: 4rpx;
margin-bottom: 12rpx;
display: -webkit-box;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
@ -1142,12 +1147,12 @@
.pickedUp {
width: 694rpx;
height: 310rpx;
// height: 310rpx;
background: #FFFFFF;
border-radius: 10rpx 10rpx 10rpx 10rpx;
opacity: 1;
margin: 14rpx 0 0 26rpx;
padding: 32rpx 50rpx 0 42rpx;
padding: 32rpx 50rpx 32rpx 42rpx;
.orderTitle {
position: relative;
@ -1369,6 +1374,9 @@
}
.txm {
display: flex;
justify-content: center;
margin-top: 30rpx;
.codeImg {
width: 394rpx;
height: 458rpx;
@ -1419,7 +1427,7 @@
font-size: 24rpx;
font-weight: 500;
color: #1E1E1E;
padding: 15rpx 0;
text {
font-size: 36rpx;
}

@ -82,7 +82,7 @@
@click="handleTargetGoods(item.goods[0].goods_id)">再次购买</view>
<view class="n"
v-if="item.pay_status == PayStatusEnum.SUCCESS.value && item.delivery_status == DeliveryStatusEnum.NOT_DELIVERED.value"
@click="onCdDia(item.goods_id)">催发货</view>
@click="onCdDia(item.order_id)">催发货</view>
<!-- <view class="n"
v-if="item.pay_status == PayStatusEnum.SUCCESS.value && item.delivery_status == DeliveryStatusEnum.NOT_DELIVERED.value"
@click="onAdress(order.goods_id)">修改地址</view> -->
@ -105,14 +105,22 @@
</view>
</u-modal>
<!-- 核销二维码弹窗 -->
<u-popup v-model="showQRCodePopup" mode="center" border-radius="26" :closeable="true">
<view class="qrcode-popup">
<view class="title">自提核销二维码</view>
<view class="pop-content">
<image v-if="qrcodeImage" class="image" :src="qrcodeImage"></image>
<view class="bigCode" v-if="showQRCodePopup" @click="showQRCodePopup=false">
<view class="cm">
<view class="cm_text">
自提核销二维码
</view>
<view class="txm">
<image :src="qrcodeImage" @click="clickImg" mode="" class="codeImg"></image>
</view>
<view class="cline">
<u-line border-style="dashed" color="#D0D0D0" />
</view>
<view class="sm">
可前往门店扫码完成操作
</view>
</view>
</u-popup>
</view>
<!-- 催单弹框 -->
<view class="dia" v-if="cdDia">
<view class="diaMain">
@ -224,7 +232,7 @@
onShow() {
// :
uni.$on('syncRefresh', canReset => {
this.list=[]
this.list = []
this.getOrderList()
})
},
@ -245,12 +253,12 @@
methods: {
confirm() {
//
this.list=[]
this.list = []
app.getOrderList()
},
changeMenu(index) {
this.list.forEach(item => {
item.menushow=false;
item.menushow = false;
idList.push(item.response.data.fileInfo.file_id)
});
this.list[index].menushow = !this.list[index].menushow
@ -813,4 +821,65 @@
}
}
}
.bigCode {
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: rgba(65, 65, 65, 0.46);
display: flex;
align-items: center;
justify-content: center;
.cm {
width: 560rpx;
height: 714rpx;
background: #FFFFFF;
border-radius: 16rpx 16rpx 16rpx 16rpx;
opacity: 1;
padding-top: 44rpx;
.cm_text {
width: 100%;
height: 42rpx;
font-size: 30rpx;
font-weight: 500;
color: #424242;
line-height: 42rpx;
text-align: center;
}
.txm {
display: flex;
justify-content: center;
margin-top: 30rpx;
.codeImg {
width: 394rpx;
height: 458rpx;
border-radius: 0rpx 0rpx 0rpx 0rpx;
opacity: 1;
}
}
.cline {
padding: 0 34rpx;
margin: 46rpx 0 30rpx 0;
}
.sm {
width: 100%;
height: 34rpx;
font-size: 24rpx;
font-family: PingFang SC, PingFang SC;
font-weight: 500;
color: #979797;
line-height: 28rpx;
text-align: center;
}
}
}
</style>

@ -167,7 +167,8 @@
<view class="goodsManage">
<view class="manageTitle">
<text lines="1" class="text_5 titleLeft">商品订单</text>
<text lines="1" class="text_6 titleRight" @click="goJump('/pages/news3/shopOrder')">查看全部</text>
<text lines="1" class="text_6 titleRight"
@click="goJump(userInfo.user_type == 40?'/pages/news3/shopOrder':'/pages/order/index')">查看全部</text>
<u-icon style="margin-left: 5rpx; color: #909090; margin-top: -5rpx;" name="arrow-right"></u-icon>
</view>
<view class="grounding goodsOrder">
@ -582,7 +583,7 @@
distribution_order: {},
goods_order: {},
service_order: {},
recovery_order:{}
recovery_order: {}
},
actionCountsInfo: {},
userType: 2,
@ -795,14 +796,21 @@
})
},
goGoodsOrder(val) {
// if(this.isLogin == false){
// this.goLogin()
// return;
// }
// //
// uni.navigateTo({
// url: '/pages/order/index?dataType=' + val
// })
if (this.isLogin == false) {
this.goLogin()
return;
}
//
if (this.userInfo.user_type == 40) {
uni.navigateTo({
url: '/pages/news3/shopOrder'
})
} else {
uni.navigateTo({
url: '/pages/order/index?dataType=' + val
})
}
},
goodsDetail(item) {
//

Loading…
Cancel
Save