Translate hardcoded labels passed to setTitle
authorBradley Taylor <hello@brad-taylor.co.uk>
Sat, 23 Oct 2021 10:52:00 +0000 (11:52 +0100)
committerBradley Taylor <hello@brad-taylor.co.uk>
Sat, 23 Oct 2021 10:52:00 +0000 (11:52 +0100)
15 files changed:
CRM/ACL/Form/WordPress/Permissions.php
CRM/Activity/Form/Task/PDF.php
CRM/Contact/Form/Task/PDFLetterCommon.php
CRM/Contact/Form/Task/PDFTrait.php
CRM/Core/Form/Task/PDFLetterCommon.php
ext/legacycustomsearches/CRM/Contact/Form/Search/Custom/ActivitySearch.php
ext/legacycustomsearches/CRM/Contact/Form/Search/Custom/ContribSYBNT.php
ext/legacycustomsearches/CRM/Contact/Form/Search/Custom/ContributionAggregate.php
ext/legacycustomsearches/CRM/Contact/Form/Search/Custom/DateAdded.php
ext/legacycustomsearches/CRM/Contact/Form/Search/Custom/EventAggregate.php
ext/legacycustomsearches/CRM/Contact/Form/Search/Custom/MultipleValues.php
ext/legacycustomsearches/CRM/Contact/Form/Search/Custom/PriceSet.php
ext/legacycustomsearches/CRM/Contact/Form/Search/Custom/Proximity.php
ext/legacycustomsearches/CRM/Contact/Form/Search/Custom/TagContributions.php
ext/legacycustomsearches/CRM/Contact/Form/Search/Custom/ZipCodeRange.php

index 6c49a0037a4a63f149c095c9ba0fc6ae077dc829..5839aaf0a30c432f33f3ef02583493950f50316e 100644 (file)
@@ -30,7 +30,7 @@ class CRM_ACL_Form_WordPress_Permissions extends CRM_Core_Form {
    */
   public function buildQuickForm() {
 
-    $this->setTitle('WordPress Access Control');
+    $this->setTitle(ts('WordPress Access Control'));
 
     // Get the core permissions array
     $permissionsArray = self::getPermissionArray();
index 8a7cd7abb0ddfe044fd086d9711284e0dc9d5591..e7a4441bad73627db890171a355e06cc1e5831e1 100644 (file)
@@ -23,7 +23,7 @@ class CRM_Activity_Form_Task_PDF extends CRM_Activity_Form_Task {
    */
   public function preProcess(): void {
     parent::preProcess();
-    $this->setTitle('Print/Merge Document');
+    $this->setTitle(ts('Print/Merge Document'));
   }
 
   /**
index f49ab98d517ae75ffa8753b2790fae598cfedf4c..bae7d601a7825b0bf53a4f375063cbea0d62d7e4 100644 (file)
@@ -55,7 +55,7 @@ class CRM_Contact_Form_Task_PDFLetterCommon extends CRM_Core_Form_Task_PDFLetter
       $defaults['from_email_address'] = current(CRM_Core_BAO_Domain::getNameAndEmail(FALSE, TRUE));
     }
     $form->setDefaults($defaults);
-    $form->setTitle('Print/Merge Document');
+    $form->setTitle(ts('Print/Merge Document'));
   }
 
   /**
index 8a3146c8d8b949053926096e6e39810bbcb40101..c562e04d8bf831bfa9dce0a50f6ad7d5bfea4e17 100644 (file)
@@ -179,7 +179,7 @@ trait CRM_Contact_Form_Task_PDFTrait {
       $defaults['from_email_address'] = current(CRM_Core_BAO_Domain::getNameAndEmail(FALSE, TRUE));
     }
     $form->setDefaults($defaults);
-    $form->setTitle('Print/Merge Document');
+    $form->setTitle(ts('Print/Merge Document'));
   }
 
   /**
index f3774ce75ba4ebda48cc6e87f2be1514f4dc98c1..bd3537371fba8e878bafc032029016760d0450d8 100644 (file)
@@ -36,7 +36,7 @@ class CRM_Core_Form_Task_PDFLetterCommon {
   public static function preProcess(&$form) {
     CRM_Core_Error::deprecatedFunctionWarning('no alternative');
 
-    $form->setTitle('Print/Merge Document');
+    $form->setTitle(ts('Print/Merge Document'));
   }
 
   /**
index 7c403fd0c1a6ef089cfab08ba0675a7e0d6f9835..890244e583b701fc50f8e376d9e1a38da1c19b57 100644 (file)
@@ -81,7 +81,7 @@ class CRM_Contact_Form_Search_Custom_ActivitySearch extends CRM_Contact_Form_Sea
     /**
      * You can define a custom title for the search form
      */
-    $this->setTitle('Find Latest Activities');
+    $this->setTitle(ts('Find Latest Activities'));
 
     /**
      * Define the search form fields here
index cbd887c39fcaff96984be93fece2adfefa75e109..90b4c4b1417c72f4d51cd0edbc3a7aa07b066bb6 100644 (file)
@@ -95,7 +95,7 @@ class CRM_Contact_Form_Search_Custom_ContribSYBNT extends CRM_Contact_Form_Searc
       );
     }
 
-    $this->setTitle('Contributions made in Year X and not Year Y');
+    $this->setTitle(ts('Contributions made in Year X and not Year Y'));
     // @TODO: Decide on better names for "Exclusion"
     // @TODO: Add rule to ensure that exclusion dates are not in the inclusion range
   }
index 2e640827baae63a559b8ed3577e4b57694e22707..487eb1cf70a44ac364a8cf6bacef6d3c7e7b247b 100644 (file)
@@ -53,7 +53,7 @@ class CRM_Contact_Form_Search_Custom_ContributionAggregate extends CRM_Contact_F
     /**
      * You can define a custom title for the search form
      */
-    $this->setTitle('Find Contributors by Aggregate Totals');
+    $this->setTitle(ts('Find Contributors by Aggregate Totals'));
 
     /**
      * Define the search form fields here
index 2e4877bac7a91eebebc58522de8f025a5e20695b..89d6d5801e427663a30a1c487b8c452c66dec7f3 100644 (file)
@@ -72,7 +72,7 @@ class CRM_Contact_Form_Search_Custom_DateAdded extends CRM_Contact_Form_Search_C
       $select2style
     );
 
-    $this->setTitle('Search by date added to CiviCRM');
+    $this->setTitle(ts('Search by date added to CiviCRM'));
 
     //redirect if group not available for search criteria
     if (count($groups) == 0) {
index af1bd242387b048dd331b84f51968c00382e3dc1..283ae72f07529f1187bcd5c052a5624f225e8859 100644 (file)
@@ -52,7 +52,7 @@ class CRM_Contact_Form_Search_Custom_EventAggregate extends CRM_Contact_Form_Sea
     /**
      * You can define a custom title for the search form
      */
-    $this->setTitle('Find Totals for Events');
+    $this->setTitle(ts('Find Totals for Events'));
 
     /**
      * Define the search form fields here
index fe5d5374cec720810b14a902a20d88676f6e1abc..8f148a5362c5f7911d26e11208ce79de9a53a340 100644 (file)
@@ -85,7 +85,7 @@ class CRM_Contact_Form_Search_Custom_MultipleValues extends CRM_Contact_Form_Sea
    */
   public function buildForm(&$form) {
 
-    $this->setTitle('Multiple Value Custom Group Search and Export');
+    $this->setTitle(ts('Multiple Value Custom Group Search and Export'));
 
     $form->add('text', 'sort_name', ts('Contact Name'), TRUE);
 
index 49b5b32e9544dc91cb135c3db1cb791d6b38c07e..007845840d3baeb68ce738fad7c5ede9e6fd7269 100644 (file)
@@ -198,7 +198,7 @@ AND    p.entity_id    = e.id
     /**
      * You can define a custom title for the search form
      */
-    $this->setTitle('Price Set Export');
+    $this->setTitle(ts('Price Set Export'));
 
     /**
      * if you are using the standard template, this array tells the template what elements
index 11533db374e747421e69d37284c8b8375817bebf..e572e99f5e8bfbeba7d903575252ab04ffbd82eb 100644 (file)
@@ -108,7 +108,7 @@ class CRM_Contact_Form_Search_Custom_Proximity extends CRM_Contact_Form_Search_C
     /**
      * You can define a custom title for the search form
      */
-    $this->setTitle('Proximity Search');
+    $this->setTitle(ts('Proximity Search'));
 
     /**
      * if you are using the standard template, this array tells the template what elements
index a0995d50ad7207a17b857cba8fcec2b30d7eb370..0c69d4899b08fc4a86ac64eff7e3403df0ed096c 100644 (file)
@@ -51,7 +51,7 @@ class CRM_Contact_Form_Search_Custom_TagContributions extends CRM_Contact_Form_S
     /**
      * You can define a custom title for the search form
      */
-    $this->setTitle('Find Contribution Amounts by Tag');
+    $this->setTitle(ts('Find Contribution Amounts by Tag'));
 
     /**
      * Define the search form fields here
index 77dec63eab1a0de57a1c12e1f7ba27c32594fb22..bbbb2e25aed75c4fc8983805ba5174cf8d68d1fb 100644 (file)
@@ -60,7 +60,7 @@ class CRM_Contact_Form_Search_Custom_ZipCodeRange extends CRM_Contact_Form_Searc
     /**
      * You can define a custom title for the search form
      */
-    $this->setTitle('Zip Code Range Search');
+    $this->setTitle(ts('Zip Code Range Search'));
 
     /**
      * if you are using the standard template, this array tells the template what elements