Fix: Reports rows weren't always properly sorted (Fix #6065)

This commit is contained in:
nicolas.dorier 2024-07-04 18:09:03 +09:00
parent 247532e3c4
commit 1157e2d04b
No known key found for this signature in database
GPG key ID: 6618763EF09186FE
2 changed files with 2 additions and 1 deletions

View file

@ -128,7 +128,7 @@
<template v-else-if="srv.result.fields[columnIndex].type === 'tx_id'"> <template v-else-if="srv.result.fields[columnIndex].type === 'tx_id'">
<vc:truncate-center text="value" is-vue="true" padding="15" classes="truncate-center-id" link="getExplorerUrl(value, row[columnIndex-1])" /> <vc:truncate-center text="value" is-vue="true" padding="15" classes="truncate-center-id" link="getExplorerUrl(value, row[columnIndex-1])" />
</template> </template>
<template v-else-if="value && ['Address', 'PaymentId'].includes(srv.result.fields[columnIndex].name)" > <template v-else-if="value && ['Address'].includes(srv.result.fields[columnIndex].name)" >
<vc:truncate-center text="value" is-vue="true" padding="15" classes="truncate-center-id" /> <vc:truncate-center text="value" is-vue="true" padding="15" classes="truncate-center-id" />
</template> </template>
<template v-else-if="srv.result.fields[columnIndex].type === 'datetime'">{{ displayDate(value) }}</template> <template v-else-if="srv.result.fields[columnIndex].type === 'datetime'">{{ displayDate(value) }}</template>

View file

@ -187,6 +187,7 @@
} }
function createTable(summaryDefinition, fields, rows) { function createTable(summaryDefinition, fields, rows) {
rows = clone(rows);
var groupIndices = summaryDefinition.groups.map(g => fields.findIndex((a) => a === g)).filter(g => g !== -1); var groupIndices = summaryDefinition.groups.map(g => fields.findIndex((a) => a === g)).filter(g => g !== -1);
var aggregatesIndices = summaryDefinition.aggregates.map(g => fields.findIndex((a) => a === g)).filter(g => g !== -1); var aggregatesIndices = summaryDefinition.aggregates.map(g => fields.findIndex((a) => a === g)).filter(g => g !== -1);
aggregatesIndices = aggregatesIndices.filter(g => g !== -1); aggregatesIndices = aggregatesIndices.filter(g => g !== -1);