mirror of
https://github.com/ClusterCockpit/cc-backend
synced 2024-12-27 05:49:04 +01:00
pre-sort numerical ids in statstable
- sorting still fixed if not nodescope
This commit is contained in:
parent
298051c334
commit
163462b29c
@ -4,9 +4,14 @@
|
|||||||
export let scope
|
export let scope
|
||||||
export let jobMetrics
|
export let jobMetrics
|
||||||
|
|
||||||
|
function compareIds(a, b) {
|
||||||
|
return a.id - b.id;
|
||||||
|
}
|
||||||
|
|
||||||
$: series = jobMetrics
|
$: series = jobMetrics
|
||||||
.find(jm => jm.name == metric && jm.scope == scope)
|
.find(jm => jm.name == metric && jm.scope == scope)
|
||||||
?.metric.series.filter(s => s.hostname == host && s.statistics != null)
|
?.metric.series.filter(s => s.hostname == host && s.statistics != null)
|
||||||
|
?.sort(compareIds)
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
{#if series == null || series.length == 0}
|
{#if series == null || series.length == 0}
|
||||||
|
Loading…
Reference in New Issue
Block a user