mirror of
https://github.com/silverstripe/silverstripe-blog
synced 2024-10-22 11:05:58 +02:00
FIX Update Requirements references to new build paths
This commit is contained in:
parent
7ef456a1e6
commit
bf13d522a3
@ -21,7 +21,10 @@
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "3.0.x-dev"
|
||||
}
|
||||
},
|
||||
"expose": [
|
||||
"client/dist"
|
||||
]
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
|
@ -159,7 +159,7 @@ class GridFieldAddByDBField implements GridField_ActionProvider, GridField_HTMLP
|
||||
*/
|
||||
public function getHTMLFragments($gridField)
|
||||
{
|
||||
Requirements::javascript(ModuleLoader::getModule('silverstripe/blog')->getRelativeResourcePath('js/gridfieldaddbydbfield.js'));
|
||||
Requirements::javascript('silverstripe/blog:client/dist/js/main.bundle.js');
|
||||
|
||||
/**
|
||||
* @var DataList $dataList
|
||||
|
@ -21,7 +21,7 @@ class GridFieldBlogPostState extends GridFieldSiteTreeState
|
||||
public function getColumnContent($gridField, $record, $columnName)
|
||||
{
|
||||
if ($columnName == 'State') {
|
||||
Requirements::css('silverstripe/blog:css/cms.css');
|
||||
Requirements::css('silverstripe/blog:client/dist/styles/main.css');
|
||||
if ($record instanceof BlogPost) {
|
||||
$modifiedLabel = '';
|
||||
|
||||
|
@ -189,9 +189,8 @@ class Blog extends Page implements PermissionProvider
|
||||
*/
|
||||
protected function addCMSRequirements()
|
||||
{
|
||||
$module = ModuleLoader::getModule('silverstripe/blog');
|
||||
Requirements::css($module->getRelativeResourcePath('css/cms.css'));
|
||||
Requirements::javascript($module->getRelativeResourcePath('js/cms.js'));
|
||||
Requirements::css('silverstripe/blog:client/dist/styles/main.css');
|
||||
Requirements::javascript('silverstripe/blog:client/dist/js/main.bundle.js');
|
||||
}
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
|
@ -113,9 +113,8 @@ class BlogMemberExtension extends DataExtension
|
||||
$fields->removeFieldFromTab('Root', 'BlogPosts');
|
||||
|
||||
// Construct a better posts tab.
|
||||
$module = ModuleLoader::getModule('silverstripe/blog');
|
||||
Requirements::css($module->getRelativeResourcePath('css/cms.css'));
|
||||
Requirements::javascript($module->getRelativeResourcePath('js/cms.js'));
|
||||
Requirements::css('silverstripe/blog:client/dist/styles/main.css');
|
||||
Requirements::javascript('silverstripe/blog:client/dist/js/main.bundle.js');
|
||||
|
||||
$tab = Tab::create('BlogPosts', _t(__CLASS__ . '.TABBLOGPOSTS', 'Blog Posts'));
|
||||
|
||||
|
@ -211,9 +211,8 @@ class BlogPost extends Page
|
||||
*/
|
||||
public function getCMSFields()
|
||||
{
|
||||
$module = ModuleLoader::getModule('silverstripe/blog');
|
||||
Requirements::css($module->getRelativeResourcePath('css/cms.css'));
|
||||
Requirements::javascript($module->getRelativeResourcePath('js/cms.js'));
|
||||
Requirements::css('silverstripe/blog:client/dist/styles/main.css');
|
||||
Requirements::javascript('silverstripe/blog:client/dist/js/main.bundle.js');
|
||||
|
||||
$this->beforeUpdateCMSFields(function ($fields) {
|
||||
$uploadField = UploadField::create('FeaturedImage', _t(__CLASS__ . '.FeaturedImage', 'Featured Image'));
|
||||
|
Loading…
Reference in New Issue
Block a user