mirror of
https://github.com/silverstripe/silverstripe-blog
synced 2024-10-22 11:05:58 +02:00
Blog: Wrapped CMS fields in beforeUpdateCMSFields to allow for customisation
This commit is contained in:
parent
eea227d42e
commit
be0e8e283a
@ -33,7 +33,7 @@ class Blog extends Page {
|
|||||||
|
|
||||||
|
|
||||||
public function getCMSFields() {
|
public function getCMSFields() {
|
||||||
$fields = parent::getCMSFields();
|
$this->beforeUpdateCMSFields(function($fields) {
|
||||||
|
|
||||||
$posts = $this->getBlogPosts();
|
$posts = $this->getBlogPosts();
|
||||||
$excluded = $this->getExcludedSiteTreeClassNames();
|
$excluded = $this->getExcludedSiteTreeClassNames();
|
||||||
@ -72,6 +72,9 @@ class Blog extends Page {
|
|||||||
$tags
|
$tags
|
||||||
));
|
));
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
|
$fields = parent::getCMSFields();
|
||||||
return $fields;
|
return $fields;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user