@@ -45,7 +45,7 @@ discard block |
||
45 | 45 | |
46 | 46 | public function getCMSFields() |
47 | 47 | { |
48 | - $this->beforeUpdateCMSFields(function (FieldList $fields) { |
|
48 | + $this->beforeUpdateCMSFields(function(FieldList $fields) { |
|
49 | 49 | $resource = $this->DataResource(); |
50 | 50 | $fields->addFieldToTab('Root.Data', ResourceLocatorField::create('DataResource')); |
51 | 51 | |
@@ -71,11 +71,11 @@ discard block |
||
71 | 71 | $columns = $component->getDisplayFields($resourceFields); |
72 | 72 | |
73 | 73 | // We only want to change the labels for the GridField view, not the model's edit form |
74 | - $columns['ShowInSummaryView'] = _t(__CLASS__ . '.IN_RESULTS', 'In Results'); |
|
75 | - $columns['ShowInDetailView'] = _t(__CLASS__ . '.IN_DETAIL', 'In Detail'); |
|
74 | + $columns['ShowInSummaryView'] = _t(__CLASS__.'.IN_RESULTS', 'In Results'); |
|
75 | + $columns['ShowInDetailView'] = _t(__CLASS__.'.IN_DETAIL', 'In Detail'); |
|
76 | 76 | |
77 | 77 | // Abbreviate the position title |
78 | - $columns['Position'] = _t(__CLASS__ . '.POS', 'Pos.', 'Abbreviated version of position'); |
|
78 | + $columns['Position'] = _t(__CLASS__.'.POS', 'Pos.', 'Abbreviated version of position'); |
|
79 | 79 | |
80 | 80 | $editable = array_flip(['ShowInSummaryView', 'ShowInDetailView']); |
81 | 81 | $component->setDisplayFields(array_diff_key($columns, $editable)); |
@@ -110,7 +110,7 @@ discard block |
||
110 | 110 | $fields = parent::getSettingsFields(); |
111 | 111 | |
112 | 112 | $fields->addFieldsToTab('Root.Settings', [ |
113 | - TextField::create('ItemsPerPage', _t(__CLASS__ . '.ITEMS_PER_PAGE', 'Items per page')), |
|
113 | + TextField::create('ItemsPerPage', _t(__CLASS__.'.ITEMS_PER_PAGE', 'Items per page')), |
|
114 | 114 | ]); |
115 | 115 | |
116 | 116 | return $fields; |
@@ -54,10 +54,10 @@ discard block |
||
54 | 54 | |
55 | 55 | public function getCMSFields() |
56 | 56 | { |
57 | - $this->beforeUpdateCMSFields(function (FieldList $fields) { |
|
57 | + $this->beforeUpdateCMSFields(function(FieldList $fields) { |
|
58 | 58 | $originalLabel = ReadonlyField::create('OriginalLabel') |
59 | 59 | ->setDescription(_t( |
60 | - __CLASS__ . '.ORIGINAL_LABEL_DESCRIPTION', |
|
60 | + __CLASS__.'.ORIGINAL_LABEL_DESCRIPTION', |
|
61 | 61 | 'Title of this field as provided by the CKAN resource' |
62 | 62 | )); |
63 | 63 | // See https://github.com/silverstripe/silverstripe-framework/issues/8696 |
@@ -73,9 +73,9 @@ discard block |
||
73 | 73 | $fields->removeByName('Type'); |
74 | 74 | |
75 | 75 | $positionField = NumericField::create('Position') |
76 | - ->setTitle(_t(__CLASS__ . '.ORDER_LABEL', 'Presented order')) |
|
76 | + ->setTitle(_t(__CLASS__.'.ORDER_LABEL', 'Presented order')) |
|
77 | 77 | ->setDescription(_t( |
78 | - __CLASS__ . '.ORDER_DENOMINATOR', |
|
78 | + __CLASS__.'.ORDER_DENOMINATOR', |
|
79 | 79 | 'of {count} fields', |
80 | 80 | ['count' => static::get()->filter('ResourceID', $this->ResourceID)->count()] |
81 | 81 | )) |
@@ -90,7 +90,7 @@ discard block |
||
90 | 90 | ->addExtraClass('visibility-options__option'); |
91 | 91 | |
92 | 92 | // Present the visibility fields in a group |
93 | - $fields->removeByName(['ShowInSummaryView', 'ShowInDetailView', 'RemoveDuplicates',]); |
|
93 | + $fields->removeByName(['ShowInSummaryView', 'ShowInDetailView', 'RemoveDuplicates', ]); |
|
94 | 94 | $visibilityOptions = FieldGroup::create('Visibility', [$summary, $detail, $duplicates]) |
95 | 95 | ->addExtraClass('visibility-options'); |
96 | 96 | $fields->insertBefore($visibilityOptions, 'Position'); |
@@ -101,7 +101,7 @@ discard block |
||
101 | 101 | 'DisplayConditions', |
102 | 102 | ResultConditionsField::create( |
103 | 103 | 'DisplayConditions', |
104 | - _t(__CLASS__ . '.RESULT_CONDITIONS', 'Result conditions') |
|
104 | + _t(__CLASS__.'.RESULT_CONDITIONS', 'Result conditions') |
|
105 | 105 | ) |
106 | 106 | ); |
107 | 107 | }); |
@@ -60,7 +60,7 @@ discard block |
||
60 | 60 | |
61 | 61 | public function getCMSFields() |
62 | 62 | { |
63 | - $this->beforeUpdateCMSFields(function (FieldList $fields) { |
|
63 | + $this->beforeUpdateCMSFields(function(FieldList $fields) { |
|
64 | 64 | $allColumnsField = $fields->dataFieldByName('AllColumns'); |
65 | 65 | $allColumnsField->addExtraClass('ckan-columns__all-columns'); |
66 | 66 | // See https://github.com/silverstripe/silverstripe-framework/issues/8696 |
@@ -79,7 +79,7 @@ discard block |
||
79 | 79 | |
80 | 80 | $columnSources = CompositeField::create($allColumnsField, $filterFields); |
81 | 81 | $columnSources |
82 | - ->setTitle(_t(__CLASS__ . '.COLUMNS_SOURCES', 'Columns source(s)')) |
|
82 | + ->setTitle(_t(__CLASS__.'.COLUMNS_SOURCES', 'Columns source(s)')) |
|
83 | 83 | ->addExtraClass('ckan-columns__sources'); |
84 | 84 | $fields->push($columnSources); |
85 | 85 | |
@@ -129,7 +129,7 @@ discard block |
||
129 | 129 | return DBField::create_Field( |
130 | 130 | 'HTMLFragment', |
131 | 131 | '<span class="ckan-columns--all-columns">' |
132 | - . _t(__CLASS__ . '.ALL_COLUMNS', 'All columns') |
|
132 | + . _t(__CLASS__.'.ALL_COLUMNS', 'All columns') |
|
133 | 133 | . '</span>' |
134 | 134 | ); |
135 | 135 | } |
@@ -145,7 +145,7 @@ discard block |
||
145 | 145 | return DBField::create_Field( |
146 | 146 | 'HTMLFragment', |
147 | 147 | '<span class="ckan-columns--multiple">' |
148 | - . _t(__CLASS__ . '.MULTIPLE_COLUMNS', 'Multiple columns') |
|
148 | + . _t(__CLASS__.'.MULTIPLE_COLUMNS', 'Multiple columns') |
|
149 | 149 | . '</span>' |
150 | 150 | ); |
151 | 151 | } |