From da4119409c0a769fd7805b54de550a2a7eedefd9 Mon Sep 17 00:00:00 2001 From: Guy Sartorelli Date: Fri, 8 Nov 2024 14:20:07 +1300 Subject: [PATCH] API Add new configuration for use in CMSMain-like admin --- src/TaxonomyTerm.php | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/TaxonomyTerm.php b/src/TaxonomyTerm.php index 8c50fd2..329ee27 100644 --- a/src/TaxonomyTerm.php +++ b/src/TaxonomyTerm.php @@ -60,6 +60,8 @@ class TaxonomyTerm extends DataObject implements PermissionProvider private static $default_sort = 'Sort'; + private static string $sort_field = 'Sort'; + private static $summary_fields = array( 'Name' => 'Name', 'Type.Name' => 'Type' @@ -67,6 +69,12 @@ class TaxonomyTerm extends DataObject implements PermissionProvider private static $type_inheritance_enabled = true; + /** + * Css class attached to icons in a CMSMain tree. Also supports font-icon set. + * Overrides cms_icon for most purposes if set on the same class + */ + private static string $cms_icon_class = 'font-icon-tag'; + public function getCMSFields() { $this->beforeUpdateCMSFields(function (FieldList $fields) {