售后物流填写提交,部分状态ui编写
This commit is contained in:
@ -30,35 +30,35 @@ export function getAfterSalesDeatail(key) {
|
|||||||
|
|
||||||
// 查询订单
|
// 查询订单
|
||||||
export function getAfterSealsDetail (key, id) {
|
export function getAfterSealsDetail (key, id) {
|
||||||
return request.get(`/api/store/detail/${key}/${id}`)
|
return request.get(`/store/detail/${key}/${id}`)
|
||||||
}
|
}
|
||||||
|
|
||||||
// 搜索
|
// 搜索
|
||||||
export function searchAfterSealsDetail (key) {
|
export function searchAfterSealsDetail (key) {
|
||||||
return request.get(`/api/store/detail/${key}`)
|
return request.get(`/store/detail/${key}`)
|
||||||
}
|
}
|
||||||
|
|
||||||
// 撤销售后订单
|
// 撤销售后订单
|
||||||
export function rebackAfterSeals (key, id) {
|
export function rebackAfterSeals (key, id) {
|
||||||
return request.get(`/api/revoke/revoke/${key}/${id}`)
|
return request.get(`/revoke/${key}/${id}`)
|
||||||
}
|
}
|
||||||
|
|
||||||
// 获取物流信息
|
// 获取物流信息
|
||||||
export function getExpressData () {
|
export function getExpressData () {
|
||||||
return request.get('/api/yxExpress')
|
return request.get('/yxExpress')
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 添加快递单号
|
// 添加快递单号
|
||||||
export function addExpressData (params) {
|
export function addExpressData (params) {
|
||||||
return request.post('/api/addLogisticsInformation', params, {
|
return request.post('/addLogisticsInformation?' + `code=${params.code}&name=${params.name}&postalCode=${params.postalCode}&orderCode=${params.orderCode}&`, '', {
|
||||||
login: true
|
login: true
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
// 删除售后订单
|
// 删除售后订单
|
||||||
export function deleteAfterSeals (params) {
|
export function deleteAfterSeals (params) {
|
||||||
return request.delete('/api/deleteAfterSalesOrder', params, {
|
return request.delete('/deleteAfterSalesOrder', params, {
|
||||||
login: true
|
login: true
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
@ -327,6 +327,12 @@
|
|||||||
"navigationBarTitleText": "我的售后"
|
"navigationBarTitleText": "我的售后"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"path": "pages/order/submitExpress/index",
|
||||||
|
"style": {
|
||||||
|
"navigationBarTitleText": "售后物流填写"
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"path": "pages/orderAdmin/OrderIndex/index",
|
"path": "pages/orderAdmin/OrderIndex/index",
|
||||||
"style": {
|
"style": {
|
||||||
|
@ -48,8 +48,14 @@
|
|||||||
></textarea>
|
></textarea>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view v-if="serviceType === 0" class="returnBnt bg-color-red" @click="submit">申请退款</view>
|
<view v-if="serviceType === 0"
|
||||||
<view v-if="serviceType === 1" class="returnBnt bg-color-red" @click="submit">申请退货</view>
|
class="returnBnt bg-color-red"
|
||||||
|
@click="submit"
|
||||||
|
>申请退款</view>
|
||||||
|
<view v-if="serviceType === 1"
|
||||||
|
class="returnBnt bg-color-red"
|
||||||
|
@click="submit"
|
||||||
|
>申请退货</view>
|
||||||
</view>
|
</view>
|
||||||
<!-- 选择商品 -->
|
<!-- 选择商品 -->
|
||||||
<view class="selectProduct" v-else>
|
<view class="selectProduct" v-else>
|
||||||
|
@ -253,13 +253,11 @@
|
|||||||
}
|
}
|
||||||
})"
|
})"
|
||||||
>查看物流</view>
|
>查看物流</view>
|
||||||
<view class="bnt default" @click="goGoodsReturn(orderInfo)">申请退款</view>
|
|
||||||
<view class="bnt bg-color-red" @click="takeOrder">确认收货</view>
|
<view class="bnt bg-color-red" @click="takeOrder">确认收货</view>
|
||||||
</template>
|
</template>
|
||||||
<template v-if="orderInfo.shippingType == 1 && status.type == 3 && orderInfo.deliveryType == 'express'">
|
<template v-if="orderInfo.shippingType == 1 && status.type == 3 && orderInfo.deliveryType == 'express'">
|
||||||
<view class="bnt default"
|
<view class="bnt default"
|
||||||
@click="$yrouter.push({ path: '/pages/order/Logistics/index' ,query:{id:orderInfo.orderId }})">查看物流</view>
|
@click="$yrouter.push({ path: '/pages/order/Logistics/index' ,query:{id:orderInfo.orderId }})">查看物流</view>
|
||||||
<view class="bnt default" @click="goGoodsReturn(orderInfo)">申请退款</view>
|
|
||||||
</template>
|
</template>
|
||||||
<template v-if="orderInfo.shippingType == 1 && status.type == 4">
|
<template v-if="orderInfo.shippingType == 1 && status.type == 4">
|
||||||
<view class="bnt cancel" @click="delOrder">删除订单</view>
|
<view class="bnt cancel" @click="delOrder">删除订单</view>
|
||||||
|
@ -1,74 +1,206 @@
|
|||||||
<template>
|
<template>
|
||||||
<view class="returnList">
|
<view class="returnList">
|
||||||
<!-- 给header上与data上加on为退款订单-->
|
<view class="data bgRed">
|
||||||
<view class="header bg-color-red acea-row row-middle" :class="refundOrder ? 'on' : ''">
|
<view v-if="orderDetail.salesState === 0">
|
||||||
<view class="data" :class="refundOrder ? 'on' : ''">
|
<view class="state" v-if="orderDetail.state === 0">
|
||||||
<view class="state">{{ orderInfo._status._msg }}</view>
|
已提交申请,请耐心等待卖家处理
|
||||||
<view>{{ orderInfo.createTime || '' }}</view>
|
</view>
|
||||||
|
<view class="state" v-if="orderDetail.state === 1">
|
||||||
|
<view class="state" v-if="orderDetail.serviceType === 0">
|
||||||
|
已通过平台审核,正在退款
|
||||||
|
</view>
|
||||||
|
<view class="state" v-if="orderDetail.serviceType === 1">
|
||||||
|
已通过平台审核 ,请填写退货物流
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="state" v-if="orderDetail.state === 2">
|
||||||
|
已发货,等待商家审核
|
||||||
|
</view>
|
||||||
|
<view class="state" v-if="orderDetail.state === 3">
|
||||||
|
售后订单已完成
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view v-if="orderDetail.salesState === 1">
|
||||||
|
已撤销售后订单
|
||||||
|
</view>
|
||||||
|
<view v-if="orderDetail.salesState === 2">
|
||||||
|
商家已拒绝售后申请
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<!-- 退款总金额 -->
|
<!-- 退款总金额 -->
|
||||||
<view class="money">
|
<view class="money">
|
||||||
<view class="top">
|
<view class="top">
|
||||||
<text>退款总金额</text>
|
<text>退款总金额</text>
|
||||||
<text class="colorRed">¥{{200.0}}</text>
|
<text class="colorRed">¥{{ orderDetail.refundAmount || 0}}</text>
|
||||||
|
</view>
|
||||||
|
<view class="express" v-if="orderDetail.serviceType === 1">
|
||||||
|
<view class="title">商家已同意退货申请,请尽快发货。</view>
|
||||||
|
<view class="info people">
|
||||||
|
收货人: {{ orderDetail.consignee || '' }}
|
||||||
|
</view>
|
||||||
|
<view class="info address">
|
||||||
|
收货地址: {{ orderDetail.address || '' }}
|
||||||
|
</view>
|
||||||
|
<view class="info phone">
|
||||||
|
收货电话: {{ orderDetail.phoneNumber || '' }}
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<!-- 退款信息 -->
|
<!-- 退款信息 -->
|
||||||
<view class="tips">
|
<view class="tips" v-if="orderDetail.state === 0">
|
||||||
<text class="title">您已成功发起退款申请,请耐心等待商家处理</text>
|
<text class="title">您已成功发起退款申请,请耐心等待商家处理</text>
|
||||||
<view class="content">
|
<view class="content">
|
||||||
<view>· 卖家同意或超时未处理,系统将退款给您</view>
|
<view>· 卖家同意或超时未处理,系统将退款给您</view>
|
||||||
<view>· 如果卖家拒绝,您可以修改退款申请后再次发起,卖家会重新处理</view>
|
<view>· 如果卖家拒绝,您可以修改退款申请后再次发起,卖家会重新处理</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
<!-- 撤销 -->
|
||||||
|
<!-- <view class="tips" v-if="orderDetail.serviceType === 1 && orderDetail.state >= 2">
|
||||||
|
<text class="title">您已撤销售后申请</text>
|
||||||
|
<view class="content">
|
||||||
|
<view>· </view>
|
||||||
|
<view>· </view>
|
||||||
|
</view>
|
||||||
|
</view> -->
|
||||||
|
<!-- 商家拒接 -->
|
||||||
|
<!-- <view class="tips" v-if="orderDetail.serviceType === 2 && orderDetail.state >= 2">
|
||||||
|
<text class="title">卖家已拒绝</text>
|
||||||
|
<view class="content">
|
||||||
|
<view>· </view>
|
||||||
|
<view>· </view>
|
||||||
|
</view>
|
||||||
|
</view> -->
|
||||||
<view class="bottom">
|
<view class="bottom">
|
||||||
<view class="btns def" @click="cancelReq">撤销申请</view>
|
<view class="btns redBtn"
|
||||||
<view class="btns redBtn" @click="editReq">修改申请</view>
|
v-if="orderDetail.salesState === 0
|
||||||
|
&& orderDetail.serviceType === 1
|
||||||
|
&& orderDetail.state === 1"
|
||||||
|
@click="toExpress"
|
||||||
|
>填写物流</view>
|
||||||
|
<view class="btns def"
|
||||||
|
v-if="orderDetail.salesState === 0"
|
||||||
|
@click="cancelReq"
|
||||||
|
>撤销申请</view>
|
||||||
|
<!-- <view class="btns redBtn" @click="editReq">修改申请</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<!-- 退款信息 -->
|
<!-- 退款信息 -->
|
||||||
<view class="rebackInfo">
|
<view class="rebackInfo">
|
||||||
<view class="top">
|
<view class="top">
|
||||||
|
退款信息
|
||||||
|
</view>
|
||||||
|
<view class="rebackItem"
|
||||||
|
v-for="item in orderDetail.cartInfo"
|
||||||
|
:key="item.id"
|
||||||
|
>
|
||||||
|
<image class="img" :src="item.productInfo.image" mode=""></image>
|
||||||
|
<view class="info">
|
||||||
|
<view class="productName">
|
||||||
|
{{ item.productInfo.storeName }}
|
||||||
|
</view>
|
||||||
|
<view class="sku">
|
||||||
|
{{ item.productInfo.attrInfo.sku }}
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="Item">
|
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
<view class="bottom">
|
<view class="bottom">
|
||||||
|
<view class="reason">
|
||||||
|
<view class="left">
|
||||||
|
退款原因:
|
||||||
|
</view>
|
||||||
|
<view class="right">
|
||||||
|
{{ orderDetail.reasons || '' }}
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<!-- 协商历史 -->
|
<view class="reason">
|
||||||
<view class="history">
|
<view class="left">
|
||||||
<view class="top">
|
退款金额:
|
||||||
|
</view>
|
||||||
|
<view class="right">
|
||||||
|
¥{{ orderDetail.refundAmount || 0 }}
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="reason">
|
||||||
|
<view class="left">
|
||||||
|
退款编号:
|
||||||
|
</view>
|
||||||
|
<view class="right">
|
||||||
|
{{ orderDetail.id || '' }}
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="reason">
|
||||||
|
<view class="left">
|
||||||
|
申请时间:
|
||||||
|
</view>
|
||||||
|
<view class="right">
|
||||||
|
{{ orderDetail.createTime || '' }}
|
||||||
</view>
|
</view>
|
||||||
<view class="stepList">
|
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
<view class="bottom">
|
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
import{
|
||||||
|
getAfterSealsDetail,
|
||||||
|
rebackAfterSeals
|
||||||
|
} from '@/api/aftersales.js';
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
orderInfo: {}
|
orderId: '',
|
||||||
|
id: '',
|
||||||
|
orderInfo: {},
|
||||||
|
orderDetail: {}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
|
this.orderId = this.$yroute.query.key
|
||||||
|
this.id = this.$yroute.query.id
|
||||||
this.getReturnDetail()
|
this.getReturnDetail()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
getReturnDetail() {
|
/** state售后状态 0已提交等待平台审核 1平台已审核 等待用户发货/退款 2 用户已发货 3已完成 */
|
||||||
console.log(this.$yroute.query)
|
async getReturnDetail() {
|
||||||
|
const res = await getAfterSealsDetail(this.orderId, this.id)
|
||||||
|
if (res.status === 200) {
|
||||||
|
this.orderDetail = res.data
|
||||||
|
} else {
|
||||||
|
uni.showToast({
|
||||||
|
title: "订单异常",
|
||||||
|
icon: "none",
|
||||||
|
duration: 2000,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
},
|
||||||
|
toExpress () {
|
||||||
|
this.$yrouter.push({
|
||||||
|
path: '/pages/order/submitExpress/index',
|
||||||
|
query: {
|
||||||
|
orderCode: this.orderId
|
||||||
|
}
|
||||||
|
})
|
||||||
},
|
},
|
||||||
// 撤销申请
|
// 撤销申请
|
||||||
cancelReq() {},
|
async cancelReq() {
|
||||||
|
const res = await rebackAfterSeals(this.orderId, this.id)
|
||||||
|
if (res.status === 200) {
|
||||||
|
uni.showToast({
|
||||||
|
title: "已撤销",
|
||||||
|
icon: "none",
|
||||||
|
duration: 2000,
|
||||||
|
});
|
||||||
|
setTimeout(() => {
|
||||||
|
this.$yrouter.back();
|
||||||
|
}, 1500)
|
||||||
|
} else {
|
||||||
|
uni.showToast({
|
||||||
|
title: "撤销失败",
|
||||||
|
icon: "none",
|
||||||
|
duration: 2000,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
},
|
||||||
// 修改申请
|
// 修改申请
|
||||||
editReq() {}
|
editReq() {}
|
||||||
}
|
}
|
||||||
@ -84,6 +216,13 @@ $red: #EB3729;
|
|||||||
.bgRed{
|
.bgRed{
|
||||||
background-color: $red;
|
background-color: $red;
|
||||||
}
|
}
|
||||||
|
.data{
|
||||||
|
width: 100%;
|
||||||
|
height: 150rpx;
|
||||||
|
line-height: 150rpx;
|
||||||
|
padding-left: 30rpx;
|
||||||
|
color: #FFF;
|
||||||
|
}
|
||||||
.money{
|
.money{
|
||||||
background-color: #FFF;
|
background-color: #FFF;
|
||||||
.top{
|
.top{
|
||||||
@ -93,6 +232,16 @@ $red: #EB3729;
|
|||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
border-bottom: 2rpx solid #F3F4F5;
|
border-bottom: 2rpx solid #F3F4F5;
|
||||||
}
|
}
|
||||||
|
.express{
|
||||||
|
padding: 20rpx 30rpx;
|
||||||
|
font-size: 26rpx;
|
||||||
|
.title{
|
||||||
|
color: #333333;
|
||||||
|
}
|
||||||
|
.info{
|
||||||
|
color: #999999;
|
||||||
|
}
|
||||||
|
}
|
||||||
.tips{
|
.tips{
|
||||||
height: 160rpx;
|
height: 160rpx;
|
||||||
padding: 20rpx 30rpx;
|
padding: 20rpx 30rpx;
|
||||||
@ -115,13 +264,13 @@ $red: #EB3729;
|
|||||||
.btns{
|
.btns{
|
||||||
width: 160rpx;
|
width: 160rpx;
|
||||||
height: 58rpx;
|
height: 58rpx;
|
||||||
|
margin: 0 10rpx;
|
||||||
font-size: 24rpx;
|
font-size: 24rpx;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
line-height: 58rpx;
|
line-height: 58rpx;
|
||||||
border-radius: 180rpx;
|
border-radius: 180rpx;
|
||||||
}
|
}
|
||||||
.def{
|
.def{
|
||||||
margin-right: 20rpx;
|
|
||||||
color: #DDDDDD;
|
color: #DDDDDD;
|
||||||
border: 2rpx solid #DDDDDD;
|
border: 2rpx solid #DDDDDD;
|
||||||
}
|
}
|
||||||
@ -131,5 +280,55 @@ $red: #EB3729;
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
.rebackInfo{
|
||||||
|
padding: 0 30rpx;
|
||||||
|
background-color: #FFF;
|
||||||
|
.top{
|
||||||
|
height: 80rpx;
|
||||||
|
margin: 20rpx 0;
|
||||||
|
line-height: 80rpx;
|
||||||
|
font-size: 30rpx;
|
||||||
|
font-weight: bold;
|
||||||
|
color: #333333;
|
||||||
|
border-bottom: 2rpx solid #F3F4F5;
|
||||||
|
}
|
||||||
|
.rebackItem{
|
||||||
|
padding: 20rpx 0;
|
||||||
|
font-size: 28rpx;
|
||||||
|
display: flex;
|
||||||
|
border-bottom: 2rpx solid #F3F4F5;
|
||||||
|
.img{
|
||||||
|
width: 120rpx;
|
||||||
|
height: 120rpx;
|
||||||
|
}
|
||||||
|
.info{
|
||||||
|
margin-left: 16rpx;
|
||||||
|
flex: 1;
|
||||||
|
.productName{
|
||||||
|
width: 100%;
|
||||||
|
height: 80rpx;
|
||||||
|
overflow: hidden;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
color: #333333;
|
||||||
|
}
|
||||||
|
.sku{
|
||||||
|
font-size: 24rpx;
|
||||||
|
color: #CCCCCC;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.bottom{
|
||||||
|
padding: 20rpx 0;
|
||||||
|
.reason{
|
||||||
|
font-size: 28rpx;
|
||||||
|
color: #333333;
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-between;
|
||||||
|
.right{
|
||||||
|
color: #AAAAAA;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
@ -21,23 +21,23 @@
|
|||||||
</view>
|
</view>
|
||||||
<view class="iconfont icon-jiantou"></view>
|
<view class="iconfont icon-jiantou"></view>
|
||||||
</view>
|
</view>
|
||||||
<div class="address acea-row row-between-wrapper" v-if="shipping_type === 1" @click="showStoreList">
|
<view class="address acea-row row-between-wrapper" v-if="shipping_type === 1" @click="showStoreList">
|
||||||
<div class="addressCon" v-if="storeItems">
|
<view class="addressCon" v-if="storeItems">
|
||||||
<div class="name">
|
<view class="name">
|
||||||
{{ storeItems.name }}
|
{{ storeItems.name }}
|
||||||
<span class="phone">{{ storeItems.phone }}</span>
|
<span class="phone">{{ storeItems.phone }}</span>
|
||||||
</div>
|
</view>
|
||||||
<div>{{ storeItems.address }}</div>
|
<view>{{ storeItems.address }}</view>
|
||||||
</div>
|
</view>
|
||||||
<div class="addressCon" v-else>
|
<view class="addressCon" v-else>
|
||||||
<div class="name">
|
<view class="name">
|
||||||
{{ systemStore.name }}
|
{{ systemStore.name }}
|
||||||
<span class="phone">{{ systemStore.phone }}</span>
|
<span class="phone">{{ systemStore.phone }}</span>
|
||||||
</div>
|
</view>
|
||||||
<div>{{ systemStore.address }}</div>
|
<view>{{ systemStore.address }}</view>
|
||||||
</div>
|
</view>
|
||||||
<div class="iconfont icon-jiantou"></div>
|
<view class="iconfont icon-jiantou"></view>
|
||||||
</div>
|
</view>
|
||||||
<view class="line">
|
<view class="line">
|
||||||
<image :src="`${$VUE_APP_RESOURCES_URL}/images/line.jpg`" />
|
<image :src="`${$VUE_APP_RESOURCES_URL}/images/line.jpg`" />
|
||||||
</view>
|
</view>
|
||||||
@ -393,8 +393,6 @@ export default {
|
|||||||
}
|
}
|
||||||
postOrderConfirm(cartIds)
|
postOrderConfirm(cartIds)
|
||||||
.then(res => {
|
.then(res => {
|
||||||
console.log(res, 999999)
|
|
||||||
console.log(res.data.systemStore || {}, 999999)
|
|
||||||
this.offlinePayStatus = res.data.offline_pay_status
|
this.offlinePayStatus = res.data.offline_pay_status
|
||||||
this.orderGroupInfo = res.data
|
this.orderGroupInfo = res.data
|
||||||
this.deduction = res.data.deduction
|
this.deduction = res.data.deduction
|
||||||
|
@ -33,7 +33,18 @@
|
|||||||
</view>
|
</view>
|
||||||
<view class="money">
|
<view class="money">
|
||||||
<view class="status">
|
<view class="status">
|
||||||
<view>审核中</view>
|
<view v-if="item.salesState === 0">
|
||||||
|
<view v-if="item.state === 0">商家处理中</view>
|
||||||
|
<view v-if="item.state === 1">售后中</view>
|
||||||
|
<view v-if="item.state === 2">等待商家收货</view>
|
||||||
|
<view v-if="item.state === 3">已完成</view>
|
||||||
|
</view>
|
||||||
|
<view v-if="item.salesState === 1">
|
||||||
|
已撤销
|
||||||
|
</view>
|
||||||
|
<view v-if="item.salesState === 2">
|
||||||
|
商家拒绝
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="refundMoney">
|
<view class="refundMoney">
|
||||||
退款:<view class="red">
|
退款:<view class="red">
|
||||||
@ -52,6 +63,9 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
import {
|
||||||
|
deleteAfterSeals
|
||||||
|
} from '@/api/aftersales.js'
|
||||||
export default {
|
export default {
|
||||||
props: {
|
props: {
|
||||||
item: {
|
item: {
|
||||||
@ -69,9 +83,13 @@ export default {
|
|||||||
},
|
},
|
||||||
// 跳转售后详情
|
// 跳转售后详情
|
||||||
toDetail (item) {
|
toDetail (item) {
|
||||||
|
console.log(item)
|
||||||
this.$yrouter.push({
|
this.$yrouter.push({
|
||||||
path: "/pages/order/OrderReturnDetail/index",
|
path: "/pages/order/OrderReturnDetail/index",
|
||||||
query: { id: item.orderId }
|
query: {
|
||||||
|
key: item.orderCode,
|
||||||
|
id: item.id
|
||||||
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
174
pages/order/submitExpress/index.vue
Normal file
174
pages/order/submitExpress/index.vue
Normal file
@ -0,0 +1,174 @@
|
|||||||
|
<!-- 提交物流 -->
|
||||||
|
<template>
|
||||||
|
<view class="submitExpress">
|
||||||
|
<!-- 填写物流 -->
|
||||||
|
<view class="form">
|
||||||
|
<picker class="picker"
|
||||||
|
:value="express"
|
||||||
|
:range="expressPicker"
|
||||||
|
@change="changeExpress"
|
||||||
|
>
|
||||||
|
<view class="item acea-row row-between-wrapper">
|
||||||
|
<view class="title">
|
||||||
|
<view class="point">
|
||||||
|
*
|
||||||
|
</view>
|
||||||
|
物流公司
|
||||||
|
</view>
|
||||||
|
<view class="num">{{ express }}</view>
|
||||||
|
<text class="iconfont icon-jiantou"></text>
|
||||||
|
</view>
|
||||||
|
</picker>
|
||||||
|
<view class="item">
|
||||||
|
<view class="title">
|
||||||
|
<view class="point">
|
||||||
|
*
|
||||||
|
</view>
|
||||||
|
物流单号:
|
||||||
|
</view>
|
||||||
|
<input class="input" v-model="expressQuery.postalCode" placeholder="请输入物流单号" />
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<!-- 提交按钮 -->
|
||||||
|
<view class="btnContainer">
|
||||||
|
<view class="addBtn" @click="addExpress">
|
||||||
|
提交
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import {
|
||||||
|
getExpressData,
|
||||||
|
addExpressData
|
||||||
|
} from '@/api/aftersales.js'
|
||||||
|
export default {
|
||||||
|
data () {
|
||||||
|
return {
|
||||||
|
expressQuery: {
|
||||||
|
code: '', // 快递公司编码
|
||||||
|
name: '', // 快递公司名称
|
||||||
|
postalCode: 'SF1213132132', // 快递编号
|
||||||
|
orderCode: '' // 订单编号
|
||||||
|
},
|
||||||
|
expressList: [],
|
||||||
|
expressPicker: [],
|
||||||
|
express: ''
|
||||||
|
}
|
||||||
|
},
|
||||||
|
mounted () {
|
||||||
|
this.expressQuery.orderCode = this.$yroute.query.orderCode
|
||||||
|
this.getExpress()
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
async getExpress () {
|
||||||
|
const res = await getExpressData()
|
||||||
|
console.log(res)
|
||||||
|
this.expressList = res.data.map(item => {
|
||||||
|
return {
|
||||||
|
id: item.id,
|
||||||
|
name: item.name,
|
||||||
|
code: item.code
|
||||||
|
}
|
||||||
|
})
|
||||||
|
this.expressPicker = res.data.map(item => {
|
||||||
|
return item.name
|
||||||
|
})
|
||||||
|
},
|
||||||
|
changeExpress(e) {
|
||||||
|
this.express = this.expressPicker[e.mp.detail.value];
|
||||||
|
this.expressQuery.code = this.expressList[e.mp.detail.value].code
|
||||||
|
this.expressQuery.name = this.expressList[e.mp.detail.value].name
|
||||||
|
},
|
||||||
|
async addExpress () {
|
||||||
|
let errMsg = '请选择'
|
||||||
|
if (!this.expressQuery.code || !this.expressQuery.code) {
|
||||||
|
errMsg += ' 快递公司 '
|
||||||
|
}
|
||||||
|
if (!this.expressQuery.postalCode) {
|
||||||
|
errMsg += ' 快递单号 '
|
||||||
|
}
|
||||||
|
if (errMsg.length > 3) {
|
||||||
|
uni.showToast({
|
||||||
|
title: errMsg,
|
||||||
|
icon: 'none',
|
||||||
|
duration: 2000,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
console.log(this.expressQuery)
|
||||||
|
const res = await addExpressData(this.expressQuery)
|
||||||
|
if (res.status === 200) {
|
||||||
|
uni.showToast({
|
||||||
|
title: '物流填写成功!',
|
||||||
|
icon: 'none',
|
||||||
|
duration: 2000,
|
||||||
|
})
|
||||||
|
this.$yrouter.push({
|
||||||
|
path: '/pages/order/ReturnList/index'
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
uni.showToast({
|
||||||
|
title: '提交物流信息失败!',
|
||||||
|
icon: 'none',
|
||||||
|
duration: 2000,
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.submitExpress{
|
||||||
|
.form{
|
||||||
|
margin-bottom: 170rpx;
|
||||||
|
.picker{
|
||||||
|
margin: 0;
|
||||||
|
padding: 0;
|
||||||
|
font-size: 28rpx;
|
||||||
|
color: #999999;
|
||||||
|
}
|
||||||
|
.item{
|
||||||
|
width: 100%;
|
||||||
|
height: 80rpx;
|
||||||
|
padding: 0 32rpx;
|
||||||
|
line-height: 80rpx;
|
||||||
|
background-color: #FFF;
|
||||||
|
display: flex;
|
||||||
|
.title{
|
||||||
|
font-size: 28rpx;
|
||||||
|
color: #333333;
|
||||||
|
display: flex;
|
||||||
|
.point{
|
||||||
|
color: #EA3729;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.input{
|
||||||
|
height: 80rpx;
|
||||||
|
line-height: 80rpx;
|
||||||
|
font-size: 28rpx;
|
||||||
|
color: #999999;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.btnContainer{
|
||||||
|
width: 100%;
|
||||||
|
height: 170rpx;
|
||||||
|
background-color: #FFF;
|
||||||
|
box-shadow: 0px 0px 0px rgba(197, 202, 207, 0.5);
|
||||||
|
position: fixed;
|
||||||
|
bottom: 0;
|
||||||
|
.addBtn{
|
||||||
|
height: 90rpx;
|
||||||
|
margin: 40rpx 30rpx;
|
||||||
|
line-height: 90rpx;
|
||||||
|
text-align: center;
|
||||||
|
border-radius: 50rpx;
|
||||||
|
font-size: 28rpx;
|
||||||
|
color: #FFF;
|
||||||
|
background: linear-gradient(90deg, #E93526 0%, #FF8E3C 100%);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
Reference in New Issue
Block a user