Moved LandingPageFreshness to "Settings" tab

It just adds clutter under the main tab, and pushes
the actually important "Content" field further down the CMS screen
This commit is contained in:
Ingo Schommer 2013-04-11 00:42:23 +02:00
parent 899a81cb79
commit 92b6de1d77

View File

@ -106,7 +106,23 @@ class BlogTree extends Page {
function getCMSFields() {
$fields = parent::getCMSFields();
$fields->addFieldToTab('Root.Main', new DropdownField('LandingPageFreshness', 'When you first open the blog, how many entries should I show', array(
if(class_exists('WidgetArea')) {
$fields->addFieldToTab("Root.Widgets", new CheckboxField("InheritSideBar", 'Inherit Sidebar From Parent'));
$fields->addFieldToTab("Root.Widgets", new WidgetAreaEditor("SideBar"));
}
return $fields;
}
function getSettingsFields() {
$fields = parent::getSettingsFields();
$fields->addFieldToTab(
'Root.Settings',
new DropdownField(
'LandingPageFreshness',
'When you first open the blog, how many entries should I show',
array(
"" => "All entries",
"1" => "Last month's entries",
"2" => "Last 2 months' entries",
@ -121,12 +137,9 @@ class BlogTree extends Page {
"11" => "Last 11 months' entries",
"12" => "Last year's entries",
"INHERIT" => "Take value from parent Blog Tree"
)), "Content");
if(class_exists('WidgetArea')) {
$fields->addFieldToTab("Root.Widgets", new CheckboxField("InheritSideBar", 'Inherit Sidebar From Parent'));
$fields->addFieldToTab("Root.Widgets", new WidgetAreaEditor("SideBar"));
}
)
)
);
return $fields;
}