minor tidies
authorEileen McNaughton <eileen@fuzion.co.nz>
Thu, 15 Jan 2015 06:58:23 +0000 (19:58 +1300)
committerEileen McNaughton <eileen@fuzion.co.nz>
Thu, 15 Jan 2015 06:58:23 +0000 (19:58 +1300)
12 files changed:
CRM/Activity/BAO/Activity.php
CRM/Admin/Form/Setting.php
CRM/Campaign/Form/Gotv.php
CRM/Contact/BAO/Contact.php
CRM/Contact/Form/RelatedContact.php
CRM/Contact/Form/Task.php
CRM/Contact/Selector/Custom.php
CRM/Core/Controller/Simple.php
CRM/Core/QuickForm/Action/Upload.php
CRM/Dedupe/BAO/QueryBuilder/IndividualSupervised.php
CRM/Event/Form/Task/Email.php
CRM/SMS/Form/Provider.php

index 0c65ba6c76819ad1f631a0b81f3931d1f86ea22e..4e39db2618ed1499ac09350d1bc78e0b20126c94 100644 (file)
@@ -1494,7 +1494,7 @@ LEFT JOIN civicrm_activity_contact src ON (src.activity_id = ac.activity_id AND
   }
 
   /**
-   * Send the sms message to a specific contact
+   * Send the sms message to a specific contact.
    *
    * @param int $toID
    *   The contact id of the recipient.
@@ -1568,7 +1568,7 @@ LEFT JOIN civicrm_activity_contact src ON (src.activity_id = ac.activity_id AND
   }
 
   /**
-   * Send the message to a specific contact
+   * Send the message to a specific contact.
    *
    * @param string $from
    *   The name and email of the sender.
index 6ab1d92e4646ac022b885414f83c47ebd9e34182..094d00ae6dc6ea8228223c8a7175342d27e273dc 100644 (file)
@@ -85,11 +85,11 @@ class CRM_Admin_Form_Setting extends CRM_Core_Form {
 
       //Set defaults for autocomplete and contact reference options
       $this->_defaults['autocompleteContactSearch'] = array(
-          '1' => 1,
-        ) + $autoSearchFields;
+        '1' => 1,
+      ) + $autoSearchFields;
       $this->_defaults['autocompleteContactReference'] = array(
-          '1' => 1,
-        ) + $cRSearchFields;
+        '1' => 1,
+      ) + $cRSearchFields;
 
       // we can handle all the ones defined in the metadata here. Others to be converted
       foreach ($this->_settings as $setting => $group) {
@@ -173,6 +173,10 @@ class CRM_Admin_Form_Setting extends CRM_Core_Form {
   }
 
   /**
+   * Common Process.
+   *
+   * @todo Document what I do.
+   *
    * @param array $params
    */
   public function commonProcess(&$params) {
index e1c563cbde9d09dd93359eb0ba8c0e23aab45c32..169f0b48d0b225419d54c344139c9f897febd9b0 100755 (executable)
@@ -93,10 +93,7 @@ class CRM_Campaign_Form_Gotv extends CRM_Core_Form {
   }
 
   /**
-   * Build the form object
-   *
-   *
-   * @return void
+   * Build the form object.
    */
   public function buildQuickForm() {
     if ($this->_search) {
index d49f64cd7e71be0c8b7e3483557ac251ea0a99b8..bdd35b0cd15fae5971c6834c967be8669856d63c 100644 (file)
@@ -536,6 +536,7 @@ WHERE     civicrm_contact.id = " . CRM_Utils_Type::escape($id, 'Integer');
   public function createDefaultCrudLink($crudLinkSpec) {
     switch ($crudLinkSpec['action']) {
       case CRM_Core_Action::VIEW:
+
         return array(
           'title' => $this->display_name,
           'path' => 'civicrm/contact/view',
@@ -1177,7 +1178,7 @@ WHERE id={$id}; ";
    * @return array
    *   array of importable Fields
    */
-  static function importableFields(
+  public static function importableFields(
     $contactType = 'Individual',
     $status = FALSE,
     $showAll = FALSE,
@@ -1401,8 +1402,14 @@ WHERE id={$id}; ";
       if (!$fields) {
         $fields = CRM_Contact_DAO_Contact::export();
 
-        // the fields are meant for contact types
-        if (in_array($contactType, array('Individual', 'Household', 'Organization', 'All'))) {
+        // The fields are meant for contact types.
+        if (in_array($contactType, array(
+          'Individual',
+          'Household',
+          'Organization',
+          'All',
+          )
+        )) {
           $fields = array_merge($fields, CRM_Core_OptionValue::getFields('', $contactType));
         }
         // add current employer for individuals
@@ -1615,8 +1622,8 @@ WHERE id={$id}; ";
 
     $returnProperties = self::makeHierReturnProperties($fields, $contactId);
 
-    // We don't know the contents of return properties, but we need the lower level ids of the contact
-    // so add a few fields.
+    // We don't know the contents of return properties, but we need the lower
+    // level ids of the contact so add a few fields.
     $returnProperties['first_name'] =
     $returnProperties['organization_name'] =
     $returnProperties['household_name'] =
index 3ba4ceee78da0af5f6b215f95042aa89cd0ad8a0..33c301d0b66c63bf9c280ba86848557e5064c66d 100644 (file)
@@ -99,11 +99,10 @@ class CRM_Contact_Form_RelatedContact extends CRM_Core_Form {
   }
 
   /**
-   * Set default values for the form. Note that in edit/view mode
-   * the default values are retrieved from the database
+   * Set default values for the form.
    *
-   *
-   * @return void
+   * Note that in edit/view mode the default values are retrieved from the
+   * database
    */
   public function setDefaultValues() {
     return $this->_defaults;
index 7bce1b4c08a755a452695be2c74e19fc2cad9685..a8070022e3f5020437de1972968c5d40734b5483 100644 (file)
@@ -340,7 +340,7 @@ class CRM_Contact_Form_Task extends CRM_Core_Form {
   }
 
   /**
-   * Build the form object
+   * Build the form object.
    */
   public function buildQuickForm() {
     $this->addDefaultButtons(ts('Confirm Action'));
@@ -381,10 +381,8 @@ class CRM_Contact_Form_Task extends CRM_Core_Form {
 
   /**
    * Replace ids of household members in $this->_contactIds with the id of their household.
-   * CRM-8338
-   *
    *
-   * @return void
+   * CRM-8338
    */
   public function mergeContactIdsByHousehold() {
     if (empty($this->_contactIds)) {
index 54a0f1132a8c89dd2ff31194b1b1582723a94bc1..4a6c9c85a5c56ce42e84d8cd6baffd0411cfb168 100644 (file)
@@ -98,7 +98,7 @@ class CRM_Contact_Selector_Custom extends CRM_Contact_Selector {
   protected $_customSearchClass;
 
   /**
-   * Class constructor
+   * Class constructor.
    *
    * @param $customSearchClass
    * @param array $formValues
@@ -372,8 +372,6 @@ class CRM_Contact_Selector_Custom extends CRM_Contact_Selector {
   /**
    * Given the current formValues, gets the query in local language.
    *
-   * @param array $formValues   submitted formValues
-   *
    * @return array
    *   which contains an array of strings
    */
@@ -382,6 +380,8 @@ class CRM_Contact_Selector_Custom extends CRM_Contact_Selector {
   }
 
   /**
+   * Get summary.
+   *
    * @return mixed
    */
   public function getSummary() {
@@ -402,6 +402,8 @@ class CRM_Contact_Selector_Custom extends CRM_Contact_Selector {
   }
 
   /**
+   * Do nothing.
+   *
    * @return null
    */
   public function alphabetQuery() {
index f27d31c05ce30e1dadae3b5cda0cee9c5385fdc3..40c489d1fa6bb604d859106e2af1c1ebcc7b4abc 100644 (file)
@@ -116,7 +116,9 @@ class CRM_Core_Controller_Simple extends CRM_Core_Controller {
   }
 
   /**
-   * @return mixed
+   * Get template file name.
+   *
+   * @return string
    */
   public function getTemplateFileName() {
     // there is only one form here, so should be quite easy
index e36492ab3171b3d003c3530051e741ac0e16da4d..9179f6d025bdc5f3d0ab5c82f24a8781d0865ca8 100644 (file)
@@ -47,7 +47,7 @@ class CRM_Core_QuickForm_Action_Upload extends CRM_Core_QuickForm_Action {
   protected $_uploadDir;
 
   /**
-   * Class constructor
+   * Class constructor.
    *
    * @param object $stateMachine
    *   Reference to state machine object.
@@ -134,6 +134,8 @@ class CRM_Core_QuickForm_Action_Upload extends CRM_Core_QuickForm_Action {
   }
 
   /**
+   * Real perform.
+   *
    * @todo document what I do.
    *
    * @param CRM_Core_Form $page
index fe878ad5b43d947748d1bc7ad154216bc10bd5fa..67ec55e4a3631f009740d7aacde4089ec68b80ca 100644 (file)
@@ -66,9 +66,7 @@ class CRM_Dedupe_BAO_QueryBuilder_IndividualSupervised extends CRM_Dedupe_BAO_Qu
             WHERE contact1.contact_type = 'Individual'
               AND " . self::internalFilters($rg);
     return array(
-      "civicrm_contact.{$rg->name}.{$rg->threshold}" => $query
+      "civicrm_contact.{$rg->name}.{$rg->threshold}" => $query,
     );
   }
 }
-
-;
index d2ab1df0476de7e48a3ddf78aef7af8c6f3d40e2..c95b221868f5d859d2c54ab5387b0ddbe330a280 100644 (file)
@@ -62,7 +62,7 @@ class CRM_Event_Form_Task_Email extends CRM_Event_Form_Task {
   public $_templates = NULL;
 
   /**
-   * Build all the data structures needed to build the form
+   * Build all the data structures needed to build the form.
    */
   public function preProcess() {
     CRM_Contact_Form_Task_EmailCommon::preProcessFromAddress($this);
index 91a15f19491a00c063e802c6ebeaf57cb57eae3f..59ed8bdf02c1a7e00c5b83b177ce8d02bdd0b4b4 100644 (file)
@@ -96,7 +96,7 @@ class CRM_SMS_Form_Provider extends CRM_Core_Form {
 
     $this->addRule('title', ts('This Title already exists in Database.'), 'objectExists', array(
         'CRM_SMS_DAO_Provider',
-        $this->_id
+        $this->_id,
       ));
 
     $this->add('text', 'username', ts('Username'),