|
@@ -22,13 +22,35 @@
|
|
|
</a-col>
|
|
|
<template v-if="advanced">
|
|
|
<a-col :md="6" :sm="24">
|
|
|
- <a-form-item label="销退单号">
|
|
|
- <a-input id="salesReturn-salesReturnBillNo" v-model.trim="queryParam.salesReturnBillNo" allowClear placeholder="请输入销退单号"/>
|
|
|
+ <a-form-item label="总部销退单号">
|
|
|
+ <a-input id="salesReturn-salesReturnBillNo" v-model.trim="queryParam.salesReturnBillNo" allowClear placeholder="请输入总部销退单号"/>
|
|
|
</a-form-item>
|
|
|
</a-col>
|
|
|
<a-col :md="6" :sm="24">
|
|
|
- <a-form-item label="客户采退单号">
|
|
|
- <a-input id="salesReturn-purchaseReturnBillNo" v-model.trim="queryParam.purchaseReturnBillNo" allowClear placeholder="请输入客户采退单号"/>
|
|
|
+ <a-form-item label="客户采退申请单号">
|
|
|
+ <a-input id="salesReturn-purchaseReturnBillNo" v-model.trim="queryParam.purchaseReturnBillNo" allowClear placeholder="请输入客户采退申请单号"/>
|
|
|
+ </a-form-item>
|
|
|
+ </a-col>
|
|
|
+ <a-col :md="6" :sm="24">
|
|
|
+ <a-form-item label="单据来源">
|
|
|
+ <v-select
|
|
|
+ v-model="queryParam.salesReturnBillSource"
|
|
|
+ ref="salesReturnBillSource"
|
|
|
+ id="salesReturn-salesReturnBillSource"
|
|
|
+ code="SALES_SOURCE"
|
|
|
+ placeholder="请选择单据来源"
|
|
|
+ allowClear></v-select>
|
|
|
+ </a-form-item>
|
|
|
+ </a-col>
|
|
|
+ <a-col :md="6" :sm="24">
|
|
|
+ <a-form-item label="是否同步给客户">
|
|
|
+ <v-select
|
|
|
+ v-model="queryParam.syncToCustomFlag"
|
|
|
+ ref="syncToCustom"
|
|
|
+ id="salesReturn-syncToCustom"
|
|
|
+ code="FLAG"
|
|
|
+ placeholder="请选择是否同步给客户"
|
|
|
+ allowClear></v-select>
|
|
|
</a-form-item>
|
|
|
</a-col>
|
|
|
<a-col :md="6" :sm="24">
|
|
@@ -74,14 +96,6 @@
|
|
|
<div class="table-operator">
|
|
|
<a-button type="primary" class="button-error" v-if="$hasPermissions('B_salesReturnNew')" @click="openModal = true">新增</a-button>
|
|
|
</div>
|
|
|
- <!-- alert -->
|
|
|
- <a-alert type="info" style="margin-bottom: 10px;">
|
|
|
- <div slot="message">
|
|
|
- <span v-if="$hasPermissions('B_isShowPrice')">退货总金额:<strong>{{ countData&&(countData.totalAmount || countData.totalAmount==0) ? countData.totalAmount : '--' }}</strong>元;</span>
|
|
|
- 总单数:<strong>{{ countData&&(countData.totalRecord || countData.totalRecord==0) ? countData.totalRecord : '--' }}</strong>;
|
|
|
- 总数量:<strong>{{ countData&&(countData.totalQty || countData.totalQty==0) ? countData.totalQty : '--' }}</strong>;
|
|
|
- </div>
|
|
|
- </a-alert>
|
|
|
<!-- 列表 -->
|
|
|
<s-table
|
|
|
class="sTable fixPagination"
|
|
@@ -209,17 +223,14 @@ export default {
|
|
|
salesReturnBillNo: undefined, // 总部销退单号
|
|
|
purchaseReturnBillNo: '',
|
|
|
billStatus: undefined, // 业务状态
|
|
|
- // financialStatus: undefined, // 财务状态
|
|
|
subareaSn: undefined,
|
|
|
- shippingAddrProvinceSn: undefined
|
|
|
+ shippingAddrProvinceSn: undefined,
|
|
|
+ salesReturnBillSource: undefined
|
|
|
},
|
|
|
- countData: null, // 统计数据
|
|
|
// 加载数据方法 必须为 Promise 对象
|
|
|
loadData: parameter => {
|
|
|
this.disabled = true
|
|
|
this.spinning = true
|
|
|
- // 查询总计
|
|
|
- this.getQueryCount(Object.assign(parameter, this.queryParam))
|
|
|
return salesReturnList(Object.assign(parameter, this.queryParam)).then(res => {
|
|
|
let data
|
|
|
if (res.status == 200) {
|
|
@@ -243,24 +254,22 @@ export default {
|
|
|
computed: {
|
|
|
columns () {
|
|
|
const arr = [
|
|
|
- { title: '创建时间', dataIndex: 'createDate', width: '7%', align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
+ { title: '编号', dataIndex: 'no', width: '4%', align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
+ { title: '创建时间', dataIndex: 'createDate', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
{ title: '单据来源', dataIndex: 'salesReturnBillSourceDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
- { title: '客户采退单号', dataIndex: 'purchaseReturnBillNo', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
+ { title: '是否同步给客户', dataIndex: 'asyncFlag', width: '7%', align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
+ { title: '客户采退申请单号', dataIndex: 'purchaseReturnBillNo', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
{ title: '总部销退单号', scopedSlots: { customRender: 'salesReturnBillNo' }, width: '10%', align: 'center' },
|
|
|
- { title: '退货客户', dataIndex: 'buyerName', width: '12%', align: 'left', customRender: function (text) { return text || '--' }, ellipsis: true },
|
|
|
- { title: '退货数量', dataIndex: 'totalQty', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
- { title: '坏件数量', dataIndex: 'totalBadQty', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
- { title: '返库数量', dataIndex: 'totalBackStockQty', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
- // { title: '退款金额', dataIndex: 'totalAmount', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
- { title: '是否抓单', dataIndex: 'grabFlag', width: '6%', align: 'center', customRender: function (text) { return ['否', '是'][text] } },
|
|
|
- { title: '审核时间', dataIndex: 'auditTime', width: '7%', align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
+ { title: '客户名称', dataIndex: 'buyerName', width: '10%', align: 'left', customRender: function (text) { return text || '--' }, ellipsis: true },
|
|
|
+ { title: '申请退货数量', dataIndex: 'totalQty', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
+ { title: '仓库实收数量', dataIndex: 'totalBadQty', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
+ { title: '坏件数量', dataIndex: 'totalBadQty', width: '5%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
+ { title: '良品数量', dataIndex: 'totalBackStockQty', width: '5%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
+ { title: '返库数量', dataIndex: 'totalBackStockQty', width: '5%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
+ { title: '审核时间', dataIndex: 'auditTime', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
{ title: '业务状态', dataIndex: 'billStatusDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
- // { title: '财务状态', dataIndex: 'financialStatusDictValue', scopedSlots: { customRender: 'financialStatus' }, width: 110, align: 'center' },
|
|
|
- { title: '操作', scopedSlots: { customRender: 'action' }, width: '12%', align: 'center' }
|
|
|
+ { title: '操作', scopedSlots: { customRender: 'action' }, width: '10%', align: 'center' }
|
|
|
]
|
|
|
- if (this.$hasPermissions('B_isShowPrice')) { // 售价权限
|
|
|
- arr.splice(9, 0, { title: '退款金额', dataIndex: 'totalAmount', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } })
|
|
|
- }
|
|
|
return arr
|
|
|
}
|
|
|
},
|
|
@@ -278,12 +287,6 @@ export default {
|
|
|
custChange (val) {
|
|
|
this.queryParam.buyerSn = val.key
|
|
|
},
|
|
|
- // 列表统计
|
|
|
- getQueryCount (params) {
|
|
|
- salesReturnQueryCount(params).then(res => {
|
|
|
- this.countData = res.data || null
|
|
|
- })
|
|
|
- },
|
|
|
// 编辑
|
|
|
handleEdit (row) {
|
|
|
this.$router.push({ name: row.grabFlag == 1 ? 'salesReturnGrabEdit' : 'salesReturnEdit', params: { sn: row.salesReturnBillSn, buyerSn: row.buyerSn } })
|
|
@@ -352,6 +355,7 @@ export default {
|
|
|
this.queryParam.purchaseReturnBillNo = ''
|
|
|
this.queryParam.billStatus = undefined
|
|
|
this.queryParam.subareaSn = undefined
|
|
|
+ this.queryParam.salesReturnBillSource = undefined
|
|
|
this.queryParam.shippingAddrProvinceSn = undefined
|
|
|
this.$refs.table.refresh(true)
|
|
|
},
|