From 22544593101ce670a809f3b354f5ff850840006b Mon Sep 17 00:00:00 2001 From: Robbie Averill Date: Mon, 3 Sep 2018 08:21:05 +0200 Subject: [PATCH] FIX Text collector translations now compile without errors --- lang/en.yml | 6 ++++-- src/Forms/DateField_Disabled.php | 4 ++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/lang/en.yml b/lang/en.yml index 8c1756543..2095bdd21 100644 --- a/lang/en.yml +++ b/lang/en.yml @@ -37,6 +37,8 @@ en: SilverStripe\Forms\CurrencyField: CURRENCYSYMBOL: $ SilverStripe\Forms\DateField: + NOTSET: 'not set' + TODAY: today VALIDDATEFORMAT2: 'Please enter a valid date format ({format})' VALIDDATEMAXDATE: 'Your date has to be older or matching the maximum allowed date ({date})' VALIDDATEMINDATE: 'Your date has to be newer or matching the minimum allowed date ({date})' @@ -97,14 +99,14 @@ en: Save: Save SilverStripe\Forms\GridField\GridFieldEditButton: EDIT: Edit - SilverStripe\Forms\GridField\GridFieldViewButton: - VIEW: View SilverStripe\Forms\GridField\GridFieldGroupDeleteAction: UnlinkSelfFailure: 'Cannot remove yourself from this group, you will lose admin rights' SilverStripe\Forms\GridField\GridFieldPaginator: OF: of Page: Page View: View + SilverStripe\Forms\GridField\GridFieldViewButton: + VIEW: View SilverStripe\Forms\MoneyField: FIELDLABELAMOUNT: Amount FIELDLABELCURRENCY: Currency diff --git a/src/Forms/DateField_Disabled.php b/src/Forms/DateField_Disabled.php index 22cd201c3..ebdda7c21 100644 --- a/src/Forms/DateField_Disabled.php +++ b/src/Forms/DateField_Disabled.php @@ -17,7 +17,7 @@ class DateField_Disabled extends DateField public function Field($properties = []) { // Default display value - $displayValue = '(' . _t(DateField::class . '.NOTSET', 'not set') . ')'; + $displayValue = '(' . _t('SilverStripe\\Forms\\DateField.NOTSET', 'not set') . ')'; $value = $this->dataValue(); @@ -29,7 +29,7 @@ class DateField_Disabled extends DateField if ($df->IsToday()) { // e.g. 2018-06-01 (today) $format = '%s (%s)'; - $infoComplement = _t(DateField::class . '.TODAY', 'today'); + $infoComplement = _t('SilverStripe\\Forms\\DateField.TODAY', 'today'); } else { // e.g. 2018-06-01, 5 days ago $format = '%s, %s';