|
@@ -2,59 +2,60 @@
|
|
<div class="app-container">
|
|
<div class="app-container">
|
|
<div id="printBox">
|
|
<div id="printBox">
|
|
<el-card ref="print" class="box-card" style="margin: 0 auto;">
|
|
<el-card ref="print" class="box-card" style="margin: 0 auto;">
|
|
- <div v-for="(repact,index) in repacts" :key="index" class="refund-item">
|
|
|
|
|
|
+ <div class="refund-item">
|
|
<el-row :gutter="24" class="box-row">
|
|
<el-row :gutter="24" class="box-row">
|
|
- <el-col :span="6"><b>订单编号(ID):</b> {{ repact.orderNo }}({{ repact.orderId }})</el-col>
|
|
|
|
- <el-col :span="4"><b>下单时间:</b> {{ repact.applyTime }}</el-col>
|
|
|
|
- <el-col :span="4"><b>订单金额:</b> {{ repact.payableAmount }}</el-col>
|
|
|
|
- <el-col :span="10">
|
|
|
|
- <b>所有子订单:</b>
|
|
|
|
- <span v-for="child in repact.childOrderId" :key="child">
|
|
|
|
- 【{{ child }}】
|
|
|
|
- </span>
|
|
|
|
- </el-col>
|
|
|
|
- </el-row>
|
|
|
|
|
|
+ <el-col :span="5"><b>订单编号(ID):</b> {{ shopOrder.orderNo }}({{ shopOrder.orderId }})</el-col>
|
|
|
|
+ <el-col :span="5"><b>下单时间:</b> {{ shopOrder.orderTime }}</el-col>
|
|
|
|
+ <el-col :span="4">
|
|
|
|
+ <b>订单金额:</b>
|
|
|
|
+ <span class="el-span-danger">{{ shopOrder.payTotalFee | amountfilters }}</span>
|
|
|
|
+ </el-col></el-row>
|
|
<el-row :gutter="24" class="box-row">
|
|
<el-row :gutter="24" class="box-row">
|
|
- <el-col :span="6"><b>机构名称:</b> {{ repact.clubName }}</el-col>
|
|
|
|
- <el-col :span="4"><b>机构运费:</b> <span>{{ repact.postageInfo }}</span></el-col>
|
|
|
|
- <el-col :span="4"><b>收款状态:</b> {{ repact.status | statusFilter }}</el-col>
|
|
|
|
- <el-col :span="10"><b>收款金额:</b> {{ repact.payableAmount }}</el-col>
|
|
|
|
- </el-row>
|
|
|
|
- <el-row :gutter="24" class="box-row">
|
|
|
|
- <el-col :span="6"><b>子订单编号(ID)</b> {{ repact.orderNo }}({{ repact.orderId }})</el-col>
|
|
|
|
- <el-col :span="4"><b>子订单佣金:</b> 5000.00</el-col>
|
|
|
|
- <el-col :span="4"><b>商品费:</b> {{ repact.payableAmount }}</el-col>
|
|
|
|
- <el-col :span="10"><b>付款状态:</b> {{ repact.status | statusFilter }}</el-col>
|
|
|
|
- </el-row>
|
|
|
|
|
|
+ <el-col :span="5"><b>机构名称:</b> {{ shopOrder.clubName }}</el-col>
|
|
|
|
+ <el-col :span="5"><b>机构运费:</b> <span>{{ shopOrder.postageInfo }}</span></el-col>
|
|
|
|
+ <el-col :span="4">
|
|
|
|
+ <b>收款状态:</b>
|
|
|
|
+ <el-tag v-if="shopOrder.receiptStatus*1===1" type="danger" size="small">待收款</el-tag>
|
|
|
|
+ <el-tag v-if="shopOrder.receiptStatus*1===2" type="warning" size="small">部分收款</el-tag>
|
|
|
|
+ <el-tag v-if="shopOrder.receiptStatus*1===3" type="success" size="small">已收款</el-tag>
|
|
|
|
+ </el-col>
|
|
|
|
+ <el-col :span="10">
|
|
|
|
+ <b>收款金额:</b>
|
|
|
|
+ <span class="el-span-danger">{{ shopOrder.payableAmount | amountfilters }}</span>
|
|
|
|
+ </el-col></el-row>
|
|
<el-row :gutter="24" class="box-row">
|
|
<el-row :gutter="24" class="box-row">
|
|
- <el-col :span="6"><b>供应商名称:</b> {{ repact.shopName }}</el-col>
|
|
|
|
- <el-col :span="4"><b>供应商运费:</b> 15.00</el-col>
|
|
|
|
|
|
+ <el-col :span="5"><b>子订单编号(ID)</b> {{ shopOrder.shopOrderNo }}({{ shopOrder.shopOrderId }})</el-col>
|
|
|
|
+ <el-col :span="5"><b>商品费:</b> {{ shopOrder.payableAmount | amountfilters }}</el-col>
|
|
|
|
+ <el-col :span="10">
|
|
|
|
+ <b>付款状态:</b>
|
|
|
|
+ <el-tag v-if="shopOrder.payStatus*1===1" type="danger" size="small">待付款</el-tag>
|
|
|
|
+ <el-tag v-if="shopOrder.payStatus*1===2" type="warning" size="small">部分付款</el-tag>
|
|
|
|
+ <el-tag v-if="shopOrder.payStatus*1===3" type="success" size="small">已付款</el-tag>
|
|
|
|
+ </el-col>
|
|
</el-row>
|
|
</el-row>
|
|
<el-row :gutter="24" class="box-row">
|
|
<el-row :gutter="24" class="box-row">
|
|
- <el-col :span="24">
|
|
|
|
|
|
+ <el-col :span="5"><b>供应商名称:</b> {{ shopOrder.shopName }}</el-col>
|
|
|
|
+ <el-col :span="5"><b>供应商运费:</b> {{ shopOrder.shopPostFee | amountfilters }}</el-col>
|
|
|
|
+ <el-col :span="14">
|
|
<b>付供应商:</b>
|
|
<b>付供应商:</b>
|
|
- <b style="margin-left: 10px;">应付采美:</b>10000.00
|
|
|
|
- <b style="margin-left: 10px;">已付采美:</b>10000.00
|
|
|
|
- <b style="margin-left: 10px;">待付采美:</b>0.00
|
|
|
|
- <b style="margin-left: 10px;">应付供应商:</b>10000.00
|
|
|
|
- <b style="margin-left: 10px;">已付供应商:</b>10000.00
|
|
|
|
- <b style="margin-left: 10px;">待付供应商:</b>0.00
|
|
|
|
|
|
+ <b style="margin-left: 10px;">已付采美:</b>¥{{ shopOrder.payTotalFee | amountfilters }}
|
|
|
|
+ <b style="margin-left: 10px;">已付供应商:</b>¥{{ shopOrder.payTotalFee | amountfilters }}
|
|
</el-col>
|
|
</el-col>
|
|
</el-row>
|
|
</el-row>
|
|
<el-row :gutter="24" class="box-row">
|
|
<el-row :gutter="24" class="box-row">
|
|
- <el-table :data="repact.products" border fit highlight-current-row :header-cell-style="{background:'#eef1f6',color:'#606266'}">
|
|
|
|
- <el-table-column label="商品名" align="center" prop="productName" />
|
|
|
|
|
|
+ <el-table :data="shopOrder.newOrderProducts" border fit highlight-current-row :header-cell-style="{background:'#eef1f6',color:'#606266'}">
|
|
|
|
+ <el-table-column label="商品名" align="center" prop="name" />
|
|
<el-table-column label="规格" align="center" prop="unit" />
|
|
<el-table-column label="规格" align="center" prop="unit" />
|
|
<el-table-column label="数量" align="center" prop="num" />
|
|
<el-table-column label="数量" align="center" prop="num" />
|
|
- <el-table-column label="退货" align="center" prop="returnNum" />
|
|
|
|
|
|
+ <el-table-column label="退货" align="center" prop="returnedNum" />
|
|
<el-table-column label="单价" align="center" prop="price" />
|
|
<el-table-column label="单价" align="center" prop="price" />
|
|
- <el-table-column label="总价" align="center" prop="totalPrice" />
|
|
|
|
|
|
+ <el-table-column label="总价" align="center" prop="totalAmount" />
|
|
</el-table>
|
|
</el-table>
|
|
</el-row>
|
|
</el-row>
|
|
</div>
|
|
</div>
|
|
<div class="refund-item">
|
|
<div class="refund-item">
|
|
<h1 class="refund-item-title">付款记录</h1>
|
|
<h1 class="refund-item-title">付款记录</h1>
|
|
- <el-table :data="products" border fit highlight-current-row :header-cell-style="{background:'#e9f3f7',color:'#606266'}">
|
|
|
|
|
|
+ <el-table :data="pays" border fit highlight-current-row :header-cell-style="{background:'#e9f3f7',color:'#606266'}">
|
|
<el-table-column label="序号" align="center" prop="productName" />
|
|
<el-table-column label="序号" align="center" prop="productName" />
|
|
<el-table-column label="付款单ID" align="center" prop="unit" />
|
|
<el-table-column label="付款单ID" align="center" prop="unit" />
|
|
<el-table-column label="付款时间" align="center" prop="num" />
|
|
<el-table-column label="付款时间" align="center" prop="num" />
|
|
@@ -64,7 +65,7 @@
|
|
</div>
|
|
</div>
|
|
<div class="refund-item">
|
|
<div class="refund-item">
|
|
<h1 class="refund-item-title">退款记录</h1>
|
|
<h1 class="refund-item-title">退款记录</h1>
|
|
- <el-table :data="products" border fit highlight-current-row :header-cell-style="{background:'#e9f3f7',color:'#606266'}">
|
|
|
|
|
|
+ <el-table :data="returns" border fit highlight-current-row :header-cell-style="{background:'#e9f3f7',color:'#606266'}">
|
|
<el-table-column label="序号" align="center" prop="productName" />
|
|
<el-table-column label="序号" align="center" prop="productName" />
|
|
<el-table-column label="退款记录ID" align="center" prop="unit" />
|
|
<el-table-column label="退款记录ID" align="center" prop="unit" />
|
|
<el-table-column label="退款时间" align="center" prop="num" />
|
|
<el-table-column label="退款时间" align="center" prop="num" />
|
|
@@ -78,7 +79,7 @@
|
|
</template>
|
|
</template>
|
|
|
|
|
|
<script>
|
|
<script>
|
|
-import { getDetail, getRemarks } from '@/api/order'
|
|
|
|
|
|
+import { organizeReturnAndPay } from '@/api/finance'
|
|
export default {
|
|
export default {
|
|
name: 'PaymentRecord',
|
|
name: 'PaymentRecord',
|
|
filters: {
|
|
filters: {
|
|
@@ -93,223 +94,35 @@ export default {
|
|
},
|
|
},
|
|
data() {
|
|
data() {
|
|
return {
|
|
return {
|
|
- printObj: {
|
|
|
|
- id: 'printBox', // 局部打印的<div> Id
|
|
|
|
- popTitle: '', // 打印配置页上方标题
|
|
|
|
- extraHead: '', // 最上方的头部文字,附加在head标签上的额外标签,使用逗号分隔
|
|
|
|
- preview: '', // 是否启动预览模式,默认是false(开启预览模式,可以先预览后打印)
|
|
|
|
- previewTitle: '', // 打印预览的标题(开启预览模式后出现),
|
|
|
|
- previewPrintBtnLabel: '', // 打印预览的标题的下方按钮文本,点击可进入打印(开启预览模式后出现)
|
|
|
|
- zIndex: '', // 预览的窗口的z-index,默认是 20002(此值要高一些,这涉及到预览模式是否显示在最上面)
|
|
|
|
- previewBeforeOpenCallback() {}, // 预览窗口打开之前的callback(开启预览模式调用)
|
|
|
|
- previewOpenCallback() {}, // 预览窗口打开之后的callback(开启预览模式调用)
|
|
|
|
- beforeEntryIframe() {
|
|
|
|
- const cells = document.querySelectorAll('.cell')
|
|
|
|
- const tableNode = document.querySelectorAll('.el-table__header,.el-table__body')
|
|
|
|
- // el-table 打印不全的问题
|
|
|
|
- for (let j = 0; j < tableNode.length; j++) {
|
|
|
|
- const tableItem = tableNode[j]
|
|
|
|
- tableItem.style.width = '100%'
|
|
|
|
- const child = tableItem.childNodes
|
|
|
|
- for (let i = 0; i < child.length; i++) {
|
|
|
|
- const element = child[i]
|
|
|
|
- if (element.localName === 'colgroup') {
|
|
|
|
- element.innerHTML = ''
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
- // el-table 格子里面打印超过格子的问题
|
|
|
|
- for (let i = 0; i < cells.length; i++) {
|
|
|
|
- const cell = cells[i]
|
|
|
|
- cell.style.width = '100%'
|
|
|
|
- cell.removeAttribute('style')
|
|
|
|
- }
|
|
|
|
- },
|
|
|
|
- openCallback() {
|
|
|
|
-
|
|
|
|
- }, // 调用打印之后的回调事件
|
|
|
|
- closeCallback() {}, // 关闭打印的回调事件(无法确定点击的是确认还是取消)
|
|
|
|
- url: '',
|
|
|
|
- standard: '',
|
|
|
|
- extraCss: '',
|
|
|
|
- loading: false
|
|
|
|
- },
|
|
|
|
- payRepacts: {
|
|
|
|
- name: '卢海珠',
|
|
|
|
- account: '6214 8328 2826 4957 ',
|
|
|
|
- accountBank: '中国建设银行',
|
|
|
|
- accountType: '公账'
|
|
|
|
- },
|
|
|
|
- repacts: [
|
|
|
|
- {
|
|
|
|
- id: 7580,
|
|
|
|
- name: '卢海珠',
|
|
|
|
- account: '6214 8328 2826 4957 ',
|
|
|
|
- accountBank: '中国建设银行',
|
|
|
|
- accountType: '公账',
|
|
|
|
- type: '子订单付款',
|
|
|
|
- shopName: '采美信息技术有限公司',
|
|
|
|
- payableAmount: '20000.00',
|
|
|
|
- shopOrderNo: 'P1682650952091471001',
|
|
|
|
- shopOrderId: '19747',
|
|
|
|
- orderNo: 'P16265095220221471',
|
|
|
|
- orderId: '18179',
|
|
|
|
- clubName: '广州白云区松洲蒂亚美容院',
|
|
|
|
- applyMan: '路海珠',
|
|
|
|
- applyTime: '2020-01-01:20:30:56',
|
|
|
|
- verifyMan: '李昕',
|
|
|
|
- verifyTime: '2020-01-01:20:30:56',
|
|
|
|
- status: 0,
|
|
|
|
- totalProduct: '3000.00',
|
|
|
|
- payShopTotal: '3000.00',
|
|
|
|
- childOrderId: ['P16265095220221471', 'P16265095220221471', 'P16265095220221471'],
|
|
|
|
- products: [
|
|
|
|
- {
|
|
|
|
- productName: '阶雪山之恋保滋润面霜吖',
|
|
|
|
- unit: '50ml',
|
|
|
|
- num: 3,
|
|
|
|
- returnNum: 0,
|
|
|
|
- price: '2000.00',
|
|
|
|
- totalPrice: '6000.00',
|
|
|
|
- costPrice: '1000.00',
|
|
|
|
- totalCostPrice: '3000.00'
|
|
|
|
- },
|
|
|
|
- {
|
|
|
|
- productName: '阶雪山之恋保滋润面霜吖',
|
|
|
|
- unit: '50ml',
|
|
|
|
- num: 3,
|
|
|
|
- returnNum: 0,
|
|
|
|
- price: '2000.00',
|
|
|
|
- totalPrice: '6000.00',
|
|
|
|
- costPrice: '1000.00',
|
|
|
|
- totalCostPrice: '3000.00'
|
|
|
|
- },
|
|
|
|
- {
|
|
|
|
- productName: '阶雪山之恋保滋润面霜吖',
|
|
|
|
- unit: '50ml',
|
|
|
|
- num: 3,
|
|
|
|
- returnNum: 0,
|
|
|
|
- price: '2000.00',
|
|
|
|
- totalPrice: '6000.00',
|
|
|
|
- costPrice: '1000.00',
|
|
|
|
- totalCostPrice: '3000.00'
|
|
|
|
- },
|
|
|
|
- {
|
|
|
|
- productName: '阶雪山之恋保滋润面霜吖',
|
|
|
|
- unit: '50ml',
|
|
|
|
- num: 3,
|
|
|
|
- returnNum: 0,
|
|
|
|
- price: '2000.00',
|
|
|
|
- totalPrice: '6000.00',
|
|
|
|
- costPrice: '1000.00',
|
|
|
|
- totalCostPrice: '3000.00'
|
|
|
|
- }
|
|
|
|
- ]
|
|
|
|
- }
|
|
|
|
- ],
|
|
|
|
- products: [
|
|
|
|
- {
|
|
|
|
- productName: '阶雪山之恋保滋润面霜吖',
|
|
|
|
- unit: '50ml',
|
|
|
|
- num: 3,
|
|
|
|
- returnNum: 0,
|
|
|
|
- price: '2000.00',
|
|
|
|
- totalPrice: '6000.00',
|
|
|
|
- costPrice: '1000.00',
|
|
|
|
- totalCostPrice: '3000.00'
|
|
|
|
- },
|
|
|
|
- {
|
|
|
|
- productName: '阶雪山之恋保滋润面霜吖',
|
|
|
|
- unit: '50ml',
|
|
|
|
- num: 3,
|
|
|
|
- returnNum: 0,
|
|
|
|
- price: '2000.00',
|
|
|
|
- totalPrice: '6000.00',
|
|
|
|
- costPrice: '1000.00',
|
|
|
|
- totalCostPrice: '3000.00'
|
|
|
|
- },
|
|
|
|
- {
|
|
|
|
- productName: '阶雪山之恋保滋润面霜吖',
|
|
|
|
- unit: '50ml',
|
|
|
|
- num: 3,
|
|
|
|
- returnNum: 0,
|
|
|
|
- price: '2000.00',
|
|
|
|
- totalPrice: '6000.00',
|
|
|
|
- costPrice: '1000.00',
|
|
|
|
- totalCostPrice: '3000.00'
|
|
|
|
- },
|
|
|
|
- {
|
|
|
|
- productName: '阶雪山之恋保滋润面霜吖',
|
|
|
|
- unit: '50ml',
|
|
|
|
- num: 3,
|
|
|
|
- returnNum: 0,
|
|
|
|
- price: '2000.00',
|
|
|
|
- totalPrice: '6000.00',
|
|
|
|
- costPrice: '1000.00',
|
|
|
|
- totalCostPrice: '3000.00'
|
|
|
|
- }
|
|
|
|
- ],
|
|
|
|
- activeIndex: '2',
|
|
|
|
- order: null,
|
|
|
|
- receiptAmount: 0,
|
|
|
|
- returnValue: 0,
|
|
|
|
- returnedPurchaseFee: 0,
|
|
|
|
- bpClauses: null,
|
|
|
|
- dialogRemarkList: [],
|
|
|
|
- dialogRemarksVisible: false,
|
|
|
|
- dialogRemarksOrderId: 0,
|
|
|
|
- statusObj: {
|
|
|
|
- '0': '待确认',
|
|
|
|
- '4': '交易完成',
|
|
|
|
- '5': '订单完成',
|
|
|
|
- '6': '已关闭',
|
|
|
|
- '7': '交易全退',
|
|
|
|
- '11': '待收款、待发货',
|
|
|
|
- '12': '待收款、部分发货',
|
|
|
|
- '13': '待收款、全部发货',
|
|
|
|
- '21': '部分收款、待发货',
|
|
|
|
- '22': '部分收款、部分发货',
|
|
|
|
- '23': '部分收款、全部发货',
|
|
|
|
- '31': '全部收款、待发货',
|
|
|
|
- '32': '全部收款、部分发货',
|
|
|
|
- '33': '全部收款、全部发货'
|
|
|
|
- }
|
|
|
|
|
|
+ shopOrder: {},
|
|
|
|
+ pays: [],
|
|
|
|
+ returns: []
|
|
}
|
|
}
|
|
},
|
|
},
|
|
computed: {
|
|
computed: {
|
|
- orderID: function() {
|
|
|
|
- return this.$route.query.orderID * 1
|
|
|
|
|
|
+ shopOrderId: function() {
|
|
|
|
+ return this.$route.query.shopOrderId * 1
|
|
}
|
|
}
|
|
},
|
|
},
|
|
created() {
|
|
created() {
|
|
- // this.fetchData()
|
|
|
|
|
|
+ this.organizeReturnAndPay()
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
- fetchData() {
|
|
|
|
- this.listLoading = true
|
|
|
|
- getDetail({ id: this.orderID }).then(response => {
|
|
|
|
- this.order = response.data.order
|
|
|
|
- this.bpClauses = response.data.bpClauses
|
|
|
|
- this.receiptAmount = response.data.receiptAmount
|
|
|
|
- this.returnValue = response.data.returnValue
|
|
|
|
- this.returnedPurchaseFee = response.data.returnedPurchaseFee
|
|
|
|
- this.listLoading = false
|
|
|
|
- }).catch(() => {
|
|
|
|
- this.listLoading = false
|
|
|
|
- })
|
|
|
|
- },
|
|
|
|
- RemarksOrder: function(id) {
|
|
|
|
- getRemarks({ orderID: id }).then(response => {
|
|
|
|
- this.dialogRemarkList = response.data
|
|
|
|
- })
|
|
|
|
- this.dialogRemarksOrderId = id
|
|
|
|
- this.dialogRemarksVisible = true
|
|
|
|
|
|
+ async organizeReturnAndPay() {
|
|
|
|
+ try {
|
|
|
|
+ const res = await organizeReturnAndPay(this.shopOrderId)
|
|
|
|
+ this.shopOrder = res.data.shopOrder
|
|
|
|
+ this.pays = res.data.pays
|
|
|
|
+ this.returns = res.data.returns
|
|
|
|
+ } catch (error) {
|
|
|
|
+ console.log('error', error)
|
|
|
|
+ }
|
|
},
|
|
},
|
|
backToList() {
|
|
backToList() {
|
|
this.$store.dispatch('tagsView/delView', this.$route).then(() => {
|
|
this.$store.dispatch('tagsView/delView', this.$route).then(() => {
|
|
this.$nextTick(() => {
|
|
this.$nextTick(() => {
|
|
this.$router.replace({
|
|
this.$router.replace({
|
|
- path: '/finance/list'
|
|
|
|
|
|
+ path: '/finance/paysettle-list'
|
|
})
|
|
})
|
|
})
|
|
})
|
|
})
|
|
})
|