From 83fe489949d9b45c5643379d59b821ffb917ac7b Mon Sep 17 00:00:00 2001 From: jamesread Date: Mon, 10 Nov 2025 21:08:34 +0000 Subject: [PATCH] fix: (#703) Fixed entity fieldsets being drawn in a random order --- service/internal/api/dashboards.go | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/service/internal/api/dashboards.go b/service/internal/api/dashboards.go index 28f5c12..c837226 100644 --- a/service/internal/api/dashboards.go +++ b/service/internal/api/dashboards.go @@ -89,13 +89,10 @@ func buildDefaultDashboard(rr *DashboardRenderRequest) *apiv1.Dashboard { } func sortActions(components []*apiv1.DashboardComponent) []*apiv1.DashboardComponent { + log.Infof("sortActions: %+v", components) sort.Slice(components, func(i, j int) bool { - if components[i].Action == nil { - return false - } - - if components[j].Action == nil { - return true + if components[i].Action == nil || components[j].Action == nil { + return components[i].Title < components[j].Title } if components[i].Action.Order == components[j].Action.Order {