From e52171bf75d34ccf3e15e720414a7ed4fece99b5 Mon Sep 17 00:00:00 2001 From: Andrew O'Neil Date: Thu, 17 Dec 2009 08:00:34 +0000 Subject: [PATCH] Allow extending of blog holder fields --- code/BlogHolder.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/code/BlogHolder.php b/code/BlogHolder.php index 36e7e99..74aa094 100644 --- a/code/BlogHolder.php +++ b/code/BlogHolder.php @@ -28,12 +28,16 @@ class BlogHolder extends BlogTree implements PermissionProvider { ); function getCMSFields() { + SiteTree::disableCMSFieldsExtensions(); $fields = parent::getCMSFields(); + SiteTree::enableCMSFieldsExtensions(); $fields->addFieldToTab('Root.Content.Main', new CheckboxField('TrackBacksEnabled', 'Enable TrackBacks')); $fields->addFieldToTab('Root.Content.Main', new DropdownField('OwnerID', 'Blog owner', DataObject::get('Member')->toDropDownMap('ID', 'Name', 'None'))); $fields->addFieldToTab('Root.Content.Main', new CheckboxField('AllowCustomAuthors', 'Allow non-admins to have a custom author field')); + $this->extend('updateCMSFields', $fields); + return $fields; }