From ed70de49b80fc7f63043d3542a69005a282493dc Mon Sep 17 00:00:00 2001 From: Sam Minnee Date: Thu, 9 Jul 2009 05:41:30 +0000 Subject: [PATCH] BUGFIX "Page type" dropdown for site tree filters is now sorted alphabetically, to be consistent with the "Create" page type dropdown list git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/cms/trunk@81462 467b73ca-7a2a-4603-9d3b-597d59a354a9 --- code/CMSMain.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/code/CMSMain.php b/code/CMSMain.php index db70df98..e6697fc5 100644 --- a/code/CMSMain.php +++ b/code/CMSMain.php @@ -208,7 +208,9 @@ class CMSMain extends LeftAndMain implements CurrentPageIdentifier, PermissionPr } public function SiteTreeFilterPageTypeField() { $types = SiteTree::page_type_classes(); array_unshift($types, 'All'); - $optionsetField = new DropdownField('ClassName', 'ClassName', array_combine($types, $types), 'Any'); + $source = array_combine($types, $types); + asort($source); + $optionsetField = new DropdownField('ClassName', 'ClassName', $source, 'Any'); return $optionsetField->Field(); }