【类 型】:fix
【原 因】:订单列表 总额统计 没有计算 运费打包费 【过 程】: 【影 响】:
This commit is contained in:
parent
344e1d79d7
commit
5585ace367
@ -103,6 +103,7 @@ export default {
|
||||
const res = await getOrderList(orderSerch)
|
||||
if (res.data.status === 1) {
|
||||
this.orderList = res.data.orderList
|
||||
console.log(this.orderList)
|
||||
this.loading = false
|
||||
} else {
|
||||
this.$message.error('获取订单列表失败')
|
||||
@ -119,7 +120,7 @@ export default {
|
||||
*/
|
||||
getSummaries () {
|
||||
const sum = this.orderList.reduce((acc, order) => {
|
||||
return acc + (order.total_price - order.refund_price)
|
||||
return acc + (Number(order.total_price) + Number(order.transport_price) + Number(order.pack_price) - Number(order.refund_price))
|
||||
}, 0)
|
||||
const total = this.orderList.length
|
||||
return ['合计', '', '', '', '', `共 ${total}单 ${formatPrice(sum)}元`]
|
||||
|
Loading…
Reference in New Issue
Block a user