|
@@ -0,0 +1,132 @@
|
|
|
+<template>
|
|
|
+ <div class="app-container">
|
|
|
+
|
|
|
+ <el-menu :default-active="activeIndex" class="el-menu-demo" mode="horizontal">
|
|
|
+ <el-menu-item index="1"><router-link to="/order/list">订单列表</router-link></el-menu-item>
|
|
|
+ <el-menu-item index="2">收退款记录</el-menu-item>
|
|
|
+ </el-menu>
|
|
|
+
|
|
|
+ <el-card v-if="order" class="box-card">
|
|
|
+ <el-row :gutter="24" class="box-row">
|
|
|
+ <el-col :span="6"><b>订单编号(ID):</b> {{ order.orderNo + '(' + order.orderID + ')' }}</el-col>
|
|
|
+ <el-col :span="6"><b>下单时间:</b> {{ order.orderTime | parseTime('{y}-{m}-{d} {h}:{i}') }}</el-col>
|
|
|
+ </el-row>
|
|
|
+ <el-row :gutter="24" class="box-row">
|
|
|
+ <el-col :span="6"><b>订单状态:</b>
|
|
|
+ <template v-if="['11','12','13','21','22','23','31','32','33'].indexOf(order.status)>=0">
|
|
|
+ <el-tag type="success" size="small">{{ '交易中('+statusObj[order.status]+')' }}</el-tag>
|
|
|
+ </template>
|
|
|
+ <template v-else>
|
|
|
+ <el-tag :type="row.status*1===6?'info':''" size="small">{{ statusObj[order.status] }}</el-tag>
|
|
|
+ </template>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="6"><b>收款状态:</b>
|
|
|
+ <el-tag v-if="order.receiptStatus*1===1" type="danger" size="small">待收款</el-tag>
|
|
|
+ <el-tag v-if="order.receiptStatus*1===2" type="warning" size="small">部分收款</el-tag>
|
|
|
+ <el-tag v-if="order.receiptStatus*1===3" type="success" size="small">已收款</el-tag>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="6"><b>退款状态:</b>
|
|
|
+ <el-tag v-if="order.refundType*1===1" type="warning" size="small">部分退</el-tag>
|
|
|
+ <el-tag v-else-if="order.refundType*1===2" type="danger" size="small">全部退</el-tag>
|
|
|
+ <el-tag v-else type="info" size="small">无退款</el-tag>
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
+
|
|
|
+ <el-row v-if="order.bpOrderUserinfo" :gutter="24" class="box-row">
|
|
|
+ <el-col v-if="order.bpOrderUserinfo" :span="6"><b>买家:</b> {{ order.bpOrderUserinfo.name }}</el-col>
|
|
|
+ <el-col :span="6"><b>收货人:</b> {{ order.bpOrderUserinfo.shouHuoRen }}</el-col>
|
|
|
+ <el-col :span="6"><b>手机:</b> {{ order.bpOrderUserinfo.mobile }}</el-col>
|
|
|
+ <el-col :span="12"><b>地址:</b> {{ order.bpOrderUserinfo.province +' '+ order.bpOrderUserinfo.city +' '+ order.bpOrderUserinfo.town +' '+ order.bpOrderUserinfo.address }}</el-col>
|
|
|
+ </el-row>
|
|
|
+
|
|
|
+ </el-card>
|
|
|
+
|
|
|
+ </div>
|
|
|
+</template>
|
|
|
+
|
|
|
+<script>
|
|
|
+import { getRefundRecord } from '@/api/order'
|
|
|
+export default {
|
|
|
+ data() {
|
|
|
+ return {
|
|
|
+ activeIndex: '2',
|
|
|
+ bpClauses: [],
|
|
|
+ order: null,
|
|
|
+ refundList: [],
|
|
|
+ statusObj: {
|
|
|
+ '0': '待确认',
|
|
|
+ '4': '交易完成',
|
|
|
+ '5': '订单完成',
|
|
|
+ '6': '已关闭',
|
|
|
+ '7': '交易全退',
|
|
|
+ '11': '待收待发',
|
|
|
+ '12': '待收部发',
|
|
|
+ '13': '待收全发',
|
|
|
+ '21': '部收待发',
|
|
|
+ '22': '部收部发',
|
|
|
+ '23': '部收全发',
|
|
|
+ '31': '已收待发',
|
|
|
+ '32': '已收部发',
|
|
|
+ '33': '已收全发'
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
+ computed: {
|
|
|
+ orderID: function() {
|
|
|
+ return window.location.href.split('/').reverse()[0] * 1
|
|
|
+ }
|
|
|
+ },
|
|
|
+ created() {
|
|
|
+ this.fetchData()
|
|
|
+ },
|
|
|
+ methods: {
|
|
|
+ fetchData() {
|
|
|
+ this.listLoading = true
|
|
|
+ getRefundRecord({ orderID: this.orderID }).then(response => {
|
|
|
+ this.order = response.data.order
|
|
|
+ this.bpClauses = response.data.bpClauses
|
|
|
+ this.refundList = response.data.cmReturnedPurchaseList
|
|
|
+ this.listLoading = false
|
|
|
+ }).catch(() => {
|
|
|
+ this.listLoading = false
|
|
|
+ })
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+</script>
|
|
|
+
|
|
|
+<style scoped>
|
|
|
+ h1{
|
|
|
+ color: #409EFF;
|
|
|
+ font-size: 24px;
|
|
|
+ text-align: center;
|
|
|
+ }
|
|
|
+ h3{
|
|
|
+ color: #409EFF;
|
|
|
+ font-size: 16px;
|
|
|
+ margin: 0;
|
|
|
+ }
|
|
|
+ .box-card{
|
|
|
+ margin-top: 20px;
|
|
|
+ font-size: 14px;
|
|
|
+ }
|
|
|
+ .box-row{
|
|
|
+ padding: 10px 0;
|
|
|
+ }
|
|
|
+ .order-item{
|
|
|
+ border-bottom: 1px solid #DCDFE6;
|
|
|
+ background:#F2F6FC;
|
|
|
+ margin-top: 20px;
|
|
|
+ padding: 5px 15px 0;
|
|
|
+ border-radius: 5px;
|
|
|
+ }
|
|
|
+ .product-row{
|
|
|
+ padding: 10px 0;
|
|
|
+ background: #EBEEF5;
|
|
|
+ border-top: 1px dashed #DCDFE6;
|
|
|
+ }
|
|
|
+ .op-item{
|
|
|
+ padding: 5px 0;
|
|
|
+ }
|
|
|
+</style>
|
|
|
+
|