AdminUi Extension - Translate strings
authorColeman Watts <coleman@civicrm.org>
Sun, 18 Sep 2022 22:55:54 +0000 (18:55 -0400)
committerColeman Watts <coleman@civicrm.org>
Sun, 18 Sep 2022 22:55:54 +0000 (18:55 -0400)
ext/civicrm_admin_ui/managed/SavedSearch_Administer_Contact_Types.php
ext/civicrm_admin_ui/managed/SavedSearch_Administer_Custom_Fields.mgd.php
ext/civicrm_admin_ui/managed/SavedSearch_Administer_Custom_Groups.mgd.php

index bce63cb882ed98c9d755646b137f0933b82a9fac..8531e041db282ade24fcae13ea7e1bba346ba200 100644 (file)
@@ -1,4 +1,6 @@
 <?php
+use CRM_CivicrmAdminUi_ExtensionUtil as E;
+
 return [
   [
     'name' => 'SavedSearch_Administer_Contact_Types',
@@ -9,7 +11,7 @@ return [
       'version' => 4,
       'values' => [
         'name' => 'Administer_Contact_Types',
-        'label' => 'Administer Contact Types',
+        'label' => E::ts('Administer Contact Types'),
         'form_values' => NULL,
         'mapping_id' => NULL,
         'search_custom_id' => NULL,
@@ -41,7 +43,7 @@ return [
       'version' => 4,
       'values' => [
         'name' => 'Contact_Types_Table',
-        'label' => 'Contact Types Table',
+        'label' => E::ts('Contact Types Table'),
         'saved_search_id.name' => 'Administer_Contact_Types',
         'type' => 'table',
         'settings' => [
@@ -70,7 +72,7 @@ return [
               'type' => 'field',
               'key' => 'label',
               'dataType' => 'String',
-              'label' => 'Label',
+              'label' => E::ts('Label'),
               'sortable' => TRUE,
               'icons' => [
                 [
@@ -84,7 +86,7 @@ return [
               'type' => 'field',
               'key' => 'parent_id:label',
               'dataType' => 'Integer',
-              'label' => 'Parent',
+              'label' => E::ts('Parent'),
               'sortable' => TRUE,
               'icons' => [
                 [
@@ -101,7 +103,7 @@ return [
               'type' => 'field',
               'key' => 'description',
               'dataType' => 'Text',
-              'label' => 'Description',
+              'label' => E::ts('Description'),
               'sortable' => TRUE,
               'editable' => TRUE,
             ],
@@ -114,7 +116,7 @@ return [
                   'join' => '',
                   'target' => 'crm-popup',
                   'icon' => 'fa-pencil',
-                  'text' => 'Edit',
+                  'text' => E::ts('Edit'),
                   'style' => 'default',
                   'path' => '',
                   'condition' => [],
@@ -125,7 +127,7 @@ return [
                   'join' => '',
                   'target' => 'crm-popup',
                   'icon' => 'fa-trash',
-                  'text' => 'Delete',
+                  'text' => E::ts('Delete'),
                   'style' => 'danger',
                   'path' => '',
                   'condition' => [
@@ -140,7 +142,7 @@ return [
           ],
           'addButton' => [
             'path' => 'civicrm/admin/options/subtype/edit?action=add&reset=1',
-            'text' => 'Add Contact Type',
+            'text' => E::ts('Add Contact Type'),
             'icon' => 'fa-plus',
           ],
         ],
index 0151fe4f9a15e40cf15170f1d08a74e83c227ad8..652498e75b02bad7006c40ff8c353b84b391f097 100644 (file)
@@ -1,4 +1,6 @@
 <?php
+use CRM_CivicrmAdminUi_ExtensionUtil as E;
+
 return [
   [
     'name' => 'SavedSearch_Administer_Custom_Fields',
@@ -9,7 +11,7 @@ return [
       'version' => 4,
       'values' => [
         'name' => 'Administer_Custom_Fields',
-        'label' => 'Administer Custom Fields',
+        'label' => E::ts('Administer Custom Fields'),
         'form_values' => NULL,
         'search_custom_id' => NULL,
         'api_entity' => 'CustomField',
@@ -46,7 +48,7 @@ return [
       'version' => 4,
       'values' => [
         'name' => 'Table',
-        'label' => 'Table',
+        'label' => E::ts('Table'),
         'saved_search_id.name' => 'Administer_Custom_Fields',
         'type' => 'table',
         'settings' => [
@@ -66,35 +68,35 @@ return [
               'type' => 'field',
               'key' => 'id',
               'dataType' => 'String',
-              'label' => 'ID',
+              'label' => E::ts('ID'),
               'sortable' => TRUE,
             ],
             [
               'type' => 'field',
               'key' => 'label',
               'dataType' => 'String',
-              'label' => 'Field Label',
+              'label' => E::ts('Field Label'),
               'sortable' => TRUE,
             ],
             [
               'type' => 'field',
               'key' => 'data_type:label',
               'dataType' => 'String',
-              'label' => 'Data Type',
+              'label' => E::ts('Data Type'),
               'sortable' => TRUE,
             ],
             [
               'type' => 'field',
               'key' => 'html_type:label',
               'dataType' => 'String',
-              'label' => 'Input Type',
+              'label' => E::ts('Input Type'),
               'sortable' => TRUE,
             ],
             [
               'type' => 'field',
               'key' => 'is_required',
               'dataType' => 'Boolean',
-              'label' => 'Required',
+              'label' => E::ts('Required'),
               'sortable' => TRUE,
               'editable' => TRUE,
             ],
@@ -102,7 +104,7 @@ return [
               'type' => 'field',
               'key' => 'is_active',
               'dataType' => 'Boolean',
-              'label' => 'Enabled',
+              'label' => E::ts('Enabled'),
               'sortable' => TRUE,
               'editable' => TRUE,
             ],
@@ -115,7 +117,7 @@ return [
                   'join' => '',
                   'target' => 'crm-popup',
                   'icon' => 'fa-pencil',
-                  'text' => 'Edit Field',
+                  'text' => E::ts('Edit Field'),
                   'style' => 'default',
                   'path' => '',
                   'condition' => [],
@@ -125,7 +127,7 @@ return [
               'alignment' => 'text-right',
             ],
             [
-              'text' => 'Actions',
+              'text' => E::ts('Actions'),
               'style' => 'default',
               'size' => 'btn-xs',
               'icon' => 'fa-bars',
@@ -136,7 +138,7 @@ return [
                   'join' => '',
                   'target' => 'crm-popup',
                   'icon' => 'fa-eye',
-                  'text' => 'Preview Field',
+                  'text' => E::ts('Preview Field'),
                   'style' => 'default',
                   'path' => '',
                   'condition' => [],
@@ -147,7 +149,7 @@ return [
                   'join' => '',
                   'target' => 'crm-popup',
                   'icon' => 'fa-list-ol',
-                  'text' => 'Multiple Choice Options',
+                  'text' => E::ts('Multiple Choice Options'),
                   'style' => 'default',
                   'path' => 'civicrm/admin/custom/group/field/option?reset=1&action=browse&gid=[custom_group_id]&fid=[id]',
                   'condition' => [
@@ -161,7 +163,7 @@ return [
                   'join' => '',
                   'target' => 'crm-popup',
                   'icon' => 'fa-random',
-                  'text' => 'Move Field',
+                  'text' => E::ts('Move Field'),
                   'style' => 'default',
                   'path' => '',
                   'condition' => [],
@@ -172,7 +174,7 @@ return [
                   'join' => '',
                   'target' => 'crm-popup',
                   'icon' => 'fa-trash',
-                  'text' => 'Delete Field',
+                  'text' => E::ts('Delete Field'),
                   'style' => 'danger',
                   'path' => '',
                   'condition' => [],
index dff4856961dee8c739764c28233965bef74bf3a1..7a7a22f9f099630ea00c2830d0ee49e4fe3dc479 100644 (file)
@@ -1,4 +1,6 @@
 <?php
+use CRM_CivicrmAdminUi_ExtensionUtil as E;
+
 return [
   [
     'name' => 'SavedSearch_Administer_Custom_Groups',
@@ -9,7 +11,7 @@ return [
       'version' => 4,
       'values' => [
         'name' => 'Administer_Custom_Groups',
-        'label' => 'Administer Custom Groups',
+        'label' => E::ts('Administer Custom Groups'),
         'form_values' => NULL,
         'search_custom_id' => NULL,
         'api_entity' => 'CustomGroup',
@@ -57,7 +59,7 @@ return [
       'version' => 4,
       'values' => [
         'name' => 'Table',
-        'label' => 'Table',
+        'label' => E::ts('Table'),
         'saved_search_id.name' => 'Administer_Custom_Groups',
         'type' => 'table',
         'settings' => [
@@ -77,21 +79,21 @@ return [
               'type' => 'field',
               'key' => 'id',
               'dataType' => 'String',
-              'label' => 'ID',
+              'label' => E::ts('ID'),
               'sortable' => TRUE,
             ],
             [
               'type' => 'field',
               'key' => 'title',
               'dataType' => 'String',
-              'label' => 'Group Title',
+              'label' => E::ts('Group Title'),
               'sortable' => TRUE,
             ],
             [
               'type' => 'field',
               'key' => 'is_active',
               'dataType' => 'Boolean',
-              'label' => 'Enabled',
+              'label' => E::ts('Enabled'),
               'sortable' => TRUE,
               'editable' => TRUE,
             ],
@@ -99,7 +101,7 @@ return [
               'type' => 'field',
               'key' => 'extends_entity_column_id:label',
               'dataType' => 'Integer',
-              'label' => 'Used for',
+              'label' => E::ts('Used for'),
               'sortable' => TRUE,
               'empty_value' => '[extends:label]',
             ],
@@ -107,7 +109,7 @@ return [
               'type' => 'field',
               'key' => 'style:label',
               'dataType' => 'String',
-              'label' => 'Style',
+              'label' => E::ts('Style'),
               'sortable' => TRUE,
             ],
             [
@@ -119,7 +121,7 @@ return [
                   'join' => '',
                   'target' => '',
                   'icon' => 'fa-list-alt',
-                  'text' => 'Fields ([COUNT_CustomGroup_CustomField_custom_group_id_01_id])',
+                  'text' => E::ts('Fields (%1)', [1 => '[COUNT_CustomGroup_CustomField_custom_group_id_01_id]']),
                   'style' => 'default',
                   'path' => 'civicrm/admin/custom/group/fields#/?gid=[id]',
                 ],
@@ -129,7 +131,7 @@ return [
                   'join' => '',
                   'target' => 'crm-popup',
                   'icon' => 'fa-pencil',
-                  'text' => 'Settings',
+                  'text' => E::ts('Settings'),
                   'style' => 'default',
                 ],
               ],
@@ -148,7 +150,7 @@ return [
                   'join' => '',
                   'target' => 'crm-popup',
                   'icon' => 'fa-eye',
-                  'text' => 'Preview Group',
+                  'text' => E::ts('Preview Group'),
                   'style' => 'default',
                 ],
                 [
@@ -157,7 +159,7 @@ return [
                   'join' => '',
                   'target' => 'crm-popup',
                   'icon' => 'fa-trash',
-                  'text' => 'Delete Group',
+                  'text' => E::ts('Delete Group'),
                   'style' => 'danger',
                 ],
               ],