From e5de673f68e2fc7123e65dec88921857207f3f9a Mon Sep 17 00:00:00 2001 From: Thomas Gelf Date: Mon, 5 Dec 2022 12:48:30 +0100 Subject: [PATCH] IcingaObjectFieldForm: sort case insensitive fixes #2358 --- application/forms/IcingaObjectFieldForm.php | 3 ++- doc/82-Changelog.md | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/application/forms/IcingaObjectFieldForm.php b/application/forms/IcingaObjectFieldForm.php index 537c95e4..e380576e 100644 --- a/application/forms/IcingaObjectFieldForm.php +++ b/application/forms/IcingaObjectFieldForm.php @@ -90,7 +90,7 @@ class IcingaObjectFieldForm extends DirectorObjectForm // Prepare combined fields array $fields = array(); if (! empty($suggestedFields)) { - asort($existingFields); + asort($suggestedFields, SORT_NATURAL | SORT_FLAG_CASE); $fields[$this->translate('Suggested fields')] = $suggestedFields; } @@ -100,6 +100,7 @@ class IcingaObjectFieldForm extends DirectorObjectForm } if (! empty($existingFields)) { + asort($existingFields, SORT_NATURAL | SORT_FLAG_CASE); $fields[$this->translate('Other available fields')] = $existingFields; } diff --git a/doc/82-Changelog.md b/doc/82-Changelog.md index b5ba7c66..4b70da62 100644 --- a/doc/82-Changelog.md +++ b/doc/82-Changelog.md @@ -11,6 +11,7 @@ This version hasn't been released yet ### UI * FEATURE: allow to clone commands with fields (#2264) +* FEATURE: Data Fields are now sorted in a case-insensitive way (#2358) ### Icinga Configuration * FIX: render Set Services to individual zones where required (#1589, #2356)