Merge pull request #327 from silverstripe/add-hook-for-extension-filters-on-category-blog-posts

Added hook for extension filters on category blog posts
This commit is contained in:
Damian Mooyman 2015-11-17 16:37:03 +13:00
commit 974e5636c4

View File

@ -40,6 +40,17 @@ class BlogCategory extends DataObject implements CategorisationObject {
private static $extensions = array(
'URLSegmentExtension',
);
/**
* @return DataList
*/
public function BlogPosts() {
$blogPosts = parent::BlogPosts();
$this->extend("updateGetBlogPosts", $blogPosts);
return $blogPosts;
}
/**
* {@inheritdoc}