20 lines
440 B
PHP
Executable File
20 lines
440 B
PHP
Executable File
<?php
|
|
|
|
|
|
namespace A2nt\CMSNiceties\Extensions;
|
|
|
|
use SilverStripe\Blog\Forms\GridField\GridFieldConfigBlogPost;
|
|
use SilverStripe\Forms\FieldList;
|
|
use SilverStripe\ORM\DataExtension;
|
|
|
|
class BlogExtension extends DataExtension
|
|
{
|
|
public function updateCMSFields(FieldList $fields)
|
|
{
|
|
$f = $fields->dataFieldByName('ChildPages');
|
|
if ($f) {
|
|
$f->setConfig(GridFieldConfigBlogPost::create(75));
|
|
}
|
|
}
|
|
}
|