|
@@ -102,11 +102,11 @@
|
|
|
<s-table
|
|
|
class="sTable"
|
|
|
ref="table"
|
|
|
- size="default"
|
|
|
+ size="small"
|
|
|
:rowKey="(record) => record.id"
|
|
|
:columns="columns"
|
|
|
:data="loadData"
|
|
|
- :scroll="{ x: 2640, y:tableHeight }"
|
|
|
+ :scroll="{ x: 1700, y: tableHeight }"
|
|
|
bordered>
|
|
|
<!-- 销售单号 -->
|
|
|
<template slot="salesBillNo" slot-scope="text, record">
|
|
@@ -205,7 +205,6 @@ export default {
|
|
|
data () {
|
|
|
return {
|
|
|
spinning: false,
|
|
|
- tableHeight: 0,
|
|
|
advanced: false, // 高级搜索 展开/关闭
|
|
|
disabled: false, // 查询、重置按钮是否可操作
|
|
|
openModal: false, // 选择客户弹框是否显示
|
|
@@ -240,34 +239,31 @@ export default {
|
|
|
},
|
|
|
// 表头
|
|
|
columns: [
|
|
|
- { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
|
|
|
- { title: '创建时间', dataIndex: 'createDate', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
- { title: '单据来源', dataIndex: 'salesBillSourceDictValue', width: 120, align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
- { title: '销售单号', scopedSlots: { customRender: 'salesBillNo' }, width: 210, align: 'center' },
|
|
|
- { title: '采购单号', dataIndex: 'purchaseBillNo', width: 210, align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
+ { title: '序号', dataIndex: 'no', width: 60, align: 'center' },
|
|
|
+ { title: '创建时间', dataIndex: 'createDate', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
+ { title: '单据来源', dataIndex: 'salesBillSourceDictValue', width: 80, align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
+ { title: '销售单号', scopedSlots: { customRender: 'salesBillNo' }, width: 120, align: 'center' },
|
|
|
+ { title: '采购单号', dataIndex: 'purchaseBillNo', width: 120, align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
{ title: '客户名称', dataIndex: 'buyerName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
|
|
|
- { title: '总数量', dataIndex: 'totalQty', scopedSlots: { customRender: 'totalQty' }, width: 100, align: 'center' },
|
|
|
- { title: '总售价', dataIndex: 'totalAmount', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? ('¥' + text) : '--') } },
|
|
|
- { title: '已下推数量', dataIndex: 'totalPushedQty', width: 120, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
- { title: '已发货数量', dataIndex: 'totalDispatchQty', width: 120, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
- { title: '已取消数量', dataIndex: 'totalCancelQty', width: 120, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
- { title: '待下推数量', dataIndex: 'totalUnpushedQty', width: 120, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
- { title: '收款方式', dataIndex: 'settleStyleSnDictValue', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
- { title: '审核时间', dataIndex: 'auditDate', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
- { title: '最近备货时间', dataIndex: 'lastStockUpDate', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
- { title: '业务状态', dataIndex: 'billStatusDictValue', width: 110, align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
- { title: '财务状态', dataIndex: 'financialStatus', scopedSlots: { customRender: 'financialStatus' }, width: 110, align: 'center' },
|
|
|
- { title: '打印次数', dataIndex: 'detailPrintTimes', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
- { title: '操作', scopedSlots: { customRender: 'action' }, width: 220, align: 'center', fixed: 'right' }
|
|
|
+ { title: '总数量', dataIndex: 'totalQty', scopedSlots: { customRender: 'totalQty' }, width: 60, align: 'center' },
|
|
|
+ { title: '总售价', dataIndex: 'totalAmount', width: 80, align: 'center', customRender: function (text) { return ((text || text == 0) ? ('¥' + text) : '--') } },
|
|
|
+ { title: '已下推数量', dataIndex: 'totalPushedQty', width: 60, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
+ { title: '已发货数量', dataIndex: 'totalDispatchQty', width: 60, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
+ { title: '已取消数量', dataIndex: 'totalCancelQty', width: 60, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
+ { title: '待下推数量', dataIndex: 'totalUnpushedQty', width: 60, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
+ { title: '收款方式', dataIndex: 'settleStyleSnDictValue', width: 80, align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
+ { title: '审核时间', dataIndex: 'auditDate', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
+ { title: '最近备货时间', dataIndex: 'lastStockUpDate', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
+ { title: '业务状态', dataIndex: 'billStatusDictValue', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
+ { title: '财务状态', dataIndex: 'financialStatus', scopedSlots: { customRender: 'financialStatus' }, width: 100, align: 'center' },
|
|
|
+ { title: '打印次数', dataIndex: 'detailPrintTimes', width: 50, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
+ { title: '操作', scopedSlots: { customRender: 'action' }, width: 150, align: 'center', fixed: 'right' }
|
|
|
],
|
|
|
// 加载数据方法 必须为 Promise 对象
|
|
|
loadData: parameter => {
|
|
|
this.disabled = true
|
|
|
delete parameter.tableId
|
|
|
delete parameter.index
|
|
|
- if (this.tableHeight == 0) {
|
|
|
- this.tableHeight = window.innerHeight - 440
|
|
|
- }
|
|
|
// 查询总计
|
|
|
salesCount(Object.assign(parameter, this.queryParam)).then(res => {
|
|
|
console.log(res)
|
|
@@ -287,6 +283,11 @@ export default {
|
|
|
auditInfo: null
|
|
|
}
|
|
|
},
|
|
|
+ computed: {
|
|
|
+ tableHeight () {
|
|
|
+ return window.innerHeight - (this.advanced ? 440 : 385)
|
|
|
+ }
|
|
|
+ },
|
|
|
methods: {
|
|
|
// 时间 change
|
|
|
dateChange (date) {
|