diff --git a/src/views/ems/dzjk/home/index.vue b/src/views/ems/dzjk/home/index.vue index f06e78e..b2f9b1b 100644 --- a/src/views/ems/dzjk/home/index.vue +++ b/src/views/ems/dzjk/home/index.vue @@ -57,10 +57,6 @@ - - - - - - + @@ -174,7 +169,27 @@ export default { unit: 'kvar' } ] - } + }, + otherTypeMsg: [ + { + name: '正向有功电能', + attr: 'forwardActive', + pointName: '正向有功电能', + unit: 'kWh' + }, + { + name: '反向有功电能', + attr: 'reverseActive', + pointName: '反向有功电能', + unit: 'kWh' + }, + { + name: '有功功率', + attr: 'activePower', + pointName: '总有功功率', + unit: 'kW' + }, + ] }; }, methods: { diff --git a/src/views/ems/dzjk/tjbb/sybb/index.vue b/src/views/ems/dzjk/tjbb/sybb/index.vue index b065736..c1237a9 100644 --- a/src/views/ems/dzjk/tjbb/sybb/index.vue +++ b/src/views/ems/dzjk/tjbb/sybb/index.vue @@ -27,15 +27,14 @@ class="common-table" :data="tableData" show-summary - :summary-method="getSummaries" stripe style="width: 100%;margin-top:25px;"> - + + min-width="100px" align="center"> @@ -94,6 +93,14 @@ label="总"> + + + + + { - if (index === 0) { - const activeTotal = data.map(item => item.activeTotalPrice).reduce((prev, curr) => { - const value = Number(curr); - if (!isNaN(value)) { - return prev + curr; - } else { - return prev; - } - }, 0); - const reActiveTotal = data.map(item => item.reActiveTotalPrice).reduce((prev, curr) => { - const value = Number(curr); - if (!isNaN(value)) { - return prev + curr; - } else { - return prev; - } - }, 0); - sums[index] = '价差收入 : ' + (reActiveTotal - activeTotal); - return - } - const values = data.map(item => Number(item[column.property])); - if (!values.every(value => isNaN(value))) { - sums[index] = values.reduce((prev, curr) => { - const value = Number(curr); - if (!isNaN(value)) { - return prev + curr; - } else { - return prev; - } - }, 0); - } - }) - return sums - }, // 搜索 onSearch() { this.pageNum = 1//每次搜索从1开始搜索