-
Notifications
You must be signed in to change notification settings - Fork 36
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update translations and update classes to use __CLASS__ in translations
- Loading branch information
1 parent
f1c58fd
commit edef740
Showing
7 changed files
with
76 additions
and
72 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,22 +1,30 @@ | ||
en: | ||
ContentReview: | ||
SilverStripe\ContentReview\Extensions\ContentReviewCMSExtension: | ||
ErrorItemPermissionDenied: 'It seems you don''t have the necessary permissions to review this content' | ||
SilverStripe\ContentReview\Extensions\ContentReviewDefaultSettings: | ||
ADDGROUP: 'Add groups' | ||
ADDUSERS: 'Add users' | ||
BUTTONREVIEWED: 'Review content' | ||
COMMENTS: '(optional) Add comments...' | ||
CONTENTOWNERS: 'Content Owners' | ||
CONTENTREVIEW: 'Content due for review' | ||
CUSTOM: 'Custom settings' | ||
DEFAULTSETTINGSHELP: 'These settings will apply to all pages that do not have a specific Content Review schedule.' | ||
DISABLE: 'Disable content review' | ||
EMAILFROM: 'From email address' | ||
EMAILFROM_RIGHTTITLE: 'e.g: [email protected]' | ||
EMAILSUBJECT: 'Subject line' | ||
EMAILTEMPLATE: 'Email template' | ||
OWNERGROUPSDESCRIPTION: 'Page owners that are responsible for reviews' | ||
OWNERUSERSDESCRIPTION: 'Page owners that are responsible for reviews' | ||
PAGEOWNERGROUPS: Groups | ||
PAGEOWNERUSERS: Users | ||
REVIEWFREQUENCY: 'Review frequency' | ||
REVIEWFREQUENCYDESCRIPTION: 'The review date will be set to this far in the future, whenever the page is published.' | ||
SilverStripe\ContentReview\Extensions\SiteTreeContentReview: | ||
ADDGROUP: 'Add groups' | ||
ADDUSERS: 'Add users' | ||
CONTENTOWNERS: 'Content Owners' | ||
CONTENTREVIEW: 'Content due for review' | ||
CUSTOM: 'Custom settings' | ||
DISABLE: 'Disable content review' | ||
INHERIT: 'Inherit from parent page' | ||
MARKREVIEWED: 'Mark as reviewed' | ||
NEXTREVIEWDATADESCRIPTION: 'Leave blank for no review' | ||
NEXTREVIEWDATE: 'Next review date' | ||
NOCOMMENTS: '(no comments)' | ||
OPTIONS: Options | ||
OWNERGROUPSDESCRIPTION: 'Page owners that are responsible for reviews' | ||
OWNERUSERSDESCRIPTION: 'Page owners that are responsible for reviews' | ||
|
@@ -25,31 +33,27 @@ en: | |
REVIEWFREQUENCY: 'Review frequency' | ||
REVIEWFREQUENCYDESCRIPTION: 'The review date will be set to this far in the future whenever the page is published' | ||
REVIEWHEADER: 'Content review' | ||
REVIEWNOTES: 'Review notes' | ||
REVIEWSUCCESSFUL: 'Content reviewed successfully' | ||
SAVE: Save | ||
SETTINGSFROM: 'Options are' | ||
ContentReviewEmails: | ||
REVIEWPAGELINK: 'Review the page in the CMS' | ||
SUBJECT: 'Page(s) are due for content review' | ||
VIEWPUBLISHEDLINK: 'View this page on the website' | ||
ContentReviewLog: | ||
SilverStripe\ContentReview\Forms\ReviewContentHandler: | ||
ErrorReviewPermissionDenied: 'It seems you don''t have the necessary permissions to submit a content review' | ||
MarkAsReviewedAction: 'Mark as reviewed' | ||
NoComments: '(no comments)' | ||
Placeholder: 'Add comments (optional)' | ||
Success: 'Review successfully added' | ||
SilverStripe\ContentReview\Models\ContentReviewLog: | ||
PLURALNAME: 'Content Review Logs' | ||
PLURALS: | ||
one: 'A Content Review Log' | ||
other: '{count} Content Review Logs' | ||
SINGULARNAME: 'Content Review Log' | ||
PagesDueForReviewReport: | ||
SilverStripe\ContentReview\Reports\PagesDueForReviewReport: | ||
ONLYMYPAGES: 'Only Show pages assigned to me' | ||
REVIEWDATEAFTER: 'Review date after or on' | ||
REVIEWDATEBEFORE: 'Review date before or on' | ||
SHOWVIRTUALPAGES: 'Show Virtual Pages' | ||
TITLE: 'Pages due for review' | ||
PagesWithoutReviewScheduleReport: | ||
SilverStripe\ContentReview\Reports\PagesWithoutReviewScheduleReport: | ||
TITLE: 'Pages without a scheduled review.' | ||
Review: | ||
EMAILFROM_RIGHTTITLE: 'e.g: [email protected]' | ||
|
||
SilverStripe\ContentReview\Forms\ReviewContentHandler: | ||
ContentDueForReview: Content due for review | ||
MarkAsReviewedAction: Mark as reviewed | ||
NoComments: (no comments) | ||
Placeholder: Add comments (optional) | ||
Success: Review successfully added | ||
SilverStripe\ContentReview\Tasks\ContentReviewEmails: | ||
REVIEWPAGELINK: 'Review the page in the CMS' | ||
VIEWPUBLISHEDLINK: 'View this page on the website' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -108,7 +108,7 @@ public function updateCMSFields(FieldList $fields) | |
$helpText = LiteralField::create( | ||
'ContentReviewHelp', | ||
_t( | ||
'ContentReview.DEFAULTSETTINGSHELP', | ||
__CLASS__ . '.DEFAULTSETTINGSHELP', | ||
'These settings will apply to all pages that do not have a specific Content Review schedule.' | ||
) | ||
); | ||
|
@@ -117,11 +117,11 @@ public function updateCMSFields(FieldList $fields) | |
|
||
$reviewFrequency = DropdownField::create( | ||
'ReviewPeriodDays', | ||
_t('ContentReview.REVIEWFREQUENCY', 'Review frequency'), | ||
_t(__CLASS__ . '.REVIEWFREQUENCY', 'Review frequency'), | ||
SiteTreeContentReview::get_schedule() | ||
) | ||
->setDescription(_t( | ||
'ContentReview.REVIEWFREQUENCYDESCRIPTION', | ||
__CLASS__ . '.REVIEWFREQUENCYDESCRIPTION', | ||
'The review date will be set to this far in the future, whenever the page is published.' | ||
)); | ||
|
||
|
@@ -135,9 +135,9 @@ public function updateCMSFields(FieldList $fields) | |
$usersMap = $users->map('ID', 'Title')->toArray(); | ||
asort($usersMap); | ||
|
||
$userField = ListboxField::create('OwnerUsers', _t('ContentReview.PAGEOWNERUSERS', 'Users'), $usersMap) | ||
->setAttribute('data-placeholder', _t('ContentReview.ADDUSERS', 'Add users')) | ||
->setDescription(_t('ContentReview.OWNERUSERSDESCRIPTION', 'Page owners that are responsible for reviews')); | ||
$userField = ListboxField::create('OwnerUsers', _t(__CLASS__ . '.PAGEOWNERUSERS', 'Users'), $usersMap) | ||
->setAttribute('data-placeholder', _t(__CLASS__ . '.ADDUSERS', 'Add users')) | ||
->setDescription(_t(__CLASS__ . '.OWNERUSERSDESCRIPTION', 'Page owners that are responsible for reviews')); | ||
|
||
$fields->addFieldToTab('Root.ContentReview', $userField); | ||
|
||
|
@@ -150,20 +150,20 @@ public function updateCMSFields(FieldList $fields) | |
|
||
asort($groupsMap); | ||
|
||
$groupField = ListboxField::create('OwnerGroups', _t('ContentReview.PAGEOWNERGROUPS', 'Groups'), $groupsMap) | ||
->setAttribute('data-placeholder', _t('ContentReview.ADDGROUP', 'Add groups')) | ||
->setDescription(_t('ContentReview.OWNERGROUPSDESCRIPTION', 'Page owners that are responsible for reviews')); | ||
$groupField = ListboxField::create('OwnerGroups', _t(__CLASS__ . '.PAGEOWNERGROUPS', 'Groups'), $groupsMap) | ||
->setAttribute('data-placeholder', _t(__CLASS__ . '.ADDGROUP', 'Add groups')) | ||
->setDescription(_t(__CLASS__ . '.OWNERGROUPSDESCRIPTION', 'Page owners that are responsible for reviews')); | ||
|
||
$fields->addFieldToTab('Root.ContentReview', $groupField); | ||
|
||
// Email content | ||
$fields->addFieldsToTab( | ||
'Root.ContentReview', | ||
array( | ||
TextField::create('ReviewFrom', _t('ContentReview.EMAILFROM', 'From email address')) | ||
->setDescription(_t('Review.EMAILFROM_RIGHTTITLE', 'e.g: [email protected]')), | ||
TextField::create('ReviewSubject', _t('ContentReview.EMAILSUBJECT', 'Subject line')), | ||
TextAreaField::create('ReviewBody', _t('ContentReview.EMAILTEMPLATE', 'Email template')), | ||
TextField::create('ReviewFrom', _t(__CLASS__ . '.EMAILFROM', 'From email address')) | ||
->setDescription(_t(__CLASS__ . '.EMAILFROM_RIGHTTITLE', 'e.g: [email protected]')), | ||
TextField::create('ReviewSubject', _t(__CLASS__ . '.EMAILSUBJECT', 'Subject line')), | ||
TextAreaField::create('ReviewBody', _t(__CLASS__ . '.EMAILTEMPLATE', 'Email template')), | ||
LiteralField::create( | ||
'TemplateHelp', | ||
$this->owner->renderWith('SilverStripe\\ContentReview\\ContentReviewAdminHelp') | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
templates/SilverStripe/ContentReview/Extensions/SiteTreeContentReview_button.ss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
<div class="content-review__button-holder"> | ||
<a href="#" class="content-review__button"><%t ContentReview.CONTENTREVIEW 'Content due for review' %></a> | ||
<a href="#" class="content-review__button"><%t SilverStripe\\ContentReview\\Extensions\\SiteTreeContentReview.CONTENTREVIEW 'Content due for review' %></a> | ||
</div> |