|
@ -57,8 +57,8 @@ |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
<div class=""> |
|
|
<div class=""> |
|
|
<el-table :key="tableKey" v-loading="listLoading" :data="list" border style="width: 100%;" @selection-change="handleSelectionChange"> |
|
|
<el-table :key="tableKey" v-loading="listLoading" :data="list" border style="width: 100%;" @selection-change="handleSelectionChange" show-summary :summary-method="getSummaries"> |
|
|
<el-table-column fixed type="selection" align="center" width="50"/> |
|
|
<el-table-column fixed type="selection" align="center" width="60"/> |
|
|
<el-table-column fixed label="序号" type="index" :index="indexMethod" align="center" width="80"/> |
|
|
<el-table-column fixed label="序号" type="index" :index="indexMethod" align="center" width="80"/> |
|
|
<el-table-column label="操作" align="center" width="180"> |
|
|
<el-table-column label="操作" align="center" width="180"> |
|
|
<template slot-scope="scope"> |
|
|
<template slot-scope="scope"> |
|
@ -84,8 +84,8 @@ |
|
|
<el-table-column prop="manufactorSettlementPrice" label="车辆入库价" align="center" width="140" /> |
|
|
<el-table-column prop="manufactorSettlementPrice" label="车辆入库价" align="center" width="140" /> |
|
|
<el-table-column prop="freight" label="其中运费" align="center" width="120" /> |
|
|
<el-table-column prop="freight" label="其中运费" align="center" width="120" /> |
|
|
<el-table-column prop="createTime" label="创建日期" align="center" width="120" /> |
|
|
<el-table-column prop="createTime" label="创建日期" align="center" width="120" /> |
|
|
<el-table-column prop="rebateName" label="返利名称" align="center" min-width="150" /> |
|
|
|
|
|
<el-table-column prop="rebateTypeValue" label="返利类型" align="center" width="120" /> |
|
|
<el-table-column prop="rebateTypeValue" label="返利类型" align="center" width="120" /> |
|
|
|
|
|
<el-table-column prop="rebateName" label="返利名称" align="center" min-width="150" /> |
|
|
<el-table-column prop="estimateRebate" label="预计返利" align="center" width="120" /> |
|
|
<el-table-column prop="estimateRebate" label="预计返利" align="center" width="120" /> |
|
|
<el-table-column prop="withholdCost" label="其中预提费用" align="center" width="140" /> |
|
|
<el-table-column prop="withholdCost" label="其中预提费用" align="center" width="140" /> |
|
|
<el-table-column prop="palceGenDate" label="所属年月" align="center" width="120" /> |
|
|
<el-table-column prop="palceGenDate" label="所属年月" align="center" width="120" /> |
|
@ -410,6 +410,7 @@ export default { |
|
|
// 查询条件 ----------- |
|
|
// 查询条件 ----------- |
|
|
tableKey: 0, |
|
|
tableKey: 0, |
|
|
list: [], |
|
|
list: [], |
|
|
|
|
|
listAll: [], |
|
|
sids: [], |
|
|
sids: [], |
|
|
FormLoading: false, |
|
|
FormLoading: false, |
|
|
state_list: [ |
|
|
state_list: [ |
|
@ -549,6 +550,13 @@ export default { |
|
|
this.listQuery.total = 0 |
|
|
this.listQuery.total = 0 |
|
|
} |
|
|
} |
|
|
}) |
|
|
}) |
|
|
|
|
|
req.checkApplyGetVehRebateAll(this.listQuery.params).then((res) => { |
|
|
|
|
|
if (res.success) { |
|
|
|
|
|
this.listAll = res.data |
|
|
|
|
|
} else { |
|
|
|
|
|
this.listAll = [] |
|
|
|
|
|
} |
|
|
|
|
|
}) |
|
|
}, |
|
|
}, |
|
|
// 查询按钮 |
|
|
// 查询按钮 |
|
|
handleFilter() { |
|
|
handleFilter() { |
|
@ -783,6 +791,33 @@ export default { |
|
|
this.uploadData.orgPath = '' |
|
|
this.uploadData.orgPath = '' |
|
|
this.getList() |
|
|
this.getList() |
|
|
} |
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
// 合计 |
|
|
|
|
|
getSummaries(param) { |
|
|
|
|
|
param.data = this.listAll |
|
|
|
|
|
const { columns, data } = param |
|
|
|
|
|
const sums = [] |
|
|
|
|
|
columns.forEach((column, index) => { |
|
|
|
|
|
if (index === 0) { |
|
|
|
|
|
sums[index] = '合计' |
|
|
|
|
|
return |
|
|
|
|
|
} |
|
|
|
|
|
const values = data.map(item => Number(item[column.property])) |
|
|
|
|
|
if (column.property === 'manufactorSettlementPrice' || column.property === 'freight' || column.property === 'estimateRebate' || column.property === 'expectCost' || column.property === 'uploadMoney' || column.property === 'secondaryUploadMoney' || column.property === 'stayDetermineMoney' || column.property === 'money' || column.property === 'diffAmount' || column.property === 'adjustmentMoney') { |
|
|
|
|
|
sums[index] = values.reduce((prev, curr) => { |
|
|
|
|
|
const value = Number(curr) |
|
|
|
|
|
if (!isNaN(value)) { |
|
|
|
|
|
return Math.round((parseFloat(prev) + parseFloat(curr)) * 100) / 100 |
|
|
|
|
|
} else { |
|
|
|
|
|
return Math.round((parseFloat(prev)) * 100) / 100 |
|
|
|
|
|
} |
|
|
|
|
|
}, 0) |
|
|
|
|
|
sums[index] += '' |
|
|
|
|
|
} else { |
|
|
|
|
|
sums[index] = '' |
|
|
|
|
|
} |
|
|
|
|
|
}) |
|
|
|
|
|
return sums |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|