mirror of
https://github.com/a2nt/cms-niceties.git
synced 2024-10-22 11:05:46 +02:00
forTemplateShort
This commit is contained in:
parent
f38d186a09
commit
c7463ebfd9
@ -30,4 +30,12 @@ class BlogPostExtension extends DataExtension
|
|||||||
$mainTab = $fields->findOrMakeTab('Root.Main');
|
$mainTab = $fields->findOrMakeTab('Root.Main');
|
||||||
$mainTab->push(CheckboxField::create('Featured'));
|
$mainTab->push(CheckboxField::create('Featured'));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function forTemplateShort()
|
||||||
|
{
|
||||||
|
return $this->owner->renderWith([
|
||||||
|
$this->owner->ClassName.'_short',
|
||||||
|
'SilverStripe\Blog\Includes\BlogPostInfo'
|
||||||
|
]);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user