DAOs with singular/plural options for entity titles
[civicrm-core.git] / CRM / Contribute / DAO / Contribution.php
index d40a175b96d7ab4c6f73b56fe5121a0c1cbc0a3d..174e9bf69591ed243117ec5f61e0137dac46330c 100644 (file)
@@ -6,7 +6,7 @@
  *
  * Generated from xml/schema/CRM/Contribute/Contribution.xml
  * DO NOT EDIT.  Generated by CRM_Core_CodeGen
- * (GenCodeChecksum:534963bc67ddc36a182ff4767f223531)
+ * (GenCodeChecksum:d937ea0497be1a1aeb1bac09986dd802)
  */
 
 /**
@@ -252,9 +252,12 @@ class CRM_Contribute_DAO_Contribution extends CRM_Core_DAO {
 
   /**
    * Returns localized title of this entity.
+   *
+   * @param bool $plural
+   *   Whether to return the plural version of the title.
    */
-  public static function getEntityTitle() {
-    return ts('Contributions');
+  public static function getEntityTitle($plural = FALSE) {
+    return $plural ? ts('Contributions') : ts('Contribution');
   }
 
   /**
@@ -327,7 +330,7 @@ class CRM_Contribute_DAO_Contribution extends CRM_Core_DAO {
         'financial_type_id' => [
           'name' => 'financial_type_id',
           'type' => CRM_Utils_Type::T_INT,
-          'title' => ts('Financial Type'),
+          'title' => ts('Financial Type ID'),
           'description' => ts('FK to Financial Type for (total_amount - non_deductible_amount).'),
           'where' => 'civicrm_contribution.financial_type_id',
           'export' => TRUE,
@@ -338,6 +341,7 @@ class CRM_Contribute_DAO_Contribution extends CRM_Core_DAO {
           'FKClassName' => 'CRM_Financial_DAO_FinancialType',
           'html' => [
             'type' => 'Select',
+            'label' => ts("Financial Type"),
           ],
           'pseudoconstant' => [
             'table' => 'civicrm_financial_type',