Merge pull request #15 from purplespider/1.0

MINOR: BlogPost: Sets Title label to "Post Title"
This commit is contained in:
Michael Strong 2014-06-11 15:46:46 +01:00
commit 17762568cf
2 changed files with 14 additions and 0 deletions

View File

@ -14,6 +14,7 @@ en:
Categories: 'Categories'
Tags: 'Tags'
FeaturedImage: 'Featured Image'
PageTitleLabel: 'Post Title'
Blog:
BlogPosts: 'Blog Posts'
Categories: 'Categories'

View File

@ -176,6 +176,19 @@ class BlogPost extends Page {
return Controller::join_links($this->Parent()->Link("archive"), $date->format("Y"));
}
/**
* Sets the label for BlogPost.Title to 'Post Title' (Rather than 'Page name')
*
* @return array
**/
public function fieldLabels($includerelations = true) {
$labels = parent::fieldLabels($includerelations);
$labels['Title'] = _t('BlogPost.PageTitleLabel', "Post Title");
return $labels;
}
}