|
@@ -15,12 +15,16 @@
|
|
|
<a-row :gutter="15">
|
|
|
<a-col :md="6" :sm="24">
|
|
|
<a-form-model-item label="导入类型">
|
|
|
- <v-select
|
|
|
- v-model="queryParam.salesBillSource"
|
|
|
- ref="salesBillSource"
|
|
|
- code="SALES_SOURCE"
|
|
|
+ <a-select
|
|
|
placeholder="请选择导入类型"
|
|
|
- allowClear></v-select>
|
|
|
+ v-model="queryParam.importType">
|
|
|
+ <a-select-option value="STOCK_IMPORT">
|
|
|
+ 库存导入
|
|
|
+ </a-select-option>
|
|
|
+ <a-select-option value="SPARE_PARTS_IMPORT">
|
|
|
+ 散件导入
|
|
|
+ </a-select-option>
|
|
|
+ </a-select>
|
|
|
</a-form-model-item>
|
|
|
</a-col>
|
|
|
<a-col :md="6" :sm="24">
|
|
@@ -38,10 +42,10 @@
|
|
|
<!-- 合计 -->
|
|
|
<a-alert type="info" style="margin-bottom:10px">
|
|
|
<div class="ftext" slot="message">
|
|
|
- 总单数:<strong>{{ (totalData && (totalData.totalCategory || totalData.totalCategory==0)) ? totalData.totalCategory : '--' }}</strong>;
|
|
|
- 产品总数量:<strong>{{ (totalData && (totalData.totalQty || totalData.totalQty==0)) ? totalData.totalQty : '--' }}</strong>;
|
|
|
+ 总单数:<strong>{{ (totalData && (totalData.totalRowSize || totalData.totalRowSize==0)) ? totalData.totalRowSize : '--' }}</strong>;
|
|
|
+ 产品总数量:<strong>{{ (totalData && (totalData.productTotalQty || totalData.productTotalQty==0)) ? totalData.productTotalQty : '--' }}</strong>;
|
|
|
<div v-if="$hasPermissions('M_ShowAllCost')" style="display: inline-block;">
|
|
|
- 总成本:<strong>{{ (totalData && (totalData.totalCost || totalData.totalCost==0)) ? '¥'+totalData.totalCost : '--' }}</strong>。
|
|
|
+ 总成本:<strong>{{ (totalData && (totalData.productTotalCost || totalData.productTotalCost==0)) ? '¥'+totalData.productTotalCost : '--' }}</strong>。
|
|
|
</div>
|
|
|
</div>
|
|
|
</a-alert>
|
|
@@ -63,7 +67,7 @@
|
|
|
import { commonMixin } from '@/utils/mixin'
|
|
|
import { STable, VSelect } from '@/components'
|
|
|
import rangeDate from '@/views/common/rangeDate.vue'
|
|
|
-import { reportSalesReturnPageList, reportSalesReturnBillTotal } from '@/api/reportData'
|
|
|
+import { reportStockImportList, reportStockImportCount } from '@/api/reportData'
|
|
|
export default {
|
|
|
components: { STable, VSelect, rangeDate },
|
|
|
mixins: [commonMixin],
|
|
@@ -78,8 +82,7 @@ export default {
|
|
|
time: [],
|
|
|
beginDate: '',
|
|
|
endDate: '',
|
|
|
- buyerName: '',
|
|
|
- salesReturnNo: ''
|
|
|
+ importType: undefined
|
|
|
},
|
|
|
rules: {
|
|
|
'time': [{ required: true, message: '请选择导入时间', trigger: 'change' }]
|
|
@@ -92,7 +95,7 @@ export default {
|
|
|
const params = Object.assign(parameter, this.queryParam)
|
|
|
this.spinning = true
|
|
|
delete params.time
|
|
|
- return reportSalesReturnPageList(params).then(res => {
|
|
|
+ return reportStockImportList(params).then(res => {
|
|
|
let data
|
|
|
if (res.status == 200) {
|
|
|
data = res.data
|
|
@@ -115,15 +118,15 @@ export default {
|
|
|
columns () {
|
|
|
const arr = [
|
|
|
{ title: '序号', dataIndex: 'no', width: '5%', align: 'center' },
|
|
|
- { title: '库存导入单', dataIndex: 'salesReturnNo', width: '20%', align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
- { title: '导入类型', dataIndex: 'buyerName', width: '15%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
|
|
|
- { title: '款数', dataIndex: 'totalCategory', width: '15%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
- { title: '数量', dataIndex: 'totalQty', width: '15%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
+ { title: '库存导入单', dataIndex: 'stockImportNo', width: '20%', align: 'center', customRender: function (text) { return text || '--' } },
|
|
|
+ { title: '导入类型', dataIndex: 'importTypeDictValue', width: '15%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
|
|
|
+ { title: '款数', dataIndex: 'productTotalCategory', width: '15%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
+ { title: '数量', dataIndex: 'productTotalQty', width: '15%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
// { title: '成本', dataIndex: 'totalCost', width: '10%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
- { title: '导入时间', dataIndex: 'auditTime', width: '15%', align: 'center', customRender: function (text) { return text || '--' } }
|
|
|
+ { title: '导入时间', dataIndex: 'importTime', width: '15%', align: 'center', customRender: function (text) { return text || '--' } }
|
|
|
]
|
|
|
if (this.$hasPermissions('M_ShowAllCost')) {
|
|
|
- arr.splice(5, 0, { title: '成本', dataIndex: 'totalCost', width: '15%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } })
|
|
|
+ arr.splice(5, 0, { title: '成本', dataIndex: 'productTotalCost', width: '15%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } })
|
|
|
}
|
|
|
return arr
|
|
|
}
|
|
@@ -131,7 +134,7 @@ export default {
|
|
|
methods: {
|
|
|
// 合计
|
|
|
getCount (params) {
|
|
|
- reportSalesReturnBillTotal(params).then(res => {
|
|
|
+ reportStockImportCount(params).then(res => {
|
|
|
if (res.status == 200) {
|
|
|
this.totalData = res.data
|
|
|
} else {
|
|
@@ -158,15 +161,16 @@ export default {
|
|
|
},
|
|
|
// 重置
|
|
|
resetSearchForm () {
|
|
|
- this.$refs.rangeDate.resetDate()
|
|
|
this.queryParam.time = []
|
|
|
this.queryParam.beginDate = ''
|
|
|
this.queryParam.endDate = ''
|
|
|
- this.queryParam.salesReturnNo = ''
|
|
|
- this.queryParam.buyerName = ''
|
|
|
+ this.queryParam.importType = undefined
|
|
|
this.$refs.ruleForm.resetFields()
|
|
|
this.totalData = null
|
|
|
this.$refs.table.clearTable()
|
|
|
+ this.$nextTick(() => {
|
|
|
+ this.$refs.rangeDate.resetDate()
|
|
|
+ })
|
|
|
},
|
|
|
pageInit () {}
|
|
|
},
|