msb_beta
ch 3 years ago
parent cd457a63b0
commit a7bf93f909

@ -2,7 +2,7 @@
* @Author: ch
* @Date: 2022-03-29 16:47:32
* @LastEditors: ch
* @LastEditTime: 2022-03-31 18:07:46
* @LastEditTime: 2022-04-14 10:14:40
* @Description: file content
*/
@ -15,7 +15,16 @@ const DictOrderStatus = new Enum([
{key : '6', name : '已收货', value: 'finishReceiving'},
{key : '7', name : '已完成', value: 'end'}
])
const DictSaleAfterStatus = {
"1":"已申请",
"2":"已关闭",
"3":"待退货",
"4":"退货中",
"5":"退款中",
"6":"退款成功",
"7":"退款失败"
}
export {
DictOrderStatus
DictOrderStatus,
DictSaleAfterStatus
}

@ -2,14 +2,14 @@
* @Author: ch
* @Date: 2022-03-31 14:49:33
* @LastEditors: ch
* @LastEditTime: 2022-04-11 11:28:16
* @LastEditTime: 2022-04-14 10:01:14
* @Description: file content
-->
<template>
<view class="ui-goods">
<view class="ui-goods-item">
<image class="ui-goods-item--image" mode="widthFix" :src="data.productImageUrl" />
<view >
<view class="ui-goods-item--right">
<view class="ui-goods-item--con">
<text class="ui-goods-item--title">{{data.productName}}</text>
<text class="ui-goods-item--pirce">{{data.realAmount}}</text>
@ -43,12 +43,13 @@ export default {
display: flex;
justify-content: space-between;
&--image{
width: 180rpx;
height: 180rpx;
margin-right: 30rpx;
width: 140rpx;
height: 140rpx;
}
&--right{
width: 474rpx;
}
&--con{
width: 510rpx;
display: flex;
justify-content: space-between;
font-size: $font-size-base;
@ -67,17 +68,20 @@ export default {
margin-left: 60rpx;
}
&--desc{
width: 510rpx;
font-size: $font-size-sm;
color: $color-grey4;
margin-top: 20rpx;
line-height: 39rpx;
display: flex;
justify-content: space-between;
}
&--num{
font-size: $font-size-base;
margin-left: 60rpx;
text{
font-size: $font-size-sm;
color: $color-grey4;
&.ui-goods-item--num{
font-size: $font-size-base;
margin-left: 60rpx;
}
}
}
}
</style>

@ -0,0 +1,56 @@
<!--
* @Author: ch
* @Date: 2022-04-14 11:56:57
* @LastEditors: ch
* @LastEditTime: 2022-04-14 13:36:18
* @Description: file content
-->
<template>
<UiWhiteBox>
<view class="title">
您已成功发起退款申请请耐心等待商家处理
</view>
<view class="content">
<view>商家同意后请按照给出的退货地址退货并请记录退货运单号</view>
<view>如商家拒绝您可以修改申请后再次发起商家会重新处理</view>
<view>如商家超时未处理退货申请将达成请按系统给出的退货地址退货</view>
</view>
<view class="footer">
<UiButton size="min">撤销申请</UiButton>
<UiButton size="min" type="gradual" class="btn">修改申请</UiButton>
</view>
</UiWhiteBox>
</template>
<script>
import UiButton from '../../../../../components/UiButton.vue'
import UiWhiteBox from '../../../../../components/UiWhiteBox.vue'
export default {
components: { UiWhiteBox, UiButton },
}
</script>
<style lang="scss" scoped>
.title{
height: 98rpx;
line-height: 98rpx;
padding-left: 30rpx;
border-bottom: 2rpx solid $color-grey2;
color: $color-yellow3;
}
.content{
padding: 30rpx 30rpx 0;
view{
line-height: 34rpx;
color: $color-grey4;
font-size: $font-size-sm;
margin-bottom: 28rpx;
}
}
.footer{
padding: 0 30rpx 30rpx;
text-align: right;
.btn{
margin-left: 20rpx;
}
}
</style>

@ -0,0 +1,71 @@
<!--
* @Author: ch
* @Date: 2022-04-14 14:19:41
* @LastEditors: ch
* @LastEditTime: 2022-04-14 14:38:30
* @Description: file content
-->
<template>
<UiWhiteBox>
<view class="title">寄件信息</view>
<view class="info">
<view class="info--cell">
<text class="info--cell-label">收货信息</text>
<view class="info--cell-value">
<view>马士兵严选 18911536782</view>
<view>湖南省湖南省湖南省湖南省湖南省</view>
</view>
</view>
<view class="info--cell">
<text class="info--cell-label">物流公司</text>
<view class="info--cell-value">{{data.refundAmount}}</view>
</view>
<view class="info--cell">
<text class="info--cell-label">物流单号</text>
<view class="info--cell-value">{{data.refundNo}}</view>
</view>
<view class="info--cell">
<text class="info--cell-label">备注说明</text>
<view class="info--cell-value">{{data.applyTime}}</view>
</view>
</view>
</UiWhiteBox>
</template>
<script>
import UiWhiteBox from '../../../../../components/UiWhiteBox.vue'
export default {
components: { UiWhiteBox },
props: {
data : {
type : Object,
default : () => ({})
}
}
}
</script>
<style lang="scss" scoped>
.title{
height: 100rpx;
line-height: 100rpx;
padding-left: 30rpx;
border-bottom: 1px solid $color-grey2;
}
.info{
padding: 0 30rpx 10rpx;
&--cell{
margin: 30rpx 0;
display: flex;
justify-content: space-between;
}
&--cell-label{
color: $color-grey4;
font-size: $font-size-sm;
}
&--cell-value{
font-size: $font-size-sm;
color: $color-grey5;
text-align: right;
}
}
</style>

@ -2,7 +2,7 @@
* @Author: ch
* @Date: 2022-03-31 17:53:43
* @LastEditors: ch
* @LastEditTime: 2022-03-31 20:43:19
* @LastEditTime: 2022-04-14 15:01:49
* @Description: file content
-->
<template>
@ -17,7 +17,7 @@ import {DictOrderStatus } from '@/common/dicts/order'
import Enum from "@/common/plugins/enum"
export default {
props : {
orderInfo : {
data : {
type : Object,
default : {}
}
@ -25,55 +25,68 @@ export default {
data(){
return {
ctxData : {
awaitPay : {name:'待付款', tips:'', icon: require('@/static/order/fk.png')},
close : {name:'交易关闭' , tips:'关闭原因', icon: require('@/static/order/qx.png')},
awaitSend : {name:'等待发货', tips:'您的包裹整装待发', icon: require('@/static/order/fh.png')},
finishSend : {name:'已发货', tips:'您的包裹正向您飞来', icon: require('@/static/order/fh.png')},
finishReceiving : {name:'已收货', icon: require('@/static/order/fh.png')},
end : {name:'交易成功', icon: require('@/static/order/cg.png')},
"1" : {
name:'请等待商家处理', tips:'', icon: require('@/static/order/cg.png')},
"2" : {name:'退款关闭' , tips:'', icon: require('@/static/order/qx.png')},
"3" : {name:'请寄回商品,并填写物流信息', tips:'', icon: require('@/static/order/cg.png')},
"4" : {name:'快递已发出,等待商家收货', tips:'您的包裹正在退回的路上', icon: require('@/static/order/cg.png')},
"5" : {name:'快递已收货,等待商家退款', tips:'',icon: require('@/static/order/cg.png')},
"6" : {name:'退款成功', tips: '退款将于7个工作日内原路返回注意查收',icon: require('@/static/order/cg.png')},
"7" : {name:'退款关闭', tips: '', icon: require('@/static/order/qx.png')},
},
ctxCon : {},
secondNum : 0
ctxCon : {
name : '--',
icon: require('@/static/order/cg.png')
}
}
},
mounted(){
},
watch : {
orderInfo(nVal){
this.ctxCon = this.ctxData[this.statusKey];
if(this.statusKey === 'awaitPay'){
let expireTime = (new Date(this.orderInfo.expireTime)).getTime(),
curTime = (new Date(this.orderInfo.serverTime)).getTime(),
second = Math.floor((expireTime - curTime) / 1000);
this.secondNum = second > 0 ? second : 0;
this.timer()
}else if(this.statusKey === 'close'){
this.ctxCon.tips = this.orderInfo.closeReason;
watch:{
data(newData){
if(newData){
this.setCtxCon();
}
}
},
computed:{
// key
statusKey (){
return DictOrderStatus[this.orderInfo.orderStatus].value
}
},
methods:{
/**
* 待付款的计时器
* 根据当前状态显示不同文案
*/
timer(){
if(this.secondNum == 0){
this.$emit('close');
return;
}
this.secondNum--;
let minute = parseInt(this.secondNum / 60);
let second = parseInt(this.secondNum % 60);
this.ctxCon.tips = `剩余${minute > 0 ? `${minute}` : ''} ${second}`;
// console.log(this.ctxCon.tips);
setTimeout(()=>this.timer(),1000)
setCtxCon(){
const {refundStatus, handleExpireTime, returnExpireTime, refundExpireTime, closeReason} = this.data;
this.ctxCon = this.ctxData[refundStatus];
switch(refundStatus){
case 1 :
this.ctxCon.tips = `您的申请已经提交,还剩${this.calcTimer(handleExpireTime)}`;
break;
case 3 :
this.ctxCon.tips = `还剩${this.calcTimer(returnExpireTime)}`;
break;
case 5 :
this.ctxCon.tips = `若商家未及时处理,退款将在${this.calcTimer(refundExpireTime)}后自动退回`;
break;
case 2 :
case 7 :
this.ctxCon.tips = closeReason;
break;
default :
break;
}
},
/**
* 计算距下个节点处理时间
*/
calcTimer (time){
const expireTime = (new Date(time)).getTime();
const curTime = (new Date(this.data.serverTime)).getTime();
// const curTime = (new Date('2022-4-16 15:22:00')).getTime();
const minute = parseInt((expireTime - curTime) / 60000);
const day = parseInt(Math.floor(minute / 1440));
const hour = parseInt(Math.floor((minute - day * 1440) / 60));
const m = parseInt(Math.floor(minute - ((day * 24 + hour) * 60)));
return `${day ? `${day}${hour}${m}` : (hour ? `${hour}${m}` : ( m ? `${m}` : '1分'))}`
}
}
}
@ -81,14 +94,16 @@ export default {
<style lang="scss" scoped>
.status{
padding: 30rpx 60rpx 0;
padding: 48rpx 60rpx 0;
margin-bottom: 48rpx;
min-height: 130rpx;
position: relative;
&--icon{
width: 100rpx;
height: 100rpx;
position: absolute;
right: 60rpx;
top: 10rpx;
top: 51rpx;
}
&--name{
font-size: 36rpx;
@ -97,7 +112,7 @@ export default {
&--desc{
font-size: $font-size-base;
color: $color-grey4;
margin-bottom: 48rpx;
// margin-bottom: 48rpx;
}
}
</style>

@ -0,0 +1,110 @@
<!--
* @Author: ch
* @Date: 2022-04-14 13:44:30
* @LastEditors: ch
* @LastEditTime: 2022-04-14 14:58:49
* @Description: file content
-->
<template>
<view>
<UiWhiteBox>
<view class="title">商家已同意退货申请请尽早退货</view>
</UiWhiteBox>
<UiWhiteBox>
<view class="title">退货说明拒收到付</view>
<view class="content">
<view>未与商家协商一致请勿使用到付或平邮以免商家拒签货物</view>
<view>请填写真实退货物流信息逾期未填写退货申请将关闭</view>
</view>
<view class="footer">
<UiButton size="min">撤销申请</UiButton>
</view>
</UiWhiteBox>
<UiWhiteBox class="box">
<UiCell title="物流公司" ></UiCell>
<UiCell title="物流单号" >
<input class="input" slot="value" />
</UiCell>
<UiCell title="退款金额" :rightIcon="false">
<text class="price" slot="value">36.3</text>
</UiCell>
<view class="cell-title">
<view>
<text>问题描述</text>
<text class="cell-title--min">选填</text>
</view>
<text class="cell-title--min">10/45</text>
</view>
<textarea class="cell-textarea" maxlength="45" placeholder="请输入您申请退款的问题"></textarea>
</UiWhiteBox>
<UiWhiteBox class="box">
<view class="cell-title">
<text>上传凭证</text>
<text class="cell-title--min">0/9</text>
</view>
<u-upload
multiple
:maxCount="9"
:previewFullImage="true"
></u-upload>
</UiWhiteBox>
<UiButton class="submit-btn" size="max" type="gradual">确认提交</UiButton>
</view>
</template>
<script>
import UiButton from '../../../../../components/UiButton.vue'
import UiCell from '../../../../../components/UiCell.vue'
import UiWhiteBox from '../../../../../components/UiWhiteBox.vue'
export default {
components: { UiWhiteBox, UiButton, UiCell },
}
</script>
<style lang="scss" scoped>
.box{
padding: 0 30rpx;
}
.title{
height: 98rpx;
line-height: 98rpx;
padding-left: 30rpx;
border-bottom: 2rpx solid $color-grey2;
color: $color-yellow3;
}
.content{
padding: 30rpx 30rpx 0;
view{
line-height: 34rpx;
color: $color-grey4;
font-size: $font-size-sm;
margin-bottom: 28rpx;
}
}
.footer{
padding: 0 30rpx 30rpx;
text-align: right;
.btn{
margin-left: 20rpx;
}
}
.cell-title{
padding : 30rpx 0;
display: flex;
justify-content: space-between;
&--min{
font-size: $font-size-sm;
color: $color-grey4;
}
}
.cell-textarea{
height: 100rpx;
}
.submit-btn{
position: fixed;
bottom: 30rpx;
left: 30rpx;
z-index:999
}
</style>

@ -2,57 +2,15 @@
* @Author: ch
* @Date: 2022-03-31 14:26:09
* @LastEditors: ch
* @LastEditTime: 2022-04-13 18:34:04
* @LastEditTime: 2022-04-14 15:05:37
* @Description: file content
-->
<template>
<view>
<StatusTips :orderInfo="orderInfo" @close="timerCloseOrder"></StatusTips>
<UiWhiteBox>
<UiGoodsInfo v-for="(item, index) in orderInfo.products" :data="item" :key="index">
<template slot="operation">
<UiButton @click="$Router.push(`/saleAfterApply?type=1&id=${item.orderProductId}`)"></UiButton>
</template>
</UiGoodsInfo>
</UiWhiteBox>
<UiWhiteBox>
<u-cell class="address" title="是的发生的" label="陈先生 190****2342"
:border="false" isLink @click="$Router.push('/addressList')">
<image class="address--icon" slot="icon" src="@/static/order/dw.png" />
</u-cell>
</UiWhiteBox>
<UiWhiteBox class="cellBox">
<view class="cell">
<text class="cell--title">订单编号:</text>
<text class="cell--value">{{orderInfo.orderNo}}</text>
</view>
<view class="cell">
<text class="cell--title">订单时间:</text>
<text class="cell--value">{{orderInfo.submitTime}}</text>
</view>
<view class="cell">
<text class="cell--title">支付方式:</text>
<text class="cell--value">{{orderInfo.payTypeDesc}}</text>
</view>
<view class="cell">
<text class="cell--title">买家留言:</text>
<text class="cell--value">{{orderInfo.userMessage}}</text>
</view>
</UiWhiteBox>
<UiWhiteBox class="cellBox">
<view class="cell">
<text class="cell--title">商品总额:</text>
<text class="cell--value">{{orderInfo.totalAmount}}</text>
</view>
<view class="cell">
<text class="cell--title">运费:</text>
<text class="cell--value">{{orderInfo.shippingAmount}}</text>
</view>
</UiWhiteBox>
<StatusTips :data="orderInfo"></StatusTips>
<AwaitExamine v-if="orderInfo.refundStatus == 1"></AwaitExamine>
<SubmitLogistics v-if="orderInfo.refundStatus == 3"></SubmitLogistics>
<LogisticsInfo v-if="[4,5,6].includes(orderInfo.refundStatus)"></LogisticsInfo>
<GoodsInfo :data="orderInfo"></GoodsInfo>
</view>
</template>
@ -65,8 +23,11 @@ import UiButton from '@/components/UiButton.vue'
import StatusTips from './components/StatusTips.vue'
import UiCell from '@/components/UiCell.vue'
import GoodsInfo from './components/GoodsInfo.vue'
import AwaitExamine from './components/AwaitExamine.vue'
import SubmitLogistics from './components/SubmitLogistics.vue'
import LogisticsInfo from './components/LogisticsInfo.vue'
export default {
components: { UiPageHeader, UiGoodsInfo, UiWhiteBox, UiButton, StatusTips, UiCell, GoodsInfo },
components: { UiPageHeader, UiGoodsInfo, UiWhiteBox, UiButton, StatusTips, UiCell, GoodsInfo, AwaitExamine, SubmitLogistics, LogisticsInfo },
data(){
return {
orderInfo : {
@ -88,14 +49,7 @@ export default {
uni.$u.toast(error.message);
return false;
}
this.orderInfo = {...result, orderStatus : 7};
},
/**
* 超时自动关闭订单
*/
timerCloseOrder(){
this.orderInfo = {...this.orderInfo, orderStatus : 2, closeReason:'超时未支付'};
// this.getOrderInfo();
this.orderInfo = result;
}
}
@ -105,72 +59,7 @@ export default {
<style lang="scss" scoped>
page{
// background: linear-gradient(180deg, #FDF9F5 0%, rgba(254, 253, 252, 0) 50%) $color-grey1;
background: $color-grey1;
padding-bottom: 138rpx;
}
.header{
background: none;
}
.address{
// background: $color-grey0;
&--icon{
width: 28rpx;
height: 34rpx;
margin-right: 30rpx;
}
}
.status{
padding: 30rpx 60rpx 0;
position: relative;
&--icon{
width: 100rpx;
height: 100rpx;
position: absolute;
right: 60rpx;
top: 10rpx;
}
&--name{
font-size: 36rpx;
margin-bottom: 20rpx;
}
&--desc{
font-size: $font-size-base;
color: $color-grey4;
margin-bottom: 48rpx;
}
}
.cellBox{
padding: 30rpx;
}
.cell{
height: 56rpx;
line-height: 56rpx;
display: flex;
justify-content: space-between;
&--value{
font-size: $font-size-sm;
}
&--title{
color: $color-grey4;
font-size: $font-size-sm;
}
}
.footer{
height: 138rpx;
padding: 0 30rpx;
background: $color-grey0;
position: fixed;
bottom: 0;
left: 0;
right: 0;
display: flex;
justify-content: flex-end;
align-items: center;
&--btn{
display: block;
margin: 0 0 0 30rpx;
}
padding-bottom: 120rpx;
}
</style>
Loading…
Cancel
Save