From 62d3ee279943eae74d2f4d5797f8bb3b3fcbfa5a Mon Sep 17 00:00:00 2001 From: Seamus Lee Date: Mon, 8 Apr 2019 07:24:06 +1000 Subject: [PATCH] (NFC) Update CRM/Activity CRM/Admin and CRM/Batch folders to be the future coder standard --- CRM/Activity/BAO/Activity.php | 6 +++--- CRM/Activity/BAO/ActivityContact.php | 6 +++--- CRM/Activity/BAO/Query.php | 1 + CRM/Activity/Form/Activity.php | 7 +++++-- CRM/Activity/Form/ActivityFilter.php | 1 + CRM/Activity/Form/ActivityLinks.php | 1 + CRM/Activity/Form/Search.php | 1 + CRM/Activity/Form/Task/Batch.php | 2 ++ CRM/Activity/Form/Task/FileOnCase.php | 2 ++ CRM/Activity/Form/Task/PickOption.php | 3 +++ CRM/Activity/Form/Task/PickProfile.php | 2 ++ CRM/Activity/Import/Field.php | 1 + CRM/Activity/Import/Form/MapField.php | 1 - CRM/Activity/Import/Parser.php | 5 +++++ CRM/Activity/Import/Parser/Activity.php | 2 +- CRM/Activity/Page/AJAX.php | 2 +- CRM/Activity/Selector/Activity.php | 2 +- CRM/Activity/Selector/Search.php | 6 +++--- CRM/Activity/Task.php | 2 +- CRM/Activity/Tokens.php | 3 +-- CRM/Admin/Form/LabelFormats.php | 2 ++ CRM/Admin/Form/MessageTemplates.php | 10 ++++++++-- CRM/Admin/Form/Navigation.php | 1 + CRM/Admin/Form/PaymentProcessor.php | 5 +++-- CRM/Admin/Form/PdfFormats.php | 1 + CRM/Admin/Form/ScheduleReminders.php | 1 + CRM/Admin/Form/Setting/Localization.php | 2 -- CRM/Admin/Form/SettingTrait.php | 2 ++ CRM/Admin/Page/AJAX.php | 10 +++++----- CRM/Admin/Page/APIExplorer.php | 1 - CRM/Admin/Page/Access.php | 1 + CRM/Admin/Page/Admin.php | 1 + CRM/Admin/Page/CKEditorConfig.php | 1 + CRM/Admin/Page/ConfigTaskList.php | 1 + CRM/Admin/Page/ContactType.php | 2 +- CRM/Admin/Page/EventTemplate.php | 2 +- CRM/Admin/Page/Extensions.php | 2 +- CRM/Admin/Page/Job.php | 2 +- CRM/Admin/Page/JobLog.php | 2 +- CRM/Admin/Page/LabelFormats.php | 2 +- CRM/Admin/Page/LocationType.php | 2 +- CRM/Admin/Page/MailSettings.php | 2 +- CRM/Admin/Page/Mapping.php | 2 +- CRM/Admin/Page/MessageTemplates.php | 12 +++++++++--- CRM/Admin/Page/Navigation.php | 2 +- CRM/Admin/Page/Options.php | 10 +++++----- CRM/Admin/Page/PaymentProcessor.php | 2 +- CRM/Admin/Page/PaymentProcessorType.php | 2 +- CRM/Admin/Page/PdfFormats.php | 2 +- CRM/Admin/Page/PreferencesDate.php | 2 +- CRM/Admin/Page/RelationshipType.php | 2 +- CRM/Admin/Page/ScheduleReminders.php | 2 +- CRM/Admin/Page/Setting.php | 1 + CRM/Batch/BAO/Batch.php | 7 ++++--- CRM/Batch/Form/Entry.php | 7 +++++++ CRM/Batch/Form/Search.php | 1 + CRM/Batch/Page/Batch.php | 2 +- 57 files changed, 109 insertions(+), 58 deletions(-) diff --git a/CRM/Activity/BAO/Activity.php b/CRM/Activity/BAO/Activity.php index e454ef229e..af4961d5ab 100644 --- a/CRM/Activity/BAO/Activity.php +++ b/CRM/Activity/BAO/Activity.php @@ -49,14 +49,14 @@ class CRM_Activity_BAO_Activity extends CRM_Activity_DAO_Activity { * * @var array */ - static $_exportableFields = NULL; + public static $_exportableFields = NULL; /** * Static field for all the activity information that we can potentially import. * * @var array */ - static $_importableFields = NULL; + public static $_importableFields = NULL; /** * Check if there is absolute minimum of data to add the object. @@ -901,7 +901,7 @@ class CRM_Activity_BAO_Activity extends CRM_Activity_DAO_Activity { * that this concept might be extended later. In practice most places that * call this then re-add CiviCase in some way so it's all a bit... odd. * - * @return array Array of component id and name. + * @return array * Array of component id and name. */ public static function activityComponents($excludeComponentHandledActivities = TRUE) { diff --git a/CRM/Activity/BAO/ActivityContact.php b/CRM/Activity/BAO/ActivityContact.php index f12a86b205..7039fba2f1 100644 --- a/CRM/Activity/BAO/ActivityContact.php +++ b/CRM/Activity/BAO/ActivityContact.php @@ -147,9 +147,9 @@ AND civicrm_contact.is_deleted = 0 * @see DB_DataObject::getLink() * * @return array|null - * array = if there are links defined for this table. - * empty array - if there is a links.ini file, but no links on this table - * null - if no links.ini exists for this database (hence try auto_links). + * array if there are links defined for this table. + * empty array - if there is a links.ini file, but no links on this table + * null - if no links.ini exists for this database (hence try auto_links). */ public function links() { $link = ['activity_id' => 'civicrm_activity:id']; diff --git a/CRM/Activity/BAO/Query.php b/CRM/Activity/BAO/Query.php index 8851d2fe35..8f7cd076b8 100644 --- a/CRM/Activity/BAO/Query.php +++ b/CRM/Activity/BAO/Query.php @@ -673,6 +673,7 @@ class CRM_Activity_BAO_Query { * Where/qill clause for notes * * @param array $values + * @param object $query */ public static function whereClauseSingleActivityText(&$values, &$query) { list($name, $op, $value, $grouping, $wildcard) = $values; diff --git a/CRM/Activity/Form/Activity.php b/CRM/Activity/Form/Activity.php index 7fffdb7cd5..680188871e 100644 --- a/CRM/Activity/Form/Activity.php +++ b/CRM/Activity/Form/Activity.php @@ -119,7 +119,8 @@ class CRM_Activity_Form_Activity extends CRM_Contact_Form_Task { protected $unsavedWarn = TRUE; - /* + /** + * * Is it possible to create separate activities with this form? * * When TRUE, the form will ask whether the user wants to create separate @@ -133,7 +134,9 @@ class CRM_Activity_Form_Activity extends CRM_Contact_Form_Task { * behavior (e.g. in CRM_Case_Form_Activity) * * @var boolean + * */ + protected $supportsActivitySeparation = TRUE; /** @@ -826,7 +829,7 @@ class CRM_Activity_Form_Activity extends CRM_Contact_Form_Task { $doNotNotifyAssigneeFor = (array) Civi::settings() ->get('do_not_notify_assignees_for'); if (($this->_activityTypeId && in_array($this->_activityTypeId, $doNotNotifyAssigneeFor)) || !Civi::settings() - ->get('activity_assignee_notification')) { + ->get('activity_assignee_notification')) { $this->assign('activityAssigneeNotification', FALSE); } else { diff --git a/CRM/Activity/Form/ActivityFilter.php b/CRM/Activity/Form/ActivityFilter.php index 228a4c21f0..472c5b542c 100644 --- a/CRM/Activity/Form/ActivityFilter.php +++ b/CRM/Activity/Form/ActivityFilter.php @@ -35,6 +35,7 @@ * This class generates form components for Activity Filter. */ class CRM_Activity_Form_ActivityFilter extends CRM_Core_Form { + public function buildQuickForm() { // add activity search filter $activityOptions = CRM_Core_PseudoConstant::activityType(TRUE, TRUE, FALSE, 'label', TRUE); diff --git a/CRM/Activity/Form/ActivityLinks.php b/CRM/Activity/Form/ActivityLinks.php index 1bbdd423f3..36a27d14b3 100644 --- a/CRM/Activity/Form/ActivityLinks.php +++ b/CRM/Activity/Form/ActivityLinks.php @@ -35,6 +35,7 @@ * This class generates form components for Activity Links. */ class CRM_Activity_Form_ActivityLinks extends CRM_Core_Form { + public function buildQuickForm() { self::commonBuildQuickForm($this); } diff --git a/CRM/Activity/Form/Search.php b/CRM/Activity/Form/Search.php index a44b314c6c..4aa16252d5 100644 --- a/CRM/Activity/Form/Search.php +++ b/CRM/Activity/Form/Search.php @@ -59,6 +59,7 @@ class CRM_Activity_Form_Search extends CRM_Core_Form_Search { /** * Prefix for the controller. + * @var string */ protected $_prefix = "activity_"; diff --git a/CRM/Activity/Form/Task/Batch.php b/CRM/Activity/Form/Task/Batch.php index b8cd458e10..9bdb768b8b 100644 --- a/CRM/Activity/Form/Task/Batch.php +++ b/CRM/Activity/Form/Task/Batch.php @@ -45,11 +45,13 @@ class CRM_Activity_Form_Task_Batch extends CRM_Activity_Form_Task { /** * Maximum profile fields that will be displayed. + * @var int */ protected $_maxFields = 9; /** * Variable to store redirect path. + * @var string */ protected $_userContext; diff --git a/CRM/Activity/Form/Task/FileOnCase.php b/CRM/Activity/Form/Task/FileOnCase.php index 893012b15c..dd4d2ebb3a 100644 --- a/CRM/Activity/Form/Task/FileOnCase.php +++ b/CRM/Activity/Form/Task/FileOnCase.php @@ -45,11 +45,13 @@ class CRM_Activity_Form_Task_FileOnCase extends CRM_Activity_Form_Task { /** * Variable to store redirect path. + * @var string */ protected $_userContext; /** * Variable to store contact Ids. + * @var array */ public $_contacts; diff --git a/CRM/Activity/Form/Task/PickOption.php b/CRM/Activity/Form/Task/PickOption.php index df4e59f5a4..bef28a6b3b 100644 --- a/CRM/Activity/Form/Task/PickOption.php +++ b/CRM/Activity/Form/Task/PickOption.php @@ -45,16 +45,19 @@ class CRM_Activity_Form_Task_PickOption extends CRM_Activity_Form_Task { /** * Maximum Activities that should be allowed to update. + * @var int */ protected $_maxActivities = 100; /** * Variable to store redirect path. + * @var int */ protected $_userContext; /** * Variable to store contact Ids. + * @var array */ public $_contacts; diff --git a/CRM/Activity/Form/Task/PickProfile.php b/CRM/Activity/Form/Task/PickProfile.php index 10f258837c..1221a21c4a 100644 --- a/CRM/Activity/Form/Task/PickProfile.php +++ b/CRM/Activity/Form/Task/PickProfile.php @@ -45,11 +45,13 @@ class CRM_Activity_Form_Task_PickProfile extends CRM_Activity_Form_Task { /** * Maximum Activities that should be allowed to update. + * @var int */ protected $_maxActivities = 100; /** * Variable to store redirect path. + * @var string */ protected $_userContext; diff --git a/CRM/Activity/Import/Field.php b/CRM/Activity/Import/Field.php index b36bdd7dc4..b19a6002de 100644 --- a/CRM/Activity/Import/Field.php +++ b/CRM/Activity/Import/Field.php @@ -40,6 +40,7 @@ class CRM_Activity_Import_Field { /** * Title of the field to be used in display + * @var string */ public $_title; diff --git a/CRM/Activity/Import/Form/MapField.php b/CRM/Activity/Import/Form/MapField.php index f2f59dc04f..2b2e78053b 100644 --- a/CRM/Activity/Import/Form/MapField.php +++ b/CRM/Activity/Import/Form/MapField.php @@ -36,7 +36,6 @@ */ class CRM_Activity_Import_Form_MapField extends CRM_Import_Form_MapField { - /** * Set variables up before form is built. */ diff --git a/CRM/Activity/Import/Parser.php b/CRM/Activity/Import/Parser.php index aca1639857..fc4aca0c20 100644 --- a/CRM/Activity/Import/Parser.php +++ b/CRM/Activity/Import/Parser.php @@ -36,16 +36,19 @@ abstract class CRM_Activity_Import_Parser extends CRM_Import_Parser { /** * Imported file size. + * @var int */ protected $_fileSize; /** * Separator being used. + * @var string */ protected $_seperator; /** * Total number of lines in file. + * @var int */ protected $_lineCount; @@ -63,6 +66,8 @@ abstract class CRM_Activity_Import_Parser extends CRM_Import_Parser { * @param bool $skipColumnHeader * @param int $mode * @param int $onDuplicate + * @param int $statusID + * @param int $totalRowCount * * @return mixed * @throws Exception diff --git a/CRM/Activity/Import/Parser/Activity.php b/CRM/Activity/Import/Parser/Activity.php index fbb3c61497..de829240c3 100644 --- a/CRM/Activity/Import/Parser/Activity.php +++ b/CRM/Activity/Import/Parser/Activity.php @@ -47,7 +47,7 @@ class CRM_Activity_Import_Parser_Activity extends CRM_Activity_Import_Parser { /** * Array of successfully imported activity id's * - * @array + * @var array */ protected $_newActivity; diff --git a/CRM/Activity/Page/AJAX.php b/CRM/Activity/Page/AJAX.php index f96c4c0938..1da789c273 100644 --- a/CRM/Activity/Page/AJAX.php +++ b/CRM/Activity/Page/AJAX.php @@ -36,6 +36,7 @@ * This class contains all the function that are called using AJAX (jQuery) */ class CRM_Activity_Page_AJAX { + public static function getCaseActivity() { // Should those params be passed through the validateParams method? $caseID = CRM_Utils_Type::validate($_GET['caseID'], 'Integer'); @@ -143,7 +144,6 @@ class CRM_Activity_Page_AJAX { CRM_Utils_JSON::output($clientRelationshipsDT); } - public static function getCaseRoles() { $caseID = CRM_Utils_Type::escape($_GET['caseID'], 'Integer'); $contactID = CRM_Utils_Type::escape($_GET['cid'], 'Integer'); diff --git a/CRM/Activity/Selector/Activity.php b/CRM/Activity/Selector/Activity.php index befd1effda..e03072dbdd 100644 --- a/CRM/Activity/Selector/Activity.php +++ b/CRM/Activity/Selector/Activity.php @@ -41,7 +41,7 @@ class CRM_Activity_Selector_Activity extends CRM_Core_Selector_Base implements C * * @var array */ - static $_columnHeaders; + public static $_columnHeaders; /** * ContactId - contact id of contact whose activies are displayed diff --git a/CRM/Activity/Selector/Search.php b/CRM/Activity/Selector/Search.php index f690f1bc53..8a21dde81f 100644 --- a/CRM/Activity/Selector/Search.php +++ b/CRM/Activity/Selector/Search.php @@ -43,21 +43,21 @@ class CRM_Activity_Selector_Search extends CRM_Core_Selector_Base implements CRM * * @var array */ - static $_links = NULL; + public static $_links = NULL; /** * We use desc to remind us what that column is, name is used in the tpl * * @var array */ - static $_columnHeaders; + public static $_columnHeaders; /** * Properties of contact we're interested in displaying * @var array */ - static $_properties = [ + public static $_properties = [ 'contact_id', 'contact_type', 'contact_sub_type', diff --git a/CRM/Activity/Task.php b/CRM/Activity/Task.php index bcd4cc804e..00bfcbffd9 100644 --- a/CRM/Activity/Task.php +++ b/CRM/Activity/Task.php @@ -35,7 +35,7 @@ */ class CRM_Activity_Task extends CRM_Core_Task { - static $objectType = 'activity'; + public static $objectType = 'activity'; /** * These tasks are the core set of tasks that the user can perform diff --git a/CRM/Activity/Tokens.php b/CRM/Activity/Tokens.php index ebb83d02f1..3271b96592 100644 --- a/CRM/Activity/Tokens.php +++ b/CRM/Activity/Tokens.php @@ -60,8 +60,7 @@ class CRM_Activity_Tokens extends \Civi\Token\AbstractTokenSubscriber { */ public function checkActive(\Civi\Token\TokenProcessor $processor) { // Extracted from scheduled-reminders code. See the class description. - return - !empty($processor->context['actionMapping']) + return !empty($processor->context['actionMapping']) && $processor->context['actionMapping']->getEntity() === 'civicrm_activity'; } diff --git a/CRM/Admin/Form/LabelFormats.php b/CRM/Admin/Form/LabelFormats.php index 0a829c6889..6e3ad025df 100644 --- a/CRM/Admin/Form/LabelFormats.php +++ b/CRM/Admin/Form/LabelFormats.php @@ -39,11 +39,13 @@ class CRM_Admin_Form_LabelFormats extends CRM_Admin_Form { /** * Label Format ID. + * @var int */ protected $_id = NULL; /** * Group name, label format or name badge + * @var string */ protected $_group = NULL; diff --git a/CRM/Admin/Form/MessageTemplates.php b/CRM/Admin/Form/MessageTemplates.php index 8ff7528fda..06f0259ec9 100644 --- a/CRM/Admin/Form/MessageTemplates.php +++ b/CRM/Admin/Form/MessageTemplates.php @@ -36,10 +36,16 @@ * used by membership, contributions, event registrations, etc. */ class CRM_Admin_Form_MessageTemplates extends CRM_Admin_Form { - // which (and whether) mailing workflow this template belongs to + /** + * which (and whether) mailing workflow this template belongs to + * @var int + */ protected $_workflow_id = NULL; - // Is document file is already loaded as default value? + /** + * Is document file is already loaded as default value? + * @var bool + */ protected $_is_document = FALSE; public function preProcess() { diff --git a/CRM/Admin/Form/Navigation.php b/CRM/Admin/Form/Navigation.php index 370d0cdff7..cf885742b5 100644 --- a/CRM/Admin/Form/Navigation.php +++ b/CRM/Admin/Form/Navigation.php @@ -38,6 +38,7 @@ class CRM_Admin_Form_Navigation extends CRM_Admin_Form { /** * The parent id of the navigation menu. + * @var int */ protected $_currentParentID = NULL; diff --git a/CRM/Admin/Form/PaymentProcessor.php b/CRM/Admin/Form/PaymentProcessor.php index aef46cc304..d8b3293955 100644 --- a/CRM/Admin/Form/PaymentProcessor.php +++ b/CRM/Admin/Form/PaymentProcessor.php @@ -44,7 +44,8 @@ class CRM_Admin_Form_PaymentProcessor extends CRM_Admin_Form { protected $_paymentProcessorDAO; /** - * @var int $_paymentProcessorType Payment processor Type ID + * @var int + * Payment processor Type ID */ protected $_paymentProcessorType; @@ -448,7 +449,7 @@ class CRM_Admin_Form_PaymentProcessor extends CRM_Admin_Form { else { $creditCards = "NULL"; } - $params = array_merge([ + $params = array_merge([ 'id' => $test ? $this->_testID : $this->_id, 'domain_id' => $domainID, 'is_test' => $test, diff --git a/CRM/Admin/Form/PdfFormats.php b/CRM/Admin/Form/PdfFormats.php index 94e29cbf03..ea8e7c40c9 100644 --- a/CRM/Admin/Form/PdfFormats.php +++ b/CRM/Admin/Form/PdfFormats.php @@ -39,6 +39,7 @@ class CRM_Admin_Form_PdfFormats extends CRM_Admin_Form { /** * PDF Page Format ID. + * @var int */ protected $_id = NULL; diff --git a/CRM/Admin/Form/ScheduleReminders.php b/CRM/Admin/Form/ScheduleReminders.php index c7c89716fd..38e425bfd5 100644 --- a/CRM/Admin/Form/ScheduleReminders.php +++ b/CRM/Admin/Form/ScheduleReminders.php @@ -38,6 +38,7 @@ class CRM_Admin_Form_ScheduleReminders extends CRM_Admin_Form { /** * Scheduled Reminder ID. + * @var int */ protected $_id = NULL; diff --git a/CRM/Admin/Form/Setting/Localization.php b/CRM/Admin/Form/Setting/Localization.php index 44829d5504..2940f4136f 100644 --- a/CRM/Admin/Form/Setting/Localization.php +++ b/CRM/Admin/Form/Setting/Localization.php @@ -255,7 +255,6 @@ class CRM_Admin_Form_Setting_Localization extends CRM_Admin_Form_Setting { } } - /** * Replace available currencies by the ones provided * @@ -286,7 +285,6 @@ class CRM_Admin_Form_Setting_Localization extends CRM_Admin_Form_Setting { } - /** * @return array */ diff --git a/CRM/Admin/Form/SettingTrait.php b/CRM/Admin/Form/SettingTrait.php index b1b1cd31a4..6a056a95f8 100644 --- a/CRM/Admin/Form/SettingTrait.php +++ b/CRM/Admin/Form/SettingTrait.php @@ -119,6 +119,7 @@ trait CRM_Admin_Form_SettingTrait { * e.g get 'serialize' key, if exists, for a field. * * @param $setting + * @param $item * @return mixed */ protected function getSettingMetadataItem($setting, $item) { @@ -294,6 +295,7 @@ trait CRM_Admin_Form_SettingTrait { ]; return $mapping[$htmlType]; } + /** * Get the defaults for all fields defined in the metadata. * diff --git a/CRM/Admin/Page/AJAX.php b/CRM/Admin/Page/AJAX.php index f6dc2edee1..f782de9428 100644 --- a/CRM/Admin/Page/AJAX.php +++ b/CRM/Admin/Page/AJAX.php @@ -300,7 +300,7 @@ class CRM_Admin_Page_AJAX { * * This appears to be only used by scheduled reminders. */ - static public function mappingList() { + public static function mappingList() { if (empty($_GET['mappingID'])) { CRM_Utils_JSON::output(['status' => 'error', 'error_msg' => 'required params missing.']); } @@ -383,10 +383,10 @@ class CRM_Admin_Page_AJAX { } $dao = CRM_Utils_SQL_Select::from('civicrm_tag') - ->where($whereClauses) - ->groupBy('id') - ->orderBy($orderColumn) - ->execute(); + ->where($whereClauses) + ->groupBy('id') + ->orderBy($orderColumn) + ->execute(); while ($dao->fetch()) { if (!empty($substring)) { diff --git a/CRM/Admin/Page/APIExplorer.php b/CRM/Admin/Page/APIExplorer.php index 8414ec8ab3..a1ade427f6 100644 --- a/CRM/Admin/Page/APIExplorer.php +++ b/CRM/Admin/Page/APIExplorer.php @@ -59,7 +59,6 @@ class CRM_Admin_Page_APIExplorer extends CRM_Core_Page { return $paths; } - /** * Run page. * diff --git a/CRM/Admin/Page/Access.php b/CRM/Admin/Page/Access.php index 54b2db56f7..9d016ae5a1 100644 --- a/CRM/Admin/Page/Access.php +++ b/CRM/Admin/Page/Access.php @@ -37,6 +37,7 @@ * For initial version, this page only contains static links - so this class is empty for now. */ class CRM_Admin_Page_Access extends CRM_Core_Page { + /** * @return string */ diff --git a/CRM/Admin/Page/Admin.php b/CRM/Admin/Page/Admin.php index eab28f37aa..f195b5d693 100644 --- a/CRM/Admin/Page/Admin.php +++ b/CRM/Admin/Page/Admin.php @@ -35,6 +35,7 @@ * Page for displaying Administer CiviCRM Control Panel. */ class CRM_Admin_Page_Admin extends CRM_Core_Page { + /** * Run page. * diff --git a/CRM/Admin/Page/CKEditorConfig.php b/CRM/Admin/Page/CKEditorConfig.php index 03f7ec34b0..22f6539913 100644 --- a/CRM/Admin/Page/CKEditorConfig.php +++ b/CRM/Admin/Page/CKEditorConfig.php @@ -245,6 +245,7 @@ class CRM_Admin_Page_CKEditorConfig extends CRM_Core_Page { } /** + * @param string $preset * @param string $contents */ public static function saveConfigFile($preset, $contents) { diff --git a/CRM/Admin/Page/ConfigTaskList.php b/CRM/Admin/Page/ConfigTaskList.php index 416a58d62d..7d43f650e4 100644 --- a/CRM/Admin/Page/ConfigTaskList.php +++ b/CRM/Admin/Page/ConfigTaskList.php @@ -35,6 +35,7 @@ * Page for displaying list of site configuration tasks with links to each setting form. */ class CRM_Admin_Page_ConfigTaskList extends CRM_Core_Page { + /** * Run page. * diff --git a/CRM/Admin/Page/ContactType.php b/CRM/Admin/Page/ContactType.php index 1cfc16a5ad..b7d4dc2af2 100644 --- a/CRM/Admin/Page/ContactType.php +++ b/CRM/Admin/Page/ContactType.php @@ -43,7 +43,7 @@ class CRM_Admin_Page_ContactType extends CRM_Core_Page_Basic { * * @var array */ - static $_links = NULL; + public static $_links = NULL; /** * Get BAO Name. diff --git a/CRM/Admin/Page/EventTemplate.php b/CRM/Admin/Page/EventTemplate.php index 6c6ca7804f..049b4d6566 100644 --- a/CRM/Admin/Page/EventTemplate.php +++ b/CRM/Admin/Page/EventTemplate.php @@ -41,7 +41,7 @@ class CRM_Admin_Page_EventTemplate extends CRM_Core_Page_Basic { * * @var array */ - static $_links = NULL; + public static $_links = NULL; /** * Get BAO Name. diff --git a/CRM/Admin/Page/Extensions.php b/CRM/Admin/Page/Extensions.php index d242c9090b..e190d36f63 100644 --- a/CRM/Admin/Page/Extensions.php +++ b/CRM/Admin/Page/Extensions.php @@ -42,7 +42,7 @@ class CRM_Admin_Page_Extensions extends CRM_Core_Page_Basic { * * @var array */ - static $_links = NULL; + public static $_links = NULL; /** * Obtains the group name from url and sets the title. diff --git a/CRM/Admin/Page/Job.php b/CRM/Admin/Page/Job.php index 059fa9f584..9fdc42cc44 100644 --- a/CRM/Admin/Page/Job.php +++ b/CRM/Admin/Page/Job.php @@ -41,7 +41,7 @@ class CRM_Admin_Page_Job extends CRM_Core_Page_Basic { * * @var array */ - static $_links = NULL; + public static $_links = NULL; /** * Get BAO Name. diff --git a/CRM/Admin/Page/JobLog.php b/CRM/Admin/Page/JobLog.php index e5faee151d..b71ba3ab4d 100644 --- a/CRM/Admin/Page/JobLog.php +++ b/CRM/Admin/Page/JobLog.php @@ -41,7 +41,7 @@ class CRM_Admin_Page_JobLog extends CRM_Core_Page_Basic { * * @var array */ - static $_links = NULL; + public static $_links = NULL; /** * Get BAO Name. diff --git a/CRM/Admin/Page/LabelFormats.php b/CRM/Admin/Page/LabelFormats.php index c90b5eba3d..96b720a3d3 100644 --- a/CRM/Admin/Page/LabelFormats.php +++ b/CRM/Admin/Page/LabelFormats.php @@ -44,7 +44,7 @@ class CRM_Admin_Page_LabelFormats extends CRM_Core_Page_Basic { * * @var array */ - static $_links = NULL; + public static $_links = NULL; /** * Get BAO Name. diff --git a/CRM/Admin/Page/LocationType.php b/CRM/Admin/Page/LocationType.php index 16b2b25df6..f22c00800a 100644 --- a/CRM/Admin/Page/LocationType.php +++ b/CRM/Admin/Page/LocationType.php @@ -43,7 +43,7 @@ class CRM_Admin_Page_LocationType extends CRM_Core_Page_Basic { * * @var array */ - static $_links = NULL; + public static $_links = NULL; /** * Get BAO Name. diff --git a/CRM/Admin/Page/MailSettings.php b/CRM/Admin/Page/MailSettings.php index 94b984a5e9..5a95c855e0 100644 --- a/CRM/Admin/Page/MailSettings.php +++ b/CRM/Admin/Page/MailSettings.php @@ -43,7 +43,7 @@ class CRM_Admin_Page_MailSettings extends CRM_Core_Page_Basic { * * @var array */ - static $_links = NULL; + public static $_links = NULL; /** * Get BAO Name. diff --git a/CRM/Admin/Page/Mapping.php b/CRM/Admin/Page/Mapping.php index 33744306f0..0da215d2cc 100644 --- a/CRM/Admin/Page/Mapping.php +++ b/CRM/Admin/Page/Mapping.php @@ -43,7 +43,7 @@ class CRM_Admin_Page_Mapping extends CRM_Core_Page_Basic { * * @var array */ - static $_links = NULL; + public static $_links = NULL; /** * Get BAO. diff --git a/CRM/Admin/Page/MessageTemplates.php b/CRM/Admin/Page/MessageTemplates.php index 86efc76239..b81a56a0a0 100644 --- a/CRM/Admin/Page/MessageTemplates.php +++ b/CRM/Admin/Page/MessageTemplates.php @@ -41,12 +41,18 @@ class CRM_Admin_Page_MessageTemplates extends CRM_Core_Page_Basic { * * @var array */ - static $_links = NULL; + public static $_links = NULL; - // ids of templates which diverted from the default ones and can be reverted + /** + * ids of templates which diverted from the default ones and can be reverted + * @var array + */ protected $_revertible = []; - // set to the id that we’re reverting at the given moment (if we are) + /** + * set to the id that we’re reverting at the given moment (if we are) + * @var int + */ protected $_revertedId; /** diff --git a/CRM/Admin/Page/Navigation.php b/CRM/Admin/Page/Navigation.php index eadce454fe..30234dacfc 100644 --- a/CRM/Admin/Page/Navigation.php +++ b/CRM/Admin/Page/Navigation.php @@ -41,7 +41,7 @@ class CRM_Admin_Page_Navigation extends CRM_Core_Page_Basic { * * @var array */ - static $_links = NULL; + public static $_links = NULL; /** * Get BAO Name. diff --git a/CRM/Admin/Page/Options.php b/CRM/Admin/Page/Options.php index cf11d88def..7ba567c047 100644 --- a/CRM/Admin/Page/Options.php +++ b/CRM/Admin/Page/Options.php @@ -43,35 +43,35 @@ class CRM_Admin_Page_Options extends CRM_Core_Page_Basic { * * @var array */ - static $_links = NULL; + public static $_links = NULL; /** * The option group name. * * @var array */ - static $_gName = NULL; + public static $_gName = NULL; /** * The option group name in display format (capitalized, without underscores...etc) * * @var array */ - static $_gLabel = NULL; + public static $_gLabel = NULL; /** * The option group id. * * @var array */ - static $_gId = NULL; + public static $_gId = NULL; /** * A boolean determining if you can add options to this group in the GUI. * * @var boolean */ - static $_isLocked = FALSE; + public static $_isLocked = FALSE; /** * Obtains the group name from url string or id from $_GET['gid']. diff --git a/CRM/Admin/Page/PaymentProcessor.php b/CRM/Admin/Page/PaymentProcessor.php index 4a5142e88a..3ed9836bd1 100644 --- a/CRM/Admin/Page/PaymentProcessor.php +++ b/CRM/Admin/Page/PaymentProcessor.php @@ -41,7 +41,7 @@ class CRM_Admin_Page_PaymentProcessor extends CRM_Core_Page_Basic { * * @var array */ - static $_links = NULL; + public static $_links = NULL; /** * Get BAO Name. diff --git a/CRM/Admin/Page/PaymentProcessorType.php b/CRM/Admin/Page/PaymentProcessorType.php index 212c60e42d..ab366bd54f 100644 --- a/CRM/Admin/Page/PaymentProcessorType.php +++ b/CRM/Admin/Page/PaymentProcessorType.php @@ -41,7 +41,7 @@ class CRM_Admin_Page_PaymentProcessorType extends CRM_Core_Page_Basic { * * @var array */ - static $_links = NULL; + public static $_links = NULL; /** * Get BAO Name. diff --git a/CRM/Admin/Page/PdfFormats.php b/CRM/Admin/Page/PdfFormats.php index ba7b0a2e48..24abb29212 100644 --- a/CRM/Admin/Page/PdfFormats.php +++ b/CRM/Admin/Page/PdfFormats.php @@ -44,7 +44,7 @@ class CRM_Admin_Page_PdfFormats extends CRM_Core_Page_Basic { * * @var array */ - static $_links = NULL; + public static $_links = NULL; /** * Get BAO Name. diff --git a/CRM/Admin/Page/PreferencesDate.php b/CRM/Admin/Page/PreferencesDate.php index f1a65a7698..053d7efb28 100644 --- a/CRM/Admin/Page/PreferencesDate.php +++ b/CRM/Admin/Page/PreferencesDate.php @@ -41,7 +41,7 @@ class CRM_Admin_Page_PreferencesDate extends CRM_Core_Page_Basic { * * @var array */ - static $_links = NULL; + public static $_links = NULL; public $useLivePageJS = TRUE; diff --git a/CRM/Admin/Page/RelationshipType.php b/CRM/Admin/Page/RelationshipType.php index a93f8a70da..8657da7625 100644 --- a/CRM/Admin/Page/RelationshipType.php +++ b/CRM/Admin/Page/RelationshipType.php @@ -43,7 +43,7 @@ class CRM_Admin_Page_RelationshipType extends CRM_Core_Page_Basic { * * @var array */ - static $_links = NULL; + public static $_links = NULL; /** * Get BAO Name. diff --git a/CRM/Admin/Page/ScheduleReminders.php b/CRM/Admin/Page/ScheduleReminders.php index a4edd63958..c87d5c654e 100644 --- a/CRM/Admin/Page/ScheduleReminders.php +++ b/CRM/Admin/Page/ScheduleReminders.php @@ -43,7 +43,7 @@ class CRM_Admin_Page_ScheduleReminders extends CRM_Core_Page_Basic { * * @var array */ - static $_links = NULL; + public static $_links = NULL; /** * Get BAO Name. diff --git a/CRM/Admin/Page/Setting.php b/CRM/Admin/Page/Setting.php index 35ba64de4b..0f747b58c1 100644 --- a/CRM/Admin/Page/Setting.php +++ b/CRM/Admin/Page/Setting.php @@ -35,6 +35,7 @@ * Page for displaying list of categories for Settings. */ class CRM_Admin_Page_Setting extends CRM_Core_Page { + /** * Run page. * diff --git a/CRM/Batch/BAO/Batch.php b/CRM/Batch/BAO/Batch.php index fb8dd25c32..aa87f7076f 100644 --- a/CRM/Batch/BAO/Batch.php +++ b/CRM/Batch/BAO/Batch.php @@ -38,14 +38,16 @@ class CRM_Batch_BAO_Batch extends CRM_Batch_DAO_Batch { /** * Cache for the current batch object. + * @var object */ - static $_batch = NULL; + public static $_batch = NULL; /** * Not sure this is the best way to do this. Depends on how exportFinancialBatch() below gets called. * Maybe a parameter to that function is better. + * @var string */ - static $_exportFormat = NULL; + public static $_exportFormat = NULL; /** * Create a new batch. @@ -539,7 +541,6 @@ class CRM_Batch_BAO_Batch extends CRM_Batch_DAO_Batch { return $batches; } - /** * Calculate sum of all entries in a batch. * Used to validate and update item_count and total when closing an accounting batch diff --git a/CRM/Batch/Form/Entry.php b/CRM/Batch/Form/Entry.php index ec698a8d1d..4d0671fa8e 100644 --- a/CRM/Batch/Form/Entry.php +++ b/CRM/Batch/Form/Entry.php @@ -38,21 +38,25 @@ class CRM_Batch_Form_Entry extends CRM_Core_Form { /** * Maximum profile fields that will be displayed. + * @var int */ protected $_rowCount = 1; /** * Batch id. + * @var int */ protected $_batchId; /** * Batch information. + * @var array */ protected $_batchInfo = []; /** * Store the profile id associated with the batch type. + * @var int */ protected $_profileId; @@ -64,11 +68,13 @@ class CRM_Batch_Form_Entry extends CRM_Core_Form { /** * When not to reset sort_name. + * @var bool */ protected $_preserveDefault = TRUE; /** * Contact fields. + * @var array */ protected $_contactFields = []; @@ -88,6 +94,7 @@ class CRM_Batch_Form_Entry extends CRM_Core_Form { * These should get a standardised format in the beginPostProcess function. * * These fields are common to many forms. Some may override this. + * @var array */ protected $submittableMoneyFields = ['total_amount', 'net_amount', 'non_deductible_amount', 'fee_amount']; diff --git a/CRM/Batch/Form/Search.php b/CRM/Batch/Form/Search.php index daab61e9f8..61b86a5f86 100644 --- a/CRM/Batch/Form/Search.php +++ b/CRM/Batch/Form/Search.php @@ -31,6 +31,7 @@ * @copyright CiviCRM LLC (c) 2004-2019 */ class CRM_Batch_Form_Search extends CRM_Core_Form { + /** * Set default values. * diff --git a/CRM/Batch/Page/Batch.php b/CRM/Batch/Page/Batch.php index 5c9e068695..6267d5d90d 100644 --- a/CRM/Batch/Page/Batch.php +++ b/CRM/Batch/Page/Batch.php @@ -41,7 +41,7 @@ class CRM_Batch_Page_Batch extends CRM_Core_Page_Basic { * * @var array */ - static $_links = NULL; + public static $_links = NULL; /** * Get BAO Name. -- 2.25.1