https://jsfiddle.net/fag8xy88/ 怎么算出正确的合计总额?
https://jsfiddle.net/fag8xy88/1/
改动的地方
<el-table-column prop="sum" label="总额">
<template scope="scope">
{{scope.row.sum = scope.row.price * scope.row.amount}}
</template>
</el-table-column>
改得比较简单粗暴
11 回答1.3k 阅读
4 回答576 阅读✓ 已解决
3 回答855 阅读
2 回答577 阅读
1 回答677 阅读
我是这样改的,重新组合了一下数据,也不需要:formatter了,希望对你有帮助