From: Tim Otten Date: Fri, 9 Jan 2015 00:06:46 +0000 (-0800) Subject: INFRA-132 - Trailing commas for multiline arrays X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=21dfd5f567e7996ad92cf2a7d0fbe6f5fc205a5c;p=civicrm-core.git INFRA-132 - Trailing commas for multiline arrays --- diff --git a/CRM/Activity/BAO/Activity.php b/CRM/Activity/BAO/Activity.php index 1324e97092..00d06152c2 100644 --- a/CRM/Activity/BAO/Activity.php +++ b/CRM/Activity/BAO/Activity.php @@ -351,7 +351,7 @@ class CRM_Activity_BAO_Activity extends CRM_Activity_DAO_Activity { $acParams = array( 'activity_id' => $activityId, 'contact_id' => $params['source_contact_id'], - 'record_type_id' => $sourceID + 'record_type_id' => $sourceID, ); self::deleteActivityContact($activityId, $sourceID); CRM_Activity_BAO_ActivityContact::create($acParams); @@ -1564,7 +1564,7 @@ LEFT JOIN civicrm_activity_contact src ON (src.activity_id = ac.activity_id AND $activityTargetParams = array( 'activity_id' => $activityID, 'contact_id' => $toID, - 'record_type_id' => $targetID + 'record_type_id' => $targetID, ); CRM_Activity_BAO_ActivityContact::create($activityTargetParams); @@ -1648,7 +1648,7 @@ LEFT JOIN civicrm_activity_contact src ON (src.activity_id = ac.activity_id AND $activityTargetParams = array( 'activity_id' => $activityID, 'contact_id' => $toID, - 'record_type_id' => $targetID + 'record_type_id' => $targetID, ); CRM_Activity_BAO_ActivityContact::create($activityTargetParams); return TRUE; @@ -2182,7 +2182,7 @@ AND cl.modified_id = c.id 'case_recent_activity_date' => array('title' => ts('Activity Actual Date'), 'type' => CRM_Utils_Type::T_DATE), 'case_scheduled_activity_date' => array( 'title' => ts('Activity Scheduled Date'), - 'type' => CRM_Utils_Type::T_DATE + 'type' => CRM_Utils_Type::T_DATE, ), 'case_recent_activity_type' => array('title' => ts('Activity Type'), 'type' => CRM_Utils_Type::T_STRING), 'case_activity_status' => array('title' => ts('Activity Status'), 'type' => CRM_Utils_Type::T_STRING), @@ -2191,7 +2191,7 @@ AND cl.modified_id = c.id 'case_activity_details' => array('title' => ts('Activity Details'), 'type' => CRM_Utils_Type::T_TEXT), 'case_activity_is_auto' => array( 'title' => ts('Activity Auto-generated?'), - 'type' => CRM_Utils_Type::T_BOOLEAN + 'type' => CRM_Utils_Type::T_BOOLEAN, ), ); diff --git a/CRM/Activity/BAO/ActivityContact.php b/CRM/Activity/BAO/ActivityContact.php index 106144f505..f6bfceaad1 100644 --- a/CRM/Activity/BAO/ActivityContact.php +++ b/CRM/Activity/BAO/ActivityContact.php @@ -93,7 +93,7 @@ AND contact_a.is_deleted = 0 "; $params = array( 1 => array($activityID, 'Integer'), - 2 => array($recordTypeID, 'Integer') + 2 => array($recordTypeID, 'Integer'), ); $dao = CRM_Core_DAO::executeQuery($query, $params); @@ -130,7 +130,7 @@ AND civicrm_contact.is_deleted = 0 "; $params = array( 1 => array($activityID, 'Integer'), - 2 => array($recordTypeID, 'Integer') + 2 => array($recordTypeID, 'Integer'), ); $dao = CRM_Core_DAO::executeQuery($sql, $params); diff --git a/CRM/Activity/Form/Activity.php b/CRM/Activity/Form/Activity.php index ffb4e76678..7dfd55927a 100644 --- a/CRM/Activity/Form/Activity.php +++ b/CRM/Activity/Form/Activity.php @@ -146,14 +146,14 @@ class CRM_Activity_Form_Activity extends CRM_Contact_Form_Task { 'type' => 'text', 'label' => ts('Location'), 'attributes' => CRM_Core_DAO::getAttribute('CRM_Activity_DAO_Activity', 'location'), - 'required' => FALSE + 'required' => FALSE, ), 'details' => array( 'type' => 'wysiwyg', 'label' => ts('Details'), // forces a smaller edit window 'attributes' => array('rows' => 4, 'cols' => 60), - 'required' => FALSE + 'required' => FALSE, ), 'status_id' => array( 'type' => 'select', @@ -166,12 +166,12 @@ class CRM_Activity_Form_Activity extends CRM_Contact_Form_Task { 'source_contact_id' => array( 'type' => 'entityRef', 'label' => ts('Added By'), - 'required' => FALSE + 'required' => FALSE, ), 'target_contact_id' => array( 'type' => 'entityRef', 'label' => ts('With Contact'), - 'attributes' => array('multiple' => TRUE, 'create' => TRUE) + 'attributes' => array('multiple' => TRUE, 'create' => TRUE), ), 'assignee_contact_id' => array( 'type' => 'entityRef', @@ -195,8 +195,8 @@ class CRM_Activity_Form_Activity extends CRM_Contact_Form_Task { 'label' => ts('Subject'), 'attributes' => CRM_Core_DAO::getAttribute('CRM_Activity_DAO_Activity', 'subject' - ) - ) + ), + ), ); if (($this->_context == 'standalone') && @@ -279,7 +279,7 @@ class CRM_Activity_Form_Activity extends CRM_Contact_Form_Task { if ($this->_activityId && in_array($this->_action, array( CRM_Core_Action::UPDATE, - CRM_Core_Action::VIEW + CRM_Core_Action::VIEW, )) && !CRM_Activity_BAO_Activity::checkPermission($this->_activityId, $this->_action) ) { @@ -417,7 +417,7 @@ class CRM_Activity_Form_Activity extends CRM_Contact_Form_Task { 'standalone', 'home', 'dashlet', - 'dashletFullscreen' + 'dashletFullscreen', )) ) { $urlParams = 'reset=1'; @@ -610,12 +610,12 @@ class CRM_Activity_Form_Activity extends CRM_Contact_Form_Task { 'type' => 'next', 'name' => $button, 'spacing' => '         ', - 'isDefault' => TRUE + 'isDefault' => TRUE, ), array( 'type' => 'cancel', - 'name' => ts('Cancel') - ) + 'name' => ts('Cancel'), + ), )); return; } @@ -765,7 +765,7 @@ class CRM_Activity_Form_Activity extends CRM_Contact_Form_Task { $buttons = array(); $buttons[] = array( 'type' => 'cancel', - 'name' => ts('Done') + 'name' => ts('Done'), ); $this->addButtons($buttons); } @@ -780,12 +780,12 @@ class CRM_Activity_Form_Activity extends CRM_Contact_Form_Task { 'type' => 'upload', 'name' => ts('Save'), 'js' => $js, - 'isDefault' => TRUE + 'isDefault' => TRUE, ), array( 'type' => 'cancel', - 'name' => ts('Cancel') - ) + 'name' => ts('Cancel'), + ), ) ); } @@ -875,7 +875,7 @@ class CRM_Activity_Form_Activity extends CRM_Contact_Form_Task { // delete tags for the entity $tagParams = array( 'entity_table' => 'civicrm_activity', - 'entity_id' => $this->_activityId + 'entity_id' => $this->_activityId, ); CRM_Core_BAO_EntityTag::del($tagParams); @@ -987,7 +987,7 @@ class CRM_Activity_Form_Activity extends CRM_Contact_Form_Task { ), 'linkedColumns' => array('activity_id'), 'isRecurringEntityRecord' => FALSE, - ) + ), ); CRM_Core_Form_RecurringEntity::postProcess($params, 'civicrm_activity', $linkedEntities); @@ -1129,7 +1129,7 @@ class CRM_Activity_Form_Activity extends CRM_Contact_Form_Task { array( 1 => $subject, 2 => $followupStatus, - 3 => $mailStatus + 3 => $mailStatus, ) ), ts('Saved'), 'success'); diff --git a/CRM/Activity/Import/Form/MapField.php b/CRM/Activity/Import/Form/MapField.php index 6b10ff32fa..7ee9c42ce3 100644 --- a/CRM/Activity/Import/Form/MapField.php +++ b/CRM/Activity/Import/Form/MapField.php @@ -325,7 +325,7 @@ class CRM_Activity_Import_Form_MapField extends CRM_Import_Form_MapField { $errors['_qf_default'] .= ts('Missing required field: Provide %1 or %2', array( 1 => $title, - 2 => 'Activity Type Label' + 2 => 'Activity Type Label', )) . '
'; } } diff --git a/CRM/Activity/Import/Parser/Activity.php b/CRM/Activity/Import/Parser/Activity.php index 9748f71f1d..bdd45567e0 100644 --- a/CRM/Activity/Import/Parser/Activity.php +++ b/CRM/Activity/Import/Parser/Activity.php @@ -82,7 +82,7 @@ class CRM_Activity_Import_Parser_Activity extends CRM_Activity_Import_Parser { 'activity_label' => array( 'title' => ts('Activity Type Label'), 'headerPattern' => '/(activity.)?type label?/i', - ) + ), )); foreach ($fields as $name => $field) { diff --git a/CRM/Activity/Page/AJAX.php b/CRM/Activity/Page/AJAX.php index 7ae6a638da..5d35324ae3 100644 --- a/CRM/Activity/Page/AJAX.php +++ b/CRM/Activity/Page/AJAX.php @@ -118,7 +118,7 @@ class CRM_Activity_Page_AJAX { 0 => 'relation', 1 => 'name', 2 => 'phone', - 3 => 'email' + 3 => 'email', ); $sEcho = CRM_Utils_Type::escape($_REQUEST['sEcho'], 'Integer'); @@ -183,7 +183,7 @@ class CRM_Activity_Page_AJAX { 1 => 'name', 2 => 'phone', 3 => 'email', - 4 => 'actions' + 4 => 'actions', ); $sEcho = CRM_Utils_Type::escape($_REQUEST['sEcho'], 'Integer'); @@ -374,7 +374,7 @@ class CRM_Activity_Page_AJAX { } else { $otherActivity->subject = ts('(Filed on case %1)', array( - 1 => $params['caseID'] + 1 => $params['caseID'], )) . ' ' . $otherActivity->subject; } $otherActivity->activity_date_time = $actDateTime; @@ -398,7 +398,7 @@ class CRM_Activity_Page_AJAX { $src_params = array( 'activity_id' => $mainActivityId, 'contact_id' => $sourceContactID, - 'record_type_id' => $sourceID + 'record_type_id' => $sourceID, ); CRM_Activity_BAO_ActivityContact::create($src_params); @@ -406,7 +406,7 @@ class CRM_Activity_Page_AJAX { $targ_params = array( 'activity_id' => $mainActivityId, 'contact_id' => $value, - 'record_type_id' => $targetID + 'record_type_id' => $targetID, ); CRM_Activity_BAO_ActivityContact::create($targ_params); } @@ -420,7 +420,7 @@ class CRM_Activity_Page_AJAX { $assigneeParams = array( 'activity_id' => $mainActivityId, 'contact_id' => $value, - 'record_type_id' => $assigneeID + 'record_type_id' => $assigneeID, ); CRM_Activity_BAO_ActivityContact::create($assigneeParams); } diff --git a/CRM/Admin/Form/LabelFormats.php b/CRM/Admin/Form/LabelFormats.php index b7dadd2c2c..3548ef1a59 100644 --- a/CRM/Admin/Form/LabelFormats.php +++ b/CRM/Admin/Form/LabelFormats.php @@ -103,16 +103,16 @@ class CRM_Admin_Form_LabelFormats extends CRM_Admin_Form { $this->add('select', 'paper_size', ts('Sheet Size'), array( - 0 => ts('- default -') + 0 => ts('- default -'), ) + CRM_Core_BAO_PaperSize::getList(TRUE), FALSE, array( - 'onChange' => "selectPaper( this.value );" + 'onChange' => "selectPaper( this.value );", ) + $disabled ); $this->add('static', 'paper_dimensions', NULL, ts('Sheet Size (w x h)')); $this->add('select', 'orientation', ts('Orientation'), CRM_Core_BAO_LabelFormat::getPageOrientations(), FALSE, array( - 'onChange' => "updatePaperDimensions();" + 'onChange' => "updatePaperDimensions();", ) + $disabled ); $this->add('select', 'font_name', ts('Font Name'), CRM_Core_BAO_LabelFormat::getFontNames($this->_group)); @@ -137,7 +137,7 @@ class CRM_Admin_Form_LabelFormats extends CRM_Admin_Form { $this->addRule('label', ts('Name already exists in Database.'), 'objectExists', array( 'CRM_Core_BAO_LabelFormat', - $this->_id + $this->_id, )); $this->addRule('NX', ts('Must be an integer'), 'integer'); $this->addRule('NY', ts('Must be an integer'), 'integer'); diff --git a/CRM/Admin/Form/Options.php b/CRM/Admin/Form/Options.php index a77b1032d2..1f03724d38 100644 --- a/CRM/Admin/Form/Options.php +++ b/CRM/Admin/Form/Options.php @@ -431,7 +431,7 @@ class CRM_Admin_Form_Options extends CRM_Admin_Form { 'entity_table' => 'civicrm_option_value', 'entity_id' => $optionValue->id, 'account_relationship' => $relationTypeId, - 'financial_account_id' => $params['financial_account_id'] + 'financial_account_id' => $params['financial_account_id'], ); CRM_Financial_BAO_FinancialTypeAccount::add($params); } diff --git a/CRM/Admin/Form/PaymentProcessor.php b/CRM/Admin/Form/PaymentProcessor.php index 6132f67371..95fabcbf23 100644 --- a/CRM/Admin/Form/PaymentProcessor.php +++ b/CRM/Admin/Form/PaymentProcessor.php @@ -406,7 +406,7 @@ class CRM_Admin_Form_PaymentProcessor extends CRM_Admin_Form { 'entity_table' => 'civicrm_payment_processor', 'entity_id' => $dao->id, 'account_relationship' => $relationTypeId, - 'financial_account_id' => $values['financial_account_id'] + 'financial_account_id' => $values['financial_account_id'], ); CRM_Financial_BAO_FinancialTypeAccount::add($params); } diff --git a/CRM/Admin/Form/Preferences/Event.php b/CRM/Admin/Form/Preferences/Event.php index ec63a66969..6af7cbd18d 100644 --- a/CRM/Admin/Form/Preferences/Event.php +++ b/CRM/Admin/Form/Preferences/Event.php @@ -61,8 +61,8 @@ class CRM_Admin_Form_Preferences_Event extends CRM_Admin_Form_Preferences { 'title' => ts('Dashboard entries'), 'weight' => 2, 'description' => ts('Configure how many events should be shown on the dashboard. This overrides the default value of 10 entries.'), - 'option_values' => array('' => ts('- select -')) + $optionValues + array(-1 => ts('show all')) - ) + 'option_values' => array('' => ts('- select -')) + $optionValues + array(-1 => ts('show all')), + ), ), ); diff --git a/CRM/Admin/Form/ScheduleReminders.php b/CRM/Admin/Form/ScheduleReminders.php index 9bd699683d..352d35a99d 100644 --- a/CRM/Admin/Form/ScheduleReminders.php +++ b/CRM/Admin/Form/ScheduleReminders.php @@ -306,12 +306,12 @@ class CRM_Admin_Form_ScheduleReminders extends CRM_Admin_Form { $recipientKind = array( 'participant_role' => array( 'name' => 'participant role', - 'target_id' => 'recipient_listing' + 'target_id' => 'recipient_listing', ), 'manual' => array( 'name' => 'recipient', - 'target_id' => 'recipient_manual_id' - ) + 'target_id' => 'recipient_manual_id', + ), ); if (!empty($fields['limit_to']) && array_key_exists($fields['recipient'], $recipientKind) && empty($fields[$recipientKind[$fields['recipient']]['target_id']])) { $errors[$recipientKind[$fields['recipient']]['target_id']] = ts('If "Also include" or "Limit to" are selected, you must specify at least one %1', array(1 => $recipientKind[$fields['recipient']]['name'])); diff --git a/CRM/Admin/Form/Setting.php b/CRM/Admin/Form/Setting.php index 10219f991c..ca40d9c33a 100644 --- a/CRM/Admin/Form/Setting.php +++ b/CRM/Admin/Form/Setting.php @@ -100,7 +100,7 @@ class CRM_Admin_Form_Setting extends CRM_Core_Form { 'version' => 3, 'name' => $setting, 'group' => $group, - 'default_value' => CRM_Utils_Array::value('default', $settingMetaData['values'][$setting]) + 'default_value' => CRM_Utils_Array::value('default', $settingMetaData['values'][$setting]), ) ); } diff --git a/CRM/Admin/Form/Setting/Url.php b/CRM/Admin/Form/Setting/Url.php index d3f1dc2815..cfb5a4d706 100644 --- a/CRM/Admin/Form/Setting/Url.php +++ b/CRM/Admin/Form/Setting/Url.php @@ -50,7 +50,7 @@ class CRM_Admin_Form_Setting_Url extends CRM_Admin_Form_Setting { public function buildQuickForm() { CRM_Utils_System::setTitle(ts('Settings - Resource URLs')); $settingFields = civicrm_api('setting', 'getfields', array( - 'version' => 3 + 'version' => 3, )); $this->addElement('text', 'userFrameworkResourceURL', ts('CiviCRM Resource URL')); diff --git a/CRM/Admin/Page/AJAX.php b/CRM/Admin/Page/AJAX.php index b001414bb0..812e5c6c88 100644 --- a/CRM/Admin/Page/AJAX.php +++ b/CRM/Admin/Page/AJAX.php @@ -102,7 +102,7 @@ class CRM_Admin_Page_AJAX { $comps = array( 'Event' => 'civicrm_event', 'Contribution' => 'civicrm_contribution_page', - 'EventTemplate' => 'civicrm_event_template' + 'EventTemplate' => 'civicrm_event_template', ); $contexts = array(); foreach ($comps as $name => $table) { diff --git a/CRM/Admin/Page/Options.php b/CRM/Admin/Page/Options.php index 67d02fa86c..ebbf792b7f 100644 --- a/CRM/Admin/Page/Options.php +++ b/CRM/Admin/Page/Options.php @@ -143,7 +143,7 @@ class CRM_Admin_Page_Options extends CRM_Core_Page_Basic { 'communication_style', 'case_status', 'encounter_medium', 'case_type', 'payment_instrument', - 'soft_credit_type', 'website_type' + 'soft_credit_type', 'website_type', ) )) { $this->assign('showIsDefault', TRUE); diff --git a/CRM/Badge/BAO/Badge.php b/CRM/Badge/BAO/Badge.php index f1a0391c04..b3e111d2c4 100644 --- a/CRM/Badge/BAO/Badge.php +++ b/CRM/Badge/BAO/Badge.php @@ -231,7 +231,7 @@ class CRM_Badge_BAO_Badge { 'cap' => 'round', 'join' => 'round', 'dash' => '2,2', - 'color' => array(0, 0, 200) + 'color' => array(0, 0, 200), )); $rowCount = CRM_Badge_Form_Layout::FIELD_ROWCOUNT; diff --git a/CRM/Badge/Form/Layout.php b/CRM/Badge/Form/Layout.php index cea3100359..8b6d074d99 100644 --- a/CRM/Badge/Form/Layout.php +++ b/CRM/Badge/Form/Layout.php @@ -54,7 +54,7 @@ class CRM_Badge_Form_Layout extends CRM_Admin_Form { $resources = CRM_Core_Resources::singleton(); $resources->addSetting( array( - 'kcfinderPath' => $config->userFrameworkResourceURL . 'packages' . DIRECTORY_SEPARATOR + 'kcfinderPath' => $config->userFrameworkResourceURL . 'packages' . DIRECTORY_SEPARATOR, ) ); $resources->addScriptFile('civicrm', 'templates/CRM/Badge/Form/Layout.js', 1, 'html-header'); @@ -75,7 +75,7 @@ class CRM_Badge_Form_Layout extends CRM_Admin_Form { '{event.event_id}' => ts('Event ID'), '{event.title}' => ts('Event Title'), '{event.start_date}' => ts('Event Start Date'), - '{event.end_date}' => ts('Event End Date') + '{event.end_date}' => ts('Event End Date'), ); $participantTokens = CRM_Core_SelectValues::participantTokens(); diff --git a/CRM/Batch/BAO/Batch.php b/CRM/Batch/BAO/Batch.php index 3a161b4fe9..bac5d257df 100755 --- a/CRM/Batch/BAO/Batch.php +++ b/CRM/Batch/BAO/Batch.php @@ -469,7 +469,7 @@ class CRM_Batch_BAO_Batch extends CRM_Batch_DAO_Batch { 'url' => 'civicrm/file', 'qs' => 'reset=1&id=%%fid%%&eid=%%eid%%', 'title' => ts('Download Batch'), - ) + ), ); } else { @@ -491,7 +491,7 @@ class CRM_Batch_BAO_Batch extends CRM_Batch_DAO_Batch { 'url' => 'civicrm/batch', 'qs' => 'action=delete&id=%%id%%', 'title' => ts('Delete Batch'), - ) + ), ); } return $links; diff --git a/CRM/Batch/Form/Entry.php b/CRM/Batch/Form/Entry.php index 7f5c87f6a9..d3701e053e 100755 --- a/CRM/Batch/Form/Entry.php +++ b/CRM/Batch/Form/Entry.php @@ -175,12 +175,12 @@ class CRM_Batch_Form_Entry extends CRM_Core_Form { array( 'type' => 'upload', 'name' => ts('Validate & Process the Batch'), - 'isDefault' => TRUE + 'isDefault' => TRUE, ), array( 'type' => 'cancel', 'name' => ts('Save & Continue Later'), - ) + ), ) ); @@ -352,7 +352,7 @@ class CRM_Batch_Form_Entry extends CRM_Core_Form { 'join_date' => $currentDate, 'receive_date' => $currentDate, 'receive_date_time' => $currentTime, - 'contribution_status_id' => $completeStatus + 'contribution_status_id' => $completeStatus, ); for ($rowNumber = 1; $rowNumber <= $this->_batchInfo['item_count']; $rowNumber++) { @@ -589,14 +589,14 @@ class CRM_Batch_Form_Entry extends CRM_Core_Form { $dateTypes = array( 'join_date' => 'joinDate', 'membership_start_date' => 'startDate', - 'membership_end_date' => 'endDate' + 'membership_end_date' => 'endDate', ); $dates = array( 'join_date', 'start_date', 'end_date', - 'reminder_date' + 'reminder_date', ); // get the price set associated with offline memebership @@ -713,7 +713,7 @@ class CRM_Batch_Form_Entry extends CRM_Core_Form { $editedFieldParams = array( 'price_set_id' => $priceSetId, - 'name' => $value['membership_type'][0] + 'name' => $value['membership_type'][0], ); $editedResults = array(); @@ -726,7 +726,7 @@ class CRM_Batch_Form_Entry extends CRM_Core_Form { $fid = $editedResults['id']; $editedFieldParams = array( 'price_field_id' => $editedResults['id'], - 'membership_type_id' => $value['membership_type_id'] + 'membership_type_id' => $value['membership_type_id'], ); $editedResults = array(); diff --git a/CRM/Campaign/BAO/Petition.php b/CRM/Campaign/BAO/Petition.php index 18f485206f..1b36338d58 100644 --- a/CRM/Campaign/BAO/Petition.php +++ b/CRM/Campaign/BAO/Petition.php @@ -244,7 +244,7 @@ SELECT petition.id as id, $params = array( 1 => array($activity_id, 'Integer'), 2 => array($contact_id, 'Integer'), - 3 => array($sourceID, 'Integer') + 3 => array($sourceID, 'Integer'), ); CRM_Core_DAO::executeQuery($sql, $params); @@ -305,7 +305,7 @@ AND tag_id = ( SELECT id FROM civicrm_tag WHERE name = %2 )"; $sourceID = CRM_Utils_Array::key('Activity Source', $activityContacts); $params = array( 1 => array($surveyId, 'Integer'), - 2 => array($sourceID, 'Integer') + 2 => array($sourceID, 'Integer'), ); $sql .= " GROUP BY civicrm_address.country_id"; $fields = array('total', 'country_id', 'country_iso', 'country'); @@ -515,7 +515,7 @@ AND tag_id = ( SELECT id FROM civicrm_tag WHERE name = %2 )"; 2 => array($surveyId, 'Integer'), 3 => array($surveyInfo['activity_type_id'], 'Integer'), 4 => array($contactId, 'Integer'), - 5 => array($sourceID, 'Integer') + 5 => array($sourceID, 'Integer'), ); $dao = CRM_Core_DAO::executeQuery($sql, $params); diff --git a/CRM/Campaign/BAO/Survey.php b/CRM/Campaign/BAO/Survey.php index 40dc56dee3..682945e88e 100644 --- a/CRM/Campaign/BAO/Survey.php +++ b/CRM/Campaign/BAO/Survey.php @@ -669,7 +669,7 @@ INNER JOIN civicrm_contact contact_a ON ( activityTarget.contact_id = contact_a 'status_id' => $activity->status_id, 'interviewer_id' => $activity->interviewer_id, 'result' => $activity->result, - 'activity_date_time' => $activity->activity_date_time + 'activity_date_time' => $activity->activity_date_time, ); } diff --git a/CRM/Campaign/Form/Petition.php b/CRM/Campaign/Form/Petition.php index ca6117d416..e97bde0aac 100644 --- a/CRM/Campaign/Form/Petition.php +++ b/CRM/Campaign/Form/Petition.php @@ -206,7 +206,7 @@ class CRM_Campaign_Form_Petition extends CRM_Core_Form { // custom group id $this->add('select', 'profile_id', ts('Activity Profile'), array( - '' => ts('- select -') + '' => ts('- select -'), ) + $customProfiles ); diff --git a/CRM/Campaign/Form/Survey/Questions.php b/CRM/Campaign/Form/Survey/Questions.php index ced03cb5af..cf8552bdbf 100644 --- a/CRM/Campaign/Form/Survey/Questions.php +++ b/CRM/Campaign/Form/Survey/Questions.php @@ -81,7 +81,7 @@ class CRM_Campaign_Form_Survey_Questions extends CRM_Campaign_Form_Survey { array( 1 => $activityTypes[$subTypeId], 2 => CRM_Utils_System::url('civicrm/admin/custom/group', 'action=add&reset=1'), - 3 => '_blank' + 3 => '_blank', ) ) ); diff --git a/CRM/Campaign/Form/Survey/Results.php b/CRM/Campaign/Form/Survey/Results.php index 393a86e6e9..a9ccbaa593 100644 --- a/CRM/Campaign/Form/Survey/Results.php +++ b/CRM/Campaign/Form/Survey/Results.php @@ -118,7 +118,7 @@ class CRM_Campaign_Form_Survey_Results extends CRM_Campaign_Form_Survey { 'option_group_id', ts('Select Result Set'), array( - '' => ts('- select -') + '' => ts('- select -'), ) + $optionGroups, FALSE, array('onChange' => 'loadOptionGroup( )') ); @@ -128,7 +128,7 @@ class CRM_Campaign_Form_Survey_Results extends CRM_Campaign_Form_Survey { ts('Survey Responses'), $optionTypes, array( - 'onclick' => "showOptionSelect();" + 'onclick' => "showOptionSelect();", ), '
', TRUE ); @@ -199,7 +199,7 @@ class CRM_Campaign_Form_Survey_Results extends CRM_Campaign_Form_Survey { $this->addFormRule(array( 'CRM_Campaign_Form_Survey_Results', - 'formRule' + 'formRule', ), $this); parent::buildQuickForm(); @@ -429,7 +429,7 @@ class CRM_Campaign_Form_Survey_Results extends CRM_Campaign_Form_Survey { array( 1 => array( 'column' => 'sort_name', - 'order' => 'ASC' + 'order' => 'ASC', ), ); // for WalkList or default @@ -440,7 +440,7 @@ class CRM_Campaign_Form_Survey_Results extends CRM_Campaign_Form_Survey { 'street_number', 'street_name', 'street_unit', - 'survey_response' + 'survey_response', ); if (CRM_Core_OptionGroup::getValue('activity_type', 'WalkList') == $this->_values['activity_type_id'] @@ -449,19 +449,19 @@ class CRM_Campaign_Form_Survey_Results extends CRM_Campaign_Form_Survey { array( 1 => array( 'column' => 'street_name', - 'order' => 'ASC' + 'order' => 'ASC', ), 2 => array( 'column' => 'street_number_odd_even', - 'order' => 'ASC' + 'order' => 'ASC', ), 3 => array( 'column' => 'street_number', - 'order' => 'ASC' + 'order' => 'ASC', ), 4 => array( 'column' => 'sort_name', - 'order' => 'ASC' + 'order' => 'ASC', ), ); } @@ -488,8 +488,8 @@ class CRM_Campaign_Form_Survey_Results extends CRM_Campaign_Form_Survey { $reportID = CRM_Core_DAO::singleValueQuery($query, array( 1 => array( "survey_{$survey->id}", - 'String' - ) + 'String', + ), )); if ($reportID) { $url = CRM_Utils_System::url("civicrm/report/instance/{$reportID}", 'reset=1'); diff --git a/CRM/Campaign/Form/Task/Interview.php b/CRM/Campaign/Form/Task/Interview.php index 2e4c90ba67..811c8a2bea 100755 --- a/CRM/Campaign/Form/Task/Interview.php +++ b/CRM/Campaign/Form/Task/Interview.php @@ -553,7 +553,7 @@ WHERE {$clause} 'source_contact_id' => 'source_contact', 'location' => 'activity_location', 'campaign_id' => 'activity_campaign_id', - 'duration' => 'activity_duration' + 'duration' => 'activity_duration', ); foreach ($activityParams as $key => $field) { if (!empty($params[$field])) { diff --git a/CRM/Case/BAO/Case.php b/CRM/Case/BAO/Case.php index e8fa07847c..4d245fc12e 100644 --- a/CRM/Case/BAO/Case.php +++ b/CRM/Case/BAO/Case.php @@ -2698,7 +2698,7 @@ SELECT id 1 => $otherCaseId, 2 => $otherContactDisplayName, 3 => $mainContactDisplayName, - 4 => $mainCaseId + 4 => $mainCaseId, ) ); } @@ -2709,7 +2709,7 @@ SELECT id 1 => $otherCaseId, 2 => $otherContactId, 3 => $mainContactId, - 4 => $mainCaseId + 4 => $mainCaseId, ) ); } @@ -2902,7 +2902,7 @@ WHERE id IN (' . implode(',', $copiedActivityIds) . ')'; //need to check activity object specific. if (in_array($operation, array( 'view', - 'edit' + 'edit', )) ) { //do we have supper permission. @@ -2988,7 +2988,7 @@ WHERE id IN (' . implode(',', $copiedActivityIds) . ')'; 'Link Cases', 'Assign Case Role', 'Email', - 'Inbound Email' + 'Inbound Email', ); //do not allow to delete these activities, CRM-4543 @@ -3006,7 +3006,7 @@ WHERE id IN (' . implode(',', $copiedActivityIds) . ')'; 'Reassigned Case', 'Merge Case', 'Link Cases', - 'Assign Case Role' + 'Assign Case Role', ); if (in_array($actTypeName, $singletonNames)) { diff --git a/CRM/Case/Form/Activity.php b/CRM/Case/Form/Activity.php index 43c05b0d4f..9847be50c9 100644 --- a/CRM/Case/Form/Activity.php +++ b/CRM/Case/Form/Activity.php @@ -203,7 +203,7 @@ class CRM_Case_Form_Activity extends CRM_Activity_Form_Activity { CRM_Core_Error::statusBounce(ts("You can not add another '%1' activity to this case. %2", array( 1 => $this->_activityTypeName, - 2 => "Do you want to edit the existing activity ?" + 2 => "Do you want to edit the existing activity ?", ) ), $url @@ -282,7 +282,7 @@ class CRM_Case_Form_Activity extends CRM_Activity_Form_Activity { unset($aTypes[$openCaseID]); asort($aTypes); $this->_fields['followup_activity_type_id']['attributes'] = array( - '' => '- select activity type -' + '' => '- select activity type -', ) + $aTypes; } @@ -405,7 +405,7 @@ class CRM_Case_Form_Activity extends CRM_Activity_Form_Activity { $tagParams = array( 'entity_table' => 'civicrm_activity', - 'entity_id' => $this->_activityId + 'entity_id' => $this->_activityId, ); CRM_Core_BAO_EntityTag::del($tagParams); @@ -706,7 +706,7 @@ class CRM_Case_Form_Activity extends CRM_Activity_Form_Activity { 1 => $this->_activityTypeName, 2 => $recordStatus, 3 => $followupStatus, - 4 => $mailStatus + 4 => $mailStatus, ) ), 'info'); } diff --git a/CRM/Case/Form/Activity/ChangeCaseStatus.php b/CRM/Case/Form/Activity/ChangeCaseStatus.php index 5287b93576..8c64255242 100644 --- a/CRM/Case/Form/Activity/ChangeCaseStatus.php +++ b/CRM/Case/Form/Activity/ChangeCaseStatus.php @@ -183,7 +183,7 @@ class CRM_Case_Form_Activity_ChangeCaseStatus { if ($activity->subject == 'null') { $activity->subject = ts('Case status changed from %1 to %2', array( 1 => CRM_Utils_Array::value($statusval, $form->_caseStatus), - 2 => CRM_Utils_Array::value($params['case_status_id'], $form->_caseStatus) + 2 => CRM_Utils_Array::value($params['case_status_id'], $form->_caseStatus), ) ); $activity->save(); diff --git a/CRM/Case/ManagedEntities.php b/CRM/Case/ManagedEntities.php index 6f0c5d47bc..727c71dc55 100644 --- a/CRM/Case/ManagedEntities.php +++ b/CRM/Case/ManagedEntities.php @@ -77,7 +77,7 @@ class CRM_Case_ManagedEntities { 'name' => $actType, 'description' => $actType, 'component_id' => 'CiviCase', - ) + ), ); // We'll create managed-entity if this record doesn't exist yet @@ -125,7 +125,7 @@ class CRM_Case_ManagedEntities { 'contact_type_b' => 'Individual', 'contact_sub_type_a' => NULL, 'contact_sub_type_b' => NULL, - ) + ), ); // We'll create managed-entity if this record doesn't exist yet diff --git a/CRM/Contact/BAO/Contact.php b/CRM/Contact/BAO/Contact.php index eca1068681..afdee2970b 100644 --- a/CRM/Contact/BAO/Contact.php +++ b/CRM/Contact/BAO/Contact.php @@ -1211,7 +1211,7 @@ WHERE id={$id}; "; 'Individual', 'Household', 'Organization', - 'All' + 'All', ))) { $fields = array_merge($fields, CRM_Core_OptionValue::getFields('', $contactType)); } @@ -1262,7 +1262,7 @@ WHERE id={$id}; "; 'household_name', 'legal_name', 'sic_code', - 'organization_name' + 'organization_name', ), 'Household' => array( 'first_name', @@ -1420,7 +1420,7 @@ WHERE id={$id}; "; 'name' => 'location_type', 'where' => 'civicrm_location_type.name', 'title' => ts('Location Type'), - ) + ), ); $IMProvider = array( @@ -1428,7 +1428,7 @@ WHERE id={$id}; "; 'name' => 'im_provider', 'where' => 'civicrm_im.provider_id', 'title' => ts('IM Provider'), - ) + ), ); $locationFields = array_merge($locationType, @@ -1472,7 +1472,7 @@ WHERE id={$id}; "; foreach (array( 'Individual', 'Household', - 'Organization' + 'Organization', ) as $type) { $fields = array_merge($fields, CRM_Core_BAO_CustomField::getFieldsForImport($type, FALSE, FALSE, $search, TRUE, $withMultiRecord) @@ -1554,7 +1554,7 @@ WHERE id={$id}; "; 'postal_greeting_custom', 'addressee_custom', 'prefix_id', - 'suffix_id' + 'suffix_id', ), 'Organization' => array( 'first_name', @@ -1671,7 +1671,7 @@ WHERE id={$id}; "; 'im', 'email', 'openid', - 'phone_ext' + 'phone_ext', ))) { if ($type) { $returnProperties['location'][$locationTypeName][$fieldName . '-' . $type] = 1; @@ -2253,7 +2253,7 @@ ORDER BY civicrm_email.is_primary DESC"; 'gender_id', 'current_employer', 'prefix_id', - 'suffix_id' + 'suffix_id', )) && ($value == '' || !isset($value)) && ($session->get('authSrc') & (CRM_Core_Permission::AUTH_SRC_CHECKSUM + CRM_Core_Permission::AUTH_SRC_LOGIN)) == 0 @@ -2488,7 +2488,7 @@ AND civicrm_openid.is_primary = 1"; 'preferred_communication_method' => array( 'newName' => 'preferred_communication_method_display', 'groupName' => 'preferred_communication_method', - ) + ), ); CRM_Core_OptionGroup::lookupValues($temp, $names, FALSE); @@ -3042,7 +3042,7 @@ AND civicrm_openid.is_primary = 1"; $hasAllPermissions = TRUE; } elseif (in_array($values['ref'], array( - 'new-email' + 'new-email', ))) { // grant permissions for these tasks. $hasAllPermissions = TRUE; @@ -3058,7 +3058,7 @@ AND civicrm_openid.is_primary = 1"; // build directly accessible action menu. if (in_array($values['ref'], array( 'view-contact', - 'edit-contact' + 'edit-contact', ))) { $contextMenu['primaryActions'][$key] = array( 'title' => $values['title'], diff --git a/CRM/Contact/BAO/Group.php b/CRM/Contact/BAO/Group.php index 760ea39fba..dc040fa5d8 100644 --- a/CRM/Contact/BAO/Group.php +++ b/CRM/Contact/BAO/Group.php @@ -1039,14 +1039,14 @@ WHERE id IN $groupIdString $allGroups[$dao->id] = array( 'title' => $dao->title, 'visibility' => $dao->visibility, - 'description' => $dao->description + 'description' => $dao->description, ); if ($dao->parents == $parents) { $roots[] = array( 'id' => $dao->id, 'prefix' => '', - 'title' => $dao->title + 'title' => $dao->title, ); } else { @@ -1057,7 +1057,7 @@ WHERE id IN $groupIdString 'id' => $dao->id, 'prefix' => '', 'title' => $dao->title, - 'parents' => $parent + 'parents' => $parent, ); } } @@ -1082,7 +1082,7 @@ WHERE id IN $groupIdString $new_roots[] = array( 'id' => $row['id'], 'prefix' => $groups[$root['id']][0] . $spacer, - 'title' => $row['title'] + 'title' => $row['title'], ); unset($rows[$key]); } diff --git a/CRM/Contact/BAO/GroupContactCache.php b/CRM/Contact/BAO/GroupContactCache.php index 7c79313f0b..9c79144121 100644 --- a/CRM/Contact/BAO/GroupContactCache.php +++ b/CRM/Contact/BAO/GroupContactCache.php @@ -661,7 +661,7 @@ ORDER BY gc.contact_id, g.children 'id' => $dao->group_id, 'title' => $dao->title, 'description' => $dao->description, - 'children' => $dao->children + 'children' => $dao->children, ); $contactGroup[$dao->contact_id]['groupTitle'][] = $dao->title; } diff --git a/CRM/Contact/BAO/ProximityQuery.php b/CRM/Contact/BAO/ProximityQuery.php index e6fe770572..83226594c0 100644 --- a/CRM/Contact/BAO/ProximityQuery.php +++ b/CRM/Contact/BAO/ProximityQuery.php @@ -317,7 +317,7 @@ ACOS( $qill = ts('Proximity search to a distance of %1 from %2', array( 1 => $qillUnits, - 2 => implode(', ', $qill) + 2 => implode(', ', $qill), ) ); diff --git a/CRM/Contact/BAO/Query.php b/CRM/Contact/BAO/Query.php index d1b158e172..b54075d001 100644 --- a/CRM/Contact/BAO/Query.php +++ b/CRM/Contact/BAO/Query.php @@ -743,7 +743,7 @@ class CRM_Contact_BAO_Query { 'idCol' => "{$tName}_id", 'bao' => 'CRM_Core_BAO_Address', 'table' => "civicrm_{$tName}", - 'join' => " LEFT JOIN civicrm_{$tName} ON civicrm_address.{$tName}_id = civicrm_{$tName}.id " + 'join' => " LEFT JOIN civicrm_{$tName} ON civicrm_address.{$tName}_id = civicrm_{$tName}.id ", ); $this->_pseudoConstantsSelect[$tName] = @@ -751,7 +751,7 @@ class CRM_Contact_BAO_Query { 'pseudoField' => 'state_province_abbreviation', 'idCol' => "{$tName}_id", 'table' => "civicrm_{$tName}", - 'join' => " LEFT JOIN civicrm_{$tName} ON civicrm_address.{$tName}_id = civicrm_{$tName}.id " + 'join' => " LEFT JOIN civicrm_{$tName} ON civicrm_address.{$tName}_id = civicrm_{$tName}.id ", ); } else { @@ -761,7 +761,7 @@ class CRM_Contact_BAO_Query { 'idCol' => "{$tName}_id", 'bao' => 'CRM_Core_BAO_Address', 'table' => "civicrm_{$tName}", - 'join' => " LEFT JOIN civicrm_{$tName} ON civicrm_address.{$tName}_id = civicrm_{$tName}.id " + 'join' => " LEFT JOIN civicrm_{$tName} ON civicrm_address.{$tName}_id = civicrm_{$tName}.id ", ); } @@ -796,28 +796,28 @@ class CRM_Contact_BAO_Query { $this->_pseudoConstantsSelect['individual_prefix'] = array( 'pseudoField' => 'prefix_id', 'idCol' => "prefix_id", - 'bao' => 'CRM_Contact_BAO_Contact' + 'bao' => 'CRM_Contact_BAO_Contact', ); } if ($fieldName == 'suffix_id') { $this->_pseudoConstantsSelect['individual_suffix'] = array( 'pseudoField' => 'suffix_id', 'idCol' => "suffix_id", - 'bao' => 'CRM_Contact_BAO_Contact' + 'bao' => 'CRM_Contact_BAO_Contact', ); } if ($fieldName == 'gender_id') { $this->_pseudoConstantsSelect['gender'] = array( 'pseudoField' => 'gender_id', 'idCol' => "gender_id", - 'bao' => 'CRM_Contact_BAO_Contact' + 'bao' => 'CRM_Contact_BAO_Contact', ); } if ($name == 'communication_style_id') { $this->_pseudoConstantsSelect['communication_style'] = array( 'pseudoField' => 'communication_style_id', 'idCol' => "communication_style_id", - 'bao' => 'CRM_Contact_BAO_Contact' + 'bao' => 'CRM_Contact_BAO_Contact', ); } $this->_select[$name] = "contact_a.{$fieldName} as `$name`"; @@ -1136,7 +1136,7 @@ class CRM_Contact_BAO_Query { $this->_pseudoConstantsSelect["{$name}-{$elementFullName}"] = array( 'pseudoField' => "{$pf}_id", 'idCol' => "{$tName}_id", - 'bao' => 'CRM_Core_BAO_Address' + 'bao' => 'CRM_Core_BAO_Address', ); $this->_pseudoConstantsSelect["{$name}-{$elementFullName}"]['select'] = "`$tName`.$fieldName as `{$name}-{$elementFullName}`"; } @@ -5411,7 +5411,7 @@ AND displayRelType.is_active = 1 'gender_id', 'prefix_id', 'suffix_id', - 'communication_style_id' + 'communication_style_id', ); if (is_numeric($value)) { diff --git a/CRM/Contact/BAO/Relationship.php b/CRM/Contact/BAO/Relationship.php index ac9ee74567..328a12f0f0 100644 --- a/CRM/Contact/BAO/Relationship.php +++ b/CRM/Contact/BAO/Relationship.php @@ -320,8 +320,8 @@ class CRM_Contact_BAO_Relationship extends CRM_Contact_DAO_Relationship { $result = CRM_Core_DAO::executeQuery("SELECT " . implode(',', $fieldsToFill) . " FROM civicrm_relationship WHERE id = %1", array( 1 => array( $params['id'], - 'Integer' - ) + 'Integer', + ), )); while ($result->fetch()) { foreach ($fieldsToFill as $field) { @@ -1466,7 +1466,7 @@ SELECT relationship_type_id, relationship_direction foreach (array( 'join_date', 'start_date', - 'end_date' + 'end_date', ) as $dateField) { if (!empty($membershipValues[$dateField])) { $membershipValues[$dateField] = CRM_Utils_Date::processDate($membershipValues[$dateField]); @@ -1723,7 +1723,7 @@ AND cc.sort_name LIKE '%$name%'"; public static function membershipTypeToRelationshipTypes(&$params, $direction = NULL) { $membershipType = civicrm_api3('membership_type', 'getsingle', array( 'id' => $params['membership_type_id'], - 'return' => 'relationship_type_id, relationship_direction' + 'return' => 'relationship_type_id, relationship_direction', )); $relationshipTypes = $membershipType['relationship_type_id']; if (empty($relationshipTypes)) { diff --git a/CRM/Contact/Form/DedupeRules.php b/CRM/Contact/Form/DedupeRules.php index 6814a9ea5e..c769b42037 100644 --- a/CRM/Contact/Form/DedupeRules.php +++ b/CRM/Contact/Form/DedupeRules.php @@ -123,7 +123,7 @@ class CRM_Contact_Form_DedupeRules extends CRM_Admin_Form { for ($count = 0; $count < self::RULES_COUNT; $count++) { $this->add('select', "where_$count", ts('Field'), array( - NULL => ts('- none -') + NULL => ts('- none -'), ) + $this->_fields, FALSE, $disabled ); $this->add('text', "length_$count", ts('Length'), $attributes); diff --git a/CRM/Contact/Form/Merge.php b/CRM/Contact/Form/Merge.php index ae06c8bbfa..917c1fc9ec 100644 --- a/CRM/Contact/Form/Merge.php +++ b/CRM/Contact/Form/Merge.php @@ -217,7 +217,7 @@ class CRM_Contact_Form_Merge extends CRM_Core_Form { $this->_locBlockIds = array( 'main' => $rowsElementsAndInfo['main_details']['loc_block_ids'], - 'other' => $rowsElementsAndInfo['other_details']['loc_block_ids'] + 'other' => $rowsElementsAndInfo['other_details']['loc_block_ids'], ); // add elements diff --git a/CRM/Contact/Form/ProfileContact.php b/CRM/Contact/Form/ProfileContact.php index 9344c55744..8029c7a7f8 100644 --- a/CRM/Contact/Form/ProfileContact.php +++ b/CRM/Contact/Form/ProfileContact.php @@ -65,7 +65,7 @@ class CRM_Contact_Form_ProfileContact { $requiredProfileFields = array( 'Individual' => array('first_name', 'last_name'), 'Organization' => array('organization_name', 'email'), - 'Household' => array('household_name', 'email') + 'Household' => array('household_name', 'email'), ); $validProfile = CRM_Core_BAO_UFGroup::checkValidProfile($form->_honoreeProfileId, $requiredProfileFields[$profileContactType]); if (!$validProfile) { @@ -150,7 +150,7 @@ class CRM_Contact_Form_ProfileContact { ), 'honor_id' => $honorId, 'honor_profile_id' => $params['honoree_profile_id'], - 'honor_profile_values' => $params['honor'] + 'honor_profile_values' => $params['honor'], ); } } diff --git a/CRM/Contact/Form/Relationship.php b/CRM/Contact/Form/Relationship.php index 1fb145835c..1ee6aadd0c 100644 --- a/CRM/Contact/Form/Relationship.php +++ b/CRM/Contact/Form/Relationship.php @@ -260,7 +260,7 @@ class CRM_Contact_Form_Relationship extends CRM_Core_Form { 'entity_id' => $this->_relationshipId, 'entity_table' => 'civicrm_relationship', 'limit' => 1, - 'version' => 3 + 'version' => 3, ); $note = civicrm_api('Note' ,'getsingle', $noteParams); $defaults['note'] = CRM_Utils_Array::value('note', $note); diff --git a/CRM/Contact/Form/Search/Criteria.php b/CRM/Contact/Form/Search/Criteria.php index a105b2a2dc..767b262042 100644 --- a/CRM/Contact/Form/Search/Criteria.php +++ b/CRM/Contact/Form/Search/Criteria.php @@ -352,7 +352,7 @@ class CRM_Contact_Form_Search_Criteria { $form->addElement('text', 'prox_distance', ts('Find contacts within'), array('class' => 'six')); $form->addElement('select', 'prox_distance_unit', NULL, array( 'miles' => ts('Miles'), - 'kilos' => ts('Kilometers') + 'kilos' => ts('Kilometers'), )); $form->addRule('prox_distance', ts('Please enter positive number as a distance'), 'numeric'); } diff --git a/CRM/Contact/Form/Task/PDFLetterCommon.php b/CRM/Contact/Form/Task/PDFLetterCommon.php index f97eeaa7bb..7ce4c846ec 100644 --- a/CRM/Contact/Form/Task/PDFLetterCommon.php +++ b/CRM/Contact/Form/Task/PDFLetterCommon.php @@ -410,7 +410,7 @@ class CRM_Contact_Form_Task_PDFLetterCommon { $activityTargetParams = array( 'activity_id' => empty($activity->id) ? $activityIds[$contactId] : $activity->id, 'contact_id' => $contactId, - 'record_type_id' => $targetID + 'record_type_id' => $targetID, ); CRM_Activity_BAO_ActivityContact::create($activityTargetParams); } diff --git a/CRM/Contact/Page/AJAX.php b/CRM/Contact/Page/AJAX.php index 3f659e3755..1cb76fd5d3 100644 --- a/CRM/Contact/Page/AJAX.php +++ b/CRM/Contact/Page/AJAX.php @@ -65,7 +65,7 @@ class CRM_Contact_Page_AJAX { 'context' => 'context', 'rel' => 'rel', 'contact_sub_type' => 'contact_sub_type', - 'contact_type' => 'contact_type' + 'contact_type' => 'contact_type', ); foreach ($whitelist as $key => $param) { if (!empty($_GET[$key])) { @@ -308,7 +308,7 @@ class CRM_Contact_Page_AJAX { $ret = array( 'is_error' => 1, 'error_message' => ts('The relationship type definition for the case role is not valid for the client and / or staff contact types. You can review and edit relationship types at Administer >> Option Lists >> Relationship Types.', - array(1 => CRM_Utils_System::url('civicrm/admin/reltype', 'reset=1'))) + array(1 => CRM_Utils_System::url('civicrm/admin/reltype', 'reset=1'))), ); } } diff --git a/CRM/Contact/Page/ImageFile.php b/CRM/Contact/Page/ImageFile.php index f1ace85677..af768810da 100644 --- a/CRM/Contact/Page/ImageFile.php +++ b/CRM/Contact/Page/ImageFile.php @@ -41,7 +41,7 @@ class CRM_Contact_Page_ImageFile extends CRM_Core_Page { // FIXME Optimize performance of image_url query $sql = "SELECT id FROM civicrm_contact WHERE image_url like %1;"; $params = array( - 1 => array("%" . $_GET['photo'], 'String') + 1 => array("%" . $_GET['photo'], 'String'), ); $dao = CRM_Core_DAO::executeQuery($sql, $params); while ($dao->fetch()) { diff --git a/CRM/Contact/Page/View/Summary.php b/CRM/Contact/Page/View/Summary.php index 51eccdfa4f..8239dea8b5 100644 --- a/CRM/Contact/Page/View/Summary.php +++ b/CRM/Contact/Page/View/Summary.php @@ -391,7 +391,7 @@ class CRM_Contact_Page_View_Summary extends CRM_Contact_Page_View { 'weight' => $weight, 'count' => CRM_Contact_BAO_Contact::getCountComponent($id, $this->_contactId, $group['table_name']), 'hideCount' => !$group['is_multiple'], - 'class' => 'livePage' + 'class' => 'livePage', ); $weight += 10; } diff --git a/CRM/Contact/Selector.php b/CRM/Contact/Selector.php index 9ae3d33293..064381867b 100644 --- a/CRM/Contact/Selector.php +++ b/CRM/Contact/Selector.php @@ -614,7 +614,7 @@ class CRM_Contact_Selector extends CRM_Core_Selector_Base implements CRM_Core_Se if (in_array('world_region', $names)) { $pseudoconstants['world_region'] = array( 'dbName' => 'world_region_id', - 'values' => CRM_Core_PseudoConstant::worldRegion() + 'values' => CRM_Core_PseudoConstant::worldRegion(), ); } diff --git a/CRM/Contribute/BAO/Contribution.php b/CRM/Contribute/BAO/Contribution.php index 758612be6d..2a7515d19e 100644 --- a/CRM/Contribute/BAO/Contribution.php +++ b/CRM/Contribute/BAO/Contribution.php @@ -644,8 +644,8 @@ class CRM_Contribute_BAO_Contribution extends CRM_Contribute_DAO_Contribution { 'contribution_status' => array( 'title' => ts('Contribution Status'), 'name' => 'contribution_status', - 'data_type' => CRM_Utils_Type::T_STRING - ) + 'data_type' => CRM_Utils_Type::T_STRING, + ), ); $contributionNote = array( @@ -653,8 +653,8 @@ class CRM_Contribute_BAO_Contribution extends CRM_Contribute_DAO_Contribution { array( 'title' => ts('Contribution Note'), 'name' => 'contribution_note', - 'data_type' => CRM_Utils_Type::T_TEXT - ) + 'data_type' => CRM_Utils_Type::T_TEXT, + ), ); $contributionRecurId = array( @@ -662,14 +662,14 @@ class CRM_Contribute_BAO_Contribution extends CRM_Contribute_DAO_Contribution { 'title' => ts('Recurring Contributions ID'), 'name' => 'contribution_recur_id', 'where' => 'civicrm_contribution.contribution_recur_id', - 'data_type' => CRM_Utils_Type::T_INT - ) + 'data_type' => CRM_Utils_Type::T_INT, + ), ); $extraFields = array( 'contribution_batch' => array( - 'title' => ts('Batch Name') - ) + 'title' => ts('Batch Name'), + ), ); $softCreditFields = array( @@ -677,25 +677,25 @@ class CRM_Contribute_BAO_Contribution extends CRM_Contribute_DAO_Contribution { 'name' => 'contribution_soft_credit_name', 'title' => 'Soft Credit For', 'where' => 'civicrm_contact_d.display_name', - 'data_type' => CRM_Utils_Type::T_STRING + 'data_type' => CRM_Utils_Type::T_STRING, ), 'contribution_soft_credit_amount' => array( 'name' => 'contribution_soft_credit_amount', 'title' => 'Soft Credit Amount', 'where' => 'civicrm_contribution_soft.amount', - 'data_type' => CRM_Utils_Type::T_MONEY + 'data_type' => CRM_Utils_Type::T_MONEY, ), 'contribution_soft_credit_type' => array( 'name' => 'contribution_soft_credit_type', 'title' => 'Soft Credit Type', 'where' => 'contribution_softcredit_type.label', - 'data_type' => CRM_Utils_Type::T_STRING + 'data_type' => CRM_Utils_Type::T_STRING, ), 'contribution_soft_credit_contribution_id' => array( 'name' => 'contribution_soft_credit_contribution_id', 'title' => 'Soft Credit For Contribution ID', 'where' => 'civicrm_contribution_soft.contribution_id', - 'data_type' => CRM_Utils_Type::T_INT + 'data_type' => CRM_Utils_Type::T_INT, ), ); @@ -2436,7 +2436,7 @@ WHERE contribution_id = %1 "; $softCreditTypes[$key] = $softCredit['soft_credit_type_label']; $softCredits[$key] = array( 'Name' => $softCredit['contact_name'], - 'Amount' => CRM_Utils_Money::format($softCredit['amount'], $softCredit['currency']) + 'Amount' => CRM_Utils_Money::format($softCredit['amount'], $softCredit['currency']), ); } $template->assign('softCreditTypes', $softCreditTypes); @@ -2527,7 +2527,7 @@ WHERE contribution_id = %1 "; $primaryEmail = CRM_Core_DAO::getFieldValue('CRM_Core_DAO_Email', $this->_relatedObjects['participant']->contact_id, 'email', 'contact_id'); $primaryAmount[] = array( 'label' => $this->_relatedObjects['participant']->fee_level . ' - ' . $primaryEmail, - 'amount' => $this->_relatedObjects['participant']->fee_amount + 'amount' => $this->_relatedObjects['participant']->fee_amount, ); //build an array of cId/pId of participants $additionalIDs = CRM_Event_BAO_Event::buildCustomProfile($this->_relatedObjects['participant']->id, NULL, $this->_relatedObjects['contact']->id, $isTest, TRUE); @@ -2556,7 +2556,7 @@ WHERE contribution_id = %1 "; $amount[0] = array('label' => $additional->fee_level, 'amount' => $additional->fee_amount); $primaryAmount[] = array( 'label' => $additional->fee_level . ' - ' . $additionalParticipantInfo, - 'amount' => $additional->fee_amount + 'amount' => $additional->fee_amount, ); $additional->save(); $additional->free(); @@ -2744,7 +2744,7 @@ WHERE contribution_id = %1 "; $skipRecords = TRUE; $pendingStatus = array( array_search('Pending', $contributionStatuses), - array_search('In Progress', $contributionStatuses) + array_search('In Progress', $contributionStatuses), ); if (in_array(CRM_Utils_Array::value('contribution_status_id', $params), $pendingStatus)) { $relationTypeId = key(CRM_Core_PseudoConstant::accountOptionValues('account_relationship', NULL, " AND v.name LIKE 'Accounts Receivable Account is' ")); @@ -3101,7 +3101,7 @@ WHERE contribution_id = %1 "; 'status_id' => $prevfinancialItem->status_id, 'financial_account_id' => $financialAccount, 'entity_table' => 'civicrm_line_item', - 'entity_id' => $fieldValues['id'] + 'entity_id' => $fieldValues['id'], ); CRM_Financial_BAO_FinancialItem::create($itemParams, NULL, $trxnIds); @@ -3148,13 +3148,13 @@ WHERE contribution_id = %1 "; 'Completed' => array('Cancelled', 'Refunded'), 'Pending' => array('Cancelled', 'Completed', 'Failed'), 'In Progress' => array('Cancelled', 'Completed', 'Failed'), - 'Refunded' => array('Cancelled', 'Completed') + 'Refunded' => array('Cancelled', 'Completed'), ); if (!in_array($contributionStatuses[$fields['contribution_status_id']], $checkStatus[$contributionStatuses[$values['contribution_status_id']]])) { $errors['contribution_status_id'] = ts("Cannot change contribution status from %1 to %2.", array( 1 => $contributionStatuses[$values['contribution_status_id']], - 2 => $contributionStatuses[$fields['contribution_status_id']] + 2 => $contributionStatuses[$fields['contribution_status_id']], )); } } @@ -3201,7 +3201,7 @@ WHERE contribution_id = %1 "; if (!empty($props['contribution_page_id'])) { $page = civicrm_api('contribution_page', 'getsingle', array( 'version' => 3, - 'id' => ($props['contribution_page_id']) + 'id' => ($props['contribution_page_id']), )); $types = (array) CRM_Utils_Array::value('payment_processor', $page, 0); $params['condition'] = 'id IN (' . implode(',', $types) . ')'; @@ -3383,7 +3383,7 @@ WHERE eft.financial_trxn_id IN ({$trxnId}, {$baseTrxnId['financialTrxnId']}) 'amount' => $financialTrxn->total_amount, 'status_id' => array_search('Paid', $financialItemStatus), 'entity_id' => $lineItemId->id, - 'entity_table' => 'civicrm_line_item' + 'entity_table' => 'civicrm_line_item', ); $trxnIds['id'] = $financialTrxn->id; CRM_Financial_BAO_FinancialItem::create($addFinancialEntry, NULL, $trxnIds); diff --git a/CRM/Contribute/BAO/ContributionPage.php b/CRM/Contribute/BAO/ContributionPage.php index 3a8ea68695..4bddc9c061 100644 --- a/CRM/Contribute/BAO/ContributionPage.php +++ b/CRM/Contribute/BAO/ContributionPage.php @@ -875,9 +875,9 @@ LEFT JOIN civicrm_premiums ON ( civicrm_premiums.entity_id = civicrm 'soft_credit_types' => $params['soft_credit_types'], 'default' => array( 'honor_block_title' => $params['honor_block_title'], - 'honor_block_text' => $params['honor_block_text'] - ) - ) + 'honor_block_text' => $params['honor_block_text'], + ), + ), ) ); } @@ -889,9 +889,9 @@ LEFT JOIN civicrm_premiums ON ( civicrm_premiums.entity_id = civicrm 'soft_credit_types' => $params['soft_credit_types'], $config->lcMessages => array( 'honor_block_title' => $params['honor_block_title'], - 'honor_block_text' => $params['honor_block_text'] - ) - ) + 'honor_block_text' => $params['honor_block_text'], + ), + ), ); $ufJoinDAO = new CRM_Core_DAO_UFJoin(); @@ -920,7 +920,7 @@ LEFT JOIN civicrm_premiums ON ( civicrm_premiums.entity_id = civicrm $contactId = array($userID); $pdfParams = array( 'output' => 'pdf_invoice', - 'forPage' => 'confirmpage' + 'forPage' => 'confirmpage', ); $pdfHtml = CRM_Contribute_Form_Task_Invoice::printPDF($contributionID, $pdfParams, $contactId, CRM_Core_DAO::$_nullObject); diff --git a/CRM/Contribute/BAO/ContributionRecur.php b/CRM/Contribute/BAO/ContributionRecur.php index 0e182ad8bd..5b57460bde 100644 --- a/CRM/Contribute/BAO/ContributionRecur.php +++ b/CRM/Contribute/BAO/ContributionRecur.php @@ -274,7 +274,7 @@ SELECT r.payment_processor_id
' . ts('The recurring contribution of %1, every %2 %3 has been cancelled.', array( 1 => $dao->amount, 2 => $dao->frequency_interval, - 3 => $dao->frequency_unit + 3 => $dao->frequency_unit, )); } $activityParams = array( diff --git a/CRM/Contribute/BAO/ContributionSoft.php b/CRM/Contribute/BAO/ContributionSoft.php index a08dbaf5bc..f4a9ec69c3 100644 --- a/CRM/Contribute/BAO/ContributionSoft.php +++ b/CRM/Contribute/BAO/ContributionSoft.php @@ -191,7 +191,7 @@ class CRM_Contribute_BAO_ContributionSoft extends CRM_Contribute_DAO_Contributio 'amount' => $dao->amount, 'contact_name' => $dao->display_name, 'soft_credit_type' => $dao->soft_credit_type_id, - 'soft_credit_type_label' => CRM_Core_OptionGroup::getLabel('soft_credit_type', $dao->soft_credit_type_id) + 'soft_credit_type_label' => CRM_Core_OptionGroup::getLabel('soft_credit_type', $dao->soft_credit_type_id), ); $count++; } @@ -281,7 +281,7 @@ class CRM_Contribute_BAO_ContributionSoft extends CRM_Contribute_DAO_Contributio $params = array( 1 => array($contact_id, 'Integer'), - 2 => array($isTest, 'Integer') + 2 => array($isTest, 'Integer'), ); $cs = CRM_Core_DAO::executeQuery($query, $params); $contributionStatus = CRM_Contribute_PseudoConstant::contributionStatus(); diff --git a/CRM/Contribute/Form/AbstractEditPayment.php b/CRM/Contribute/Form/AbstractEditPayment.php index 9fbe5bbd88..2ec1e69198 100644 --- a/CRM/Contribute/Form/AbstractEditPayment.php +++ b/CRM/Contribute/Form/AbstractEditPayment.php @@ -331,7 +331,7 @@ LEFT JOIN civicrm_contribution on (civicrm_contribution.contact_id = civicrm_co $statusMsg .= "
" . ts("Membership for %1 has been updated. The membership End Date is %2.", array( 1 => $userDisplayName, - 2 => $endDate + 2 => $endDate, ) ); } @@ -550,7 +550,7 @@ LEFT JOIN civicrm_contribution on (civicrm_contribution.contact_id = civicrm_co CRM_Core_Session::setStatus(ts('This contact has a pending or overdue pledge payment of %2 which is scheduled for %3. Click here to enter a pledge payment.', array( 1 => $ppUrl, 2 => $ppAmountDue, - 3 => $ppSchedDate + 3 => $ppSchedDate, )), ts('Notice'), 'alert'); } } diff --git a/CRM/Contribute/Form/AdditionalInfo.php b/CRM/Contribute/Form/AdditionalInfo.php index 5578c80797..d69fc40fed 100644 --- a/CRM/Contribute/Form/AdditionalInfo.php +++ b/CRM/Contribute/Form/AdditionalInfo.php @@ -154,7 +154,7 @@ class CRM_Contribute_Form_AdditionalInfo { $form->add('select', 'contribution_page_id', ts('Online Contribution Page'), array( - '' => ts('- select -') + '' => ts('- select -'), ) + CRM_Contribute_PseudoConstant::contributionPage() ); @@ -239,7 +239,7 @@ class CRM_Contribute_Form_AdditionalInfo { 'cost' => CRM_Utils_Array::value('cost', $productDetails), 'currency' => CRM_Utils_Array::value('currency', $productDetails), 'financial_type_id' => CRM_Utils_Array::value('financial_type_id', $productDetails), - 'contributionId' => $contributionID + 'contributionId' => $contributionID, ); if ($isDeleted) { $params['oldPremium']['product_id'] = $premoumDAO->product_id; @@ -356,7 +356,7 @@ class CRM_Contribute_Form_AdditionalInfo { foreach ($params['soft_credit'] as $key => $softCredit) { $softCredits[$key] = array( 'Name' => $softCredit['contact_name'], - 'Amount' => CRM_Utils_Money::format($softCredit['amount'], $softCredit['currency']) + 'Amount' => CRM_Utils_Money::format($softCredit['amount'], $softCredit['currency']), ); $softCreditTypes[$key] = $softCredit['soft_credit_type_label']; } diff --git a/CRM/Contribute/Form/AdditionalPayment.php b/CRM/Contribute/Form/AdditionalPayment.php index 1bbd022802..43b7d059f9 100644 --- a/CRM/Contribute/Form/AdditionalPayment.php +++ b/CRM/Contribute/Form/AdditionalPayment.php @@ -245,7 +245,7 @@ class CRM_Contribute_Form_AdditionalPayment extends CRM_Contribute_Form_Abstract $allPanes[$name] = array( 'url' => CRM_Utils_System::url('civicrm/payment/add', $urlParams), 'open' => $open, - 'id' => $type + 'id' => $type, ); CRM_Core_Payment_Form::buildPaymentForm($this, $this->_paymentProcessor, FALSE); @@ -325,11 +325,11 @@ class CRM_Contribute_Form_AdditionalPayment extends CRM_Contribute_Form_Abstract 'type' => 'upload', 'name' => ts('%1', array(1 => $buttonName)), 'js' => $js, - 'isDefault' => TRUE + 'isDefault' => TRUE, ), array( 'type' => 'cancel', - 'name' => ts('Cancel') + 'name' => ts('Cancel'), ), ) ); diff --git a/CRM/Contribute/Form/CancelSubscription.php b/CRM/Contribute/Form/CancelSubscription.php index 3de3847f04..bea89c7fe5 100644 --- a/CRM/Contribute/Form/CancelSubscription.php +++ b/CRM/Contribute/Form/CancelSubscription.php @@ -260,7 +260,7 @@ class CRM_Contribute_Form_CancelSubscription extends CRM_Core_Form { array( 1 => $this->_subscriptionDetails->amount, 2 => $this->_subscriptionDetails->frequency_interval, - 3 => $this->_subscriptionDetails->frequency_unit + 3 => $this->_subscriptionDetails->frequency_unit, ) ); $msgTitle = 'Contribution Cancelled'; diff --git a/CRM/Contribute/Form/Contribution.php b/CRM/Contribute/Form/Contribution.php index 0019c2bd0e..ea33e63a00 100644 --- a/CRM/Contribute/Form/Contribution.php +++ b/CRM/Contribute/Form/Contribution.php @@ -597,7 +597,7 @@ class CRM_Contribute_Form_Contribution extends CRM_Contribute_Form_AbstractEditP $allPanes[$name] = array( 'url' => CRM_Utils_System::url('civicrm/contact/view/contribution', $urlParams), 'open' => $open, - 'id' => $type + 'id' => $type, ); // see if we need to include this paneName in the current form @@ -647,8 +647,8 @@ class CRM_Contribute_Form_Contribution extends CRM_Contribute_Form_AbstractEditP ), array( 'type' => 'cancel', - 'name' => ts('Cancel') - ) + 'name' => ts('Cancel'), + ), ) ); return; @@ -695,7 +695,7 @@ class CRM_Contribute_Form_Contribution extends CRM_Contribute_Form_AbstractEditP foreach (array( 'Cancelled', 'Failed', - 'In Progress' + 'In Progress', ) as $suppress) { unset($status[CRM_Utils_Array::key($suppress, $statusName)]); } @@ -711,7 +711,7 @@ class CRM_Contribute_Form_Contribution extends CRM_Contribute_Form_AbstractEditP if (!$suppressFlag) { foreach (array( 'Overdue', - 'In Progress' + 'In Progress', ) as $suppress) { unset($status[CRM_Utils_Array::key($suppress, $statusName)]); } @@ -742,7 +742,7 @@ class CRM_Contribute_Form_Contribution extends CRM_Contribute_Form_AbstractEditP 'Refunded', 'Completed', 'In Progress', - 'Cancelled' + 'Cancelled', ) as $suppress) { unset($status[CRM_Utils_Array::key($suppress, $statusName)]); } @@ -820,7 +820,7 @@ class CRM_Contribute_Form_Contribution extends CRM_Contribute_Form_AbstractEditP $hasPriceSets = TRUE; $element = $this->add('select', 'price_set_id', ts('Choose price set'), array( - '' => ts('Choose price set') + '' => ts('Choose price set'), ) + $priceSets, NULL, array('onchange' => "buildAmount( this.value );") ); @@ -834,7 +834,7 @@ class CRM_Contribute_Form_Contribution extends CRM_Contribute_Form_AbstractEditP if ($this->_online || $this->_ppID) { $attributes['total_amount'] = array_merge($attributes['total_amount'], array( 'READONLY' => TRUE, - 'style' => "background-color:#EBECE4" + 'style' => "background-color:#EBECE4", )); $optionTypes = array( '1' => ts('Adjust Pledge Payment Schedule?'), @@ -880,17 +880,17 @@ class CRM_Contribute_Form_Contribution extends CRM_Contribute_Form_AbstractEditP 'type' => 'upload', 'name' => ts('Save'), 'js' => $js, - 'isDefault' => TRUE + 'isDefault' => TRUE, ), array( 'type' => 'upload', 'name' => ts('Save and New'), 'js' => $js, - 'subName' => 'new' + 'subName' => 'new', ), array( 'type' => 'cancel', - 'name' => ts('Cancel') + 'name' => ts('Cancel'), ), ) ); @@ -1082,7 +1082,7 @@ class CRM_Contribute_Form_Contribution extends CRM_Contribute_Form_AbstractEditP $isRelatedId = FALSE; $participantParams = array( 'fee_amount' => $submittedValues['total_amount'], - 'id' => $entityID + 'id' => $entityID, ); CRM_Event_BAO_Participant::add($participantParams); if (empty($this->_lineItems)) { diff --git a/CRM/Contribute/Form/Contribution/Confirm.php b/CRM/Contribute/Form/Contribution/Confirm.php index 46f58f679d..bda9b01a8b 100644 --- a/CRM/Contribute/Form/Contribution/Confirm.php +++ b/CRM/Contribute/Form/Contribution/Confirm.php @@ -111,7 +111,7 @@ class CRM_Contribute_Form_Contribution_Confirm extends CRM_Contribute_Form_Contr //setting to make available to hook - although seems wrong to set on form for BAO hook availability 'soft_credit_to' => $softCreditToID, 'line_item' => $lineItems, - 'skipLineItem' => CRM_Utils_Array::value('skipLineItem', $params, 0) + 'skipLineItem' => CRM_Utils_Array::value('skipLineItem', $params, 0), ); if (!$online && isset($params['thankyou_date'])) { $contributionParam['thankyou_date'] = $params['thankyou_date']; @@ -403,7 +403,7 @@ class CRM_Contribute_Form_Contribution_Confirm extends CRM_Contribute_Form_Contr foreach (array( 'phone', 'email', - 'address' + 'address', ) as $blk) { if (isset($this->_params[$blk])) { unset($this->_params[$blk]); @@ -613,7 +613,7 @@ class CRM_Contribute_Form_Contribution_Confirm extends CRM_Contribute_Form_Contr foreach ($contact[$name] as $fieldName => $fieldValue) { if (is_array($fieldValue) && !in_array($this->_fields[$name][$fieldName]['html_type'], array( 'Multi-Select', - 'AdvMulti-Select' + 'AdvMulti-Select', )) ) { foreach ($fieldValue as $key => $value) { @@ -639,7 +639,7 @@ class CRM_Contribute_Form_Contribution_Confirm extends CRM_Contribute_Form_Contr elseif (in_array($name, array( 'addressee', 'email_greeting', - 'postal_greeting' + 'postal_greeting', )) && !empty($contact[$name . '_custom']) ) { $defaults[$name . '_custom'] = $contact[$name . '_custom']; @@ -782,7 +782,7 @@ class CRM_Contribute_Form_Contribution_Confirm extends CRM_Contribute_Form_Contr elseif (!(strstr($fld, '-'))) { if (in_array($fld, array( 'contribution_campaign_id', - 'member_campaign_id' + 'member_campaign_id', ))) { $fld = 'campaign_id'; } @@ -1194,7 +1194,7 @@ class CRM_Contribute_Form_Contribution_Confirm extends CRM_Contribute_Form_Contr 'cost' => $productDAO->cost, 'currency' => $productDAO->currency, 'financial_type_id' => $params['financial_type_id'], - 'contributionId' => $contribution->id + 'contributionId' => $contribution->id, ); CRM_Core_BAO_FinancialTrxn::createPremiumTrxn($trxnParams); } @@ -1752,7 +1752,7 @@ class CRM_Contribute_Form_Contribution_Confirm extends CRM_Contribute_Form_Contr 'pcp_display_in_roll', 'pcp_roll_nickname', 'pcp_personal_note', - 'amount' + 'amount', ) as $val) { if (!empty($params[$val])) { $contributionSoftParams[$val] = $params[$val]; @@ -1797,7 +1797,7 @@ class CRM_Contribute_Form_Contribution_Confirm extends CRM_Contribute_Form_Contr 'pcp_display_in_roll', 'pcp_is_anonymous', 'pcp_roll_nickname', - 'pcp_personal_note' + 'pcp_personal_note', ) as $val) { if (!empty($params[$val])) { $page->assign($val, $params[$val]); @@ -1994,7 +1994,7 @@ class CRM_Contribute_Form_Contribution_Confirm extends CRM_Contribute_Form_Contr else { $params['is_pay_later'] = civicrm_api3('contribution_page', 'getvalue', array( 'id' => $id, - 'return' => 'is_pay_later' + 'return' => 'is_pay_later', )); } } diff --git a/CRM/Contribute/Form/ContributionPage/Settings.php b/CRM/Contribute/Form/ContributionPage/Settings.php index 461ba5fd63..d3d437a5bb 100644 --- a/CRM/Contribute/Form/ContributionPage/Settings.php +++ b/CRM/Contribute/Form/ContributionPage/Settings.php @@ -89,7 +89,7 @@ class CRM_Contribute_Form_ContributionPage_Settings extends CRM_Contribute_Form_ } $defaults['soft_credit_types'] = array( CRM_Utils_Array::value('in_honor_of', $soft_credit_types), - CRM_Utils_Array::value('in_memory_of', $soft_credit_types) + CRM_Utils_Array::value('in_memory_of', $soft_credit_types), ); } } @@ -103,7 +103,7 @@ class CRM_Contribute_Form_ContributionPage_Settings extends CRM_Contribute_Form_ } $defaults['soft_credit_types'] = array( CRM_Utils_Array::value('in_honor_of', $soft_credit_types), - CRM_Utils_Array::value('in_memory_of', $soft_credit_types) + CRM_Utils_Array::value('in_memory_of', $soft_credit_types), ); } @@ -181,7 +181,7 @@ class CRM_Contribute_Form_ContributionPage_Settings extends CRM_Contribute_Form_ 'entity' => 'ContributionSoft', 'field' => 'soft_credit_type_id', 'multiple' => TRUE, - 'class' => 'huge' + 'class' => 'huge', )); $entities = array( @@ -344,7 +344,7 @@ class CRM_Contribute_Form_ContributionPage_Settings extends CRM_Contribute_Form_ 'module' => 'soft_credit', 'entity_table' => 'civicrm_contribution_page', 'entity_id' => $dao->id, - ) + ), ); foreach ($ufJoinParams as $index => $ufJoinParam) { diff --git a/CRM/Contribute/Form/Task/Invoice.php b/CRM/Contribute/Form/Task/Invoice.php index c5439c4cd6..868d333abc 100644 --- a/CRM/Contribute/Form/Task/Invoice.php +++ b/CRM/Contribute/Form/Task/Invoice.php @@ -124,7 +124,7 @@ class CRM_Contribute_Form_Task_Invoice extends CRM_Contribute_Form_Task { array( 'url' => $url, 'title' => ts('Search Results'), - ) + ), ); CRM_Utils_System::appendBreadCrumb($breadCrumb); @@ -188,7 +188,7 @@ class CRM_Contribute_Form_Task_Invoice extends CRM_Contribute_Form_Task { $this->addWysiwyg('email_comment', ts('If you would like to add personal message to email please add it here. (If sending to more then one receipient the same message will be sent to each contact.)'), array( 'rows' => 2, - 'cols' => 40 + 'cols' => 40, )); $this->addButtons(array( @@ -553,7 +553,7 @@ class CRM_Contribute_Form_Task_Invoice extends CRM_Contribute_Form_Task { CRM_Utils_PDF_Utils::html2pdf($messageInvoice, 'Invoice.pdf', FALSE, array( 'margin_top' => 10, 'margin_left' => 65, - 'metric' => 'px' + 'metric' => 'px', )); // functions call for adding activity with attachment $fileName = self::putFile($html); diff --git a/CRM/Contribute/Form/Task/PDFLetterCommon.php b/CRM/Contribute/Form/Task/PDFLetterCommon.php index fe086d97e0..ec4b55adfe 100644 --- a/CRM/Contribute/Form/Task/PDFLetterCommon.php +++ b/CRM/Contribute/Form/Task/PDFLetterCommon.php @@ -21,7 +21,7 @@ class CRM_Contribute_Form_Task_PDFLetterCommon extends CRM_Contact_Form_Task_PDF if (!empty($formValues['email_options'])) { $returnProperties['email'] = $returnProperties['on_hold'] = $returnProperties['is_deceased'] = $returnProperties['do_not_email'] = 1; $emailParams = array( - 'subject' => $formValues['subject'] + 'subject' => $formValues['subject'], ); // We need display_name for emailLetter() so add to returnProperties here $returnProperties['display_name'] = 1; diff --git a/CRM/Contribute/Form/UpdateBilling.php b/CRM/Contribute/Form/UpdateBilling.php index c412f07b23..83b5244c54 100644 --- a/CRM/Contribute/Form/UpdateBilling.php +++ b/CRM/Contribute/Form/UpdateBilling.php @@ -295,7 +295,7 @@ class CRM_Contribute_Form_UpdateBilling extends CRM_Core_Form { array( 1 => $this->_subscriptionDetails->amount, 2 => $this->_subscriptionDetails->frequency_interval, - 3 => $this->_subscriptionDetails->frequency_unit + 3 => $this->_subscriptionDetails->frequency_unit, ) ); $msgTitle = ts('Details Updated'); diff --git a/CRM/Contribute/Form/UpdateSubscription.php b/CRM/Contribute/Form/UpdateSubscription.php index 1ab480f7f1..7b934fbcec 100644 --- a/CRM/Contribute/Form/UpdateSubscription.php +++ b/CRM/Contribute/Form/UpdateSubscription.php @@ -216,7 +216,7 @@ class CRM_Contribute_Form_UpdateSubscription extends CRM_Core_Form { array(1 => CRM_Utils_Money::format($params['amount'], $this->_subscriptionDetails->currency), 2 => $this->_subscriptionDetails->frequency_interval, 3 => $this->_subscriptionDetails->frequency_unit, - 4 => $params['installments'] + 4 => $params['installments'], ) ); @@ -229,7 +229,7 @@ class CRM_Contribute_Form_UpdateSubscription extends CRM_Core_Form { $message .= "
" . ts("Recurring contribution amount has been updated from %1 to %2 for this subscription.", array( 1 => CRM_Utils_Money::format($this->_subscriptionDetails->amount, $this->_subscriptionDetails->currency), - 2 => CRM_Utils_Money::format($params['amount'], $this->_subscriptionDetails->currency) + 2 => CRM_Utils_Money::format($params['amount'], $this->_subscriptionDetails->currency), )) . ' '; } diff --git a/CRM/Contribute/Import/Form/MapField.php b/CRM/Contribute/Import/Form/MapField.php index 288769ed41..53457aa84c 100644 --- a/CRM/Contribute/Import/Form/MapField.php +++ b/CRM/Contribute/Import/Form/MapField.php @@ -390,7 +390,7 @@ class CRM_Contribute_Import_Form_MapField extends CRM_Import_Form_MapField { $requiredFields = array( $contactORContributionId == 'contribution_id' ? 'contribution_id' : 'contribution_contact_id' => $contactORContributionId == 'contribution_id' ? ts('Contribution ID') : ts('Contact ID'), 'total_amount' => ts('Total Amount'), - 'financial_type' => ts('Financial Type') + 'financial_type' => ts('Financial Type'), ); foreach ($requiredFields as $field => $title) { @@ -403,7 +403,7 @@ class CRM_Contribute_Import_Form_MapField extends CRM_Import_Form_MapField { $self->_onDuplicate != CRM_Import_Parser::DUPLICATE_UPDATE ) { $errors['_qf_default'] .= ts('Missing required contact matching fields.') . " $fieldMessage " . ts('(Sum of all weights should be greater than or equal to threshold: %1).', array( - 1 => $threshold + 1 => $threshold, )) . '
'; } elseif ($self->_onDuplicate == CRM_Import_Parser::DUPLICATE_UPDATE && @@ -416,7 +416,7 @@ class CRM_Contribute_Import_Form_MapField extends CRM_Import_Form_MapField { } else { $errors['_qf_default'] .= ts('Missing required field: %1', array( - 1 => $title + 1 => $title, )) . '
'; } } diff --git a/CRM/Contribute/Import/Parser/Contribution.php b/CRM/Contribute/Import/Parser/Contribution.php index 1363ddd189..c3fa579c94 100644 --- a/CRM/Contribute/Import/Parser/Contribution.php +++ b/CRM/Contribute/Import/Parser/Contribution.php @@ -78,7 +78,7 @@ class CRM_Contribute_Import_Parser_Contribution extends CRM_Contribute_Import_Pa 'title' => ts('Soft Credit'), 'softCredit' => TRUE, 'headerPattern' => '/Soft Credit/i', - ) + ), ) ); diff --git a/CRM/Contribute/Selector/Search.php b/CRM/Contribute/Selector/Search.php index 05e2ae2cc1..4018246014 100644 --- a/CRM/Contribute/Selector/Search.php +++ b/CRM/Contribute/Selector/Search.php @@ -463,7 +463,7 @@ class CRM_Contribute_Selector_Search extends CRM_Core_Selector_Base implements C 'name' => ts('Soft Credit Amount'), 'sort' => 'contribution_soft_credit_amount', 'direction' => CRM_Utils_Sort::DONTCARE, - ) + ), ) ); } @@ -535,7 +535,7 @@ class CRM_Contribute_Selector_Search extends CRM_Core_Selector_Base implements C self::$_columnHeaders = array_merge( self::$_columnHeaders, array( - array('desc' => ts('Actions')) + array('desc' => ts('Actions')), ) ); return self::$_columnHeaders; diff --git a/CRM/Core/BAO/Address.php b/CRM/Core/BAO/Address.php index c74aa7a073..5c326b85a9 100644 --- a/CRM/Core/BAO/Address.php +++ b/CRM/Core/BAO/Address.php @@ -997,7 +997,7 @@ SELECT is_primary, // CRM-15120 $formatted = array( 'first_name' => $rows[$rowID]['first_name'], - 'individual_prefix' => $rows[$rowID]['individual_prefix'] + 'individual_prefix' => $rows[$rowID]['individual_prefix'], ); $format = CRM_Core_BAO_Setting::getItem(CRM_Core_BAO_Setting::SYSTEM_PREFERENCES_NAME, 'display_name_format'); $firstNameWithPrefix = CRM_Utils_Address::format($formatted, $format, FALSE, FALSE, TRUE); diff --git a/CRM/Core/BAO/Block.php b/CRM/Core/BAO/Block.php index dcffc8bd93..a0ec8c8086 100644 --- a/CRM/Core/BAO/Block.php +++ b/CRM/Core/BAO/Block.php @@ -44,7 +44,7 @@ class CRM_Core_BAO_Block { 'email' => array('email'), 'phone' => array('phone'), 'im' => array('name'), - 'openid' => array('openid') + 'openid' => array('openid'), ); /** diff --git a/CRM/Core/BAO/CMSUser.php b/CRM/Core/BAO/CMSUser.php index 42f0d44f4d..a359d183d6 100644 --- a/CRM/Core/BAO/CMSUser.php +++ b/CRM/Core/BAO/CMSUser.php @@ -197,14 +197,14 @@ class CRM_Core_BAO_CMSUser { $status .= ' ' . ts('Checked one user record.', array( 'count' => $contactCount, - 'plural' => 'Checked %count user records.' + 'plural' => 'Checked %count user records.', ) ); if ($contactMatching) { $status .= ' ' . ts('Found one matching contact record.', array( 'count' => $contactMatching, - 'plural' => 'Found %count matching contact records.' + 'plural' => 'Found %count matching contact records.', ) ); } @@ -212,7 +212,7 @@ class CRM_Core_BAO_CMSUser { $status .= ' ' . ts('Created one new contact record.', array( 'count' => $contactCreated, - 'plural' => 'Created %count new contact records.' + 'plural' => 'Created %count new contact records.', ) ); CRM_Core_Session::setStatus($status, ts('Saved'), 'success'); diff --git a/CRM/Core/BAO/CustomField.php b/CRM/Core/BAO/CustomField.php index 2d0f385674..eccf8d0b0d 100644 --- a/CRM/Core/BAO/CustomField.php +++ b/CRM/Core/BAO/CustomField.php @@ -200,7 +200,7 @@ class CRM_Core_BAO_CustomField extends CRM_Core_DAO_CustomField { 'String', 'Int', 'Float', - 'Money' + 'Money', )) ) { @@ -788,13 +788,13 @@ class CRM_Core_BAO_CustomField extends CRM_Core_DAO_CustomField { 'Multi-Select Country', 'AdvMulti-Select', 'CheckBox', - 'Radio' + 'Radio', ))); if ($isSelect) { $options = CRM_Utils_Array::value('values', civicrm_api3('contact', 'getoptions', array( 'field' => "custom_$fieldId", - 'context' => $search ? 'search' : 'create' + 'context' => $search ? 'search' : 'create', ), array())); // Consolidate widget types to simplify the below switch statement @@ -989,7 +989,7 @@ class CRM_Core_BAO_CustomField extends CRM_Core_DAO_CustomField { $attributes = array( 'rows' => $field->note_rows, 'cols' => $field->note_columns, - 'data-crm-custom' => $dataCrmCustomVal + 'data-crm-custom' => $dataCrmCustomVal, ); if ($field->text_length) { $attributes['maxlength'] = $field->text_length; diff --git a/CRM/Core/BAO/CustomGroup.php b/CRM/Core/BAO/CustomGroup.php index 24fee26246..c077771d7b 100644 --- a/CRM/Core/BAO/CustomGroup.php +++ b/CRM/Core/BAO/CustomGroup.php @@ -96,7 +96,7 @@ class CRM_Core_BAO_CustomGroup extends CRM_Core_DAO_CustomGroup { if (CRM_Utils_Array::value(0, $params['extends']) == 'Relationship') { $extendsChildType = str_replace(array('_a_b', '_b_a'), array( '', - '' + '', ), $extendsChildType); } if (substr($extendsChildType, 0, 1) != CRM_Core_DAO::VALUE_SEPARATOR) { @@ -123,7 +123,7 @@ class CRM_Core_BAO_CustomGroup extends CRM_Core_DAO_CustomGroup { 'help_pre', 'help_post', 'is_active', - 'is_multiple' + 'is_multiple', ); foreach ($fields as $field) { $group->$field = CRM_Utils_Array::value($field, $params, FALSE); @@ -377,7 +377,7 @@ class CRM_Core_BAO_CustomGroup extends CRM_Core_DAO_CustomGroup { 'date_format', 'time_format', 'option_group_id', - 'in_selector' + 'in_selector', ), 'civicrm_custom_group' => array( 'id', @@ -610,7 +610,7 @@ ORDER BY civicrm_custom_group.weight, $groupTree['info']['from'][] = $table; $select = array( "{$table}.id as {$table}_id", - "{$table}.entity_id as {$table}_entity_id" + "{$table}.entity_id as {$table}_entity_id", ); foreach ($fields as $column => $dontCare) { $select[] = "{$table}.{$column} as {$table}_{$column}"; @@ -1610,7 +1610,7 @@ ORDER BY civicrm_custom_group.weight, 'Multi-Select', 'AdvMulti-Select', 'Select', - 'Radio' + 'Radio', ); foreach ($groupTree as $group) { @@ -2024,7 +2024,7 @@ SELECT IF( EXISTS(SELECT name FROM civicrm_contact_type WHERE name like %1), 1, 'dd-mm' => "%E%f %B $customTimeFormat", 'yy' => "%Y $customTimeFormat", 'M yy' => "%b %Y $customTimeFormat", - 'yy-mm' => "%Y-%m $customTimeFormat" + 'yy-mm' => "%Y-%m $customTimeFormat", ); if ($format = CRM_Utils_Array::value('date_format', $field)) { diff --git a/CRM/Core/BAO/CustomValueTable.php b/CRM/Core/BAO/CustomValueTable.php index e5d0334885..4ee8074298 100644 --- a/CRM/Core/BAO/CustomValueTable.php +++ b/CRM/Core/BAO/CustomValueTable.php @@ -583,7 +583,7 @@ AND cf.id IN ( $fieldIDList ) return CRM_Core_Error::createAPIError(ts('value: %1 is not of the right field data type: %2', array( 1 => $fieldValue['value'], - 2 => $dao->data_type + 2 => $dao->data_type, ) )); } diff --git a/CRM/Core/BAO/Domain.php b/CRM/Core/BAO/Domain.php index 6cb255d2bb..ad04e30ce3 100644 --- a/CRM/Core/BAO/Domain.php +++ b/CRM/Core/BAO/Domain.php @@ -141,7 +141,7 @@ class CRM_Core_BAO_Domain extends CRM_Core_DAO_Domain { if ($this->_location == NULL) { $domain = self::getDomain(NULL); $params = array( - 'contact_id' => $domain->contact_id + 'contact_id' => $domain->contact_id, ); $this->_location = CRM_Core_BAO_Location::getValues($params, TRUE); diff --git a/CRM/Core/BAO/File.php b/CRM/Core/BAO/File.php index 097beaa2e3..5538b9282d 100644 --- a/CRM/Core/BAO/File.php +++ b/CRM/Core/BAO/File.php @@ -251,7 +251,7 @@ class CRM_Core_BAO_File extends CRM_Core_DAO_File { //delete tags from entity tag table $tagParams = array( 'entity_table' => 'civicrm_file', - 'entity_id' => $fId + 'entity_id' => $fId, ); CRM_Core_BAO_EntityTag::del($tagParams); @@ -442,7 +442,7 @@ AND CEF.entity_id = %2"; $form->addElement('text', "attachDesc_$i", NULL, array( 'size' => 40, 'maxlength' => 255, - 'placeholder' => ts('Description') + 'placeholder' => ts('Description'), )); if (!empty($tags)) { @@ -451,7 +451,7 @@ AND CEF.entity_id = %2"; 'id' => "tags_$i", 'multiple' => 'multiple', 'class' => 'huge crm-select2', - 'placeholder' => ts('- none -') + 'placeholder' => ts('- none -'), ) ); } @@ -535,7 +535,7 @@ AND CEF.entity_id = %2"; 'description' => $formValues[$attachDesc], 'upload_date' => $now, 'tag' => $tagParams, - 'attachment_taglist' => CRM_Utils_Array::value($attachFreeTags, $formValues, array()) + 'attachment_taglist' => CRM_Utils_Array::value($attachFreeTags, $formValues, array()), ); $params[$attachName] = $fileParams; diff --git a/CRM/Core/BAO/FinancialTrxn.php b/CRM/Core/BAO/FinancialTrxn.php index ce87300849..170c4d7700 100644 --- a/CRM/Core/BAO/FinancialTrxn.php +++ b/CRM/Core/BAO/FinancialTrxn.php @@ -335,7 +335,7 @@ WHERE ceft.entity_id = %1"; 'trxn_date' => date('YmdHis'), 'total_amount' => CRM_Utils_Array::value('cost', $params) ? $params['cost'] : 0, 'currency' => CRM_Utils_Array::value('currency', $params), - 'status_id' => array_search('Completed', $contributionStatuses) + 'status_id' => array_search('Completed', $contributionStatuses), ); $trxnEntityTable['entity_table'] = 'civicrm_contribution'; $trxnEntityTable['entity_id'] = $params['contributionId']; @@ -344,7 +344,7 @@ WHERE ceft.entity_id = %1"; if (!empty($params['oldPremium'])) { $premiumParams = array( - 'id' => $params['oldPremium']['product_id'] + 'id' => $params['oldPremium']['product_id'], ); $productDetails = array(); CRM_Contribute_BAO_ManagePremiums::retrieve($premiumParams, $productDetails); @@ -353,7 +353,7 @@ WHERE ceft.entity_id = %1"; 'currency' => CRM_Utils_Array::value('currency', $productDetails), 'financial_type_id' => CRM_Utils_Array::value('financial_type_id', $productDetails), 'contributionId' => $params['oldPremium']['contribution_id'], - 'isDeleted' => TRUE + 'isDeleted' => TRUE, ); CRM_Core_BAO_FinancialTrxn::createPremiumTrxn($params); } diff --git a/CRM/Core/BAO/Mapping.php b/CRM/Core/BAO/Mapping.php index d148cf0cbe..0877c23b28 100644 --- a/CRM/Core/BAO/Mapping.php +++ b/CRM/Core/BAO/Mapping.php @@ -1022,7 +1022,7 @@ class CRM_Core_BAO_Mapping extends CRM_Core_DAO_Mapping { 'Multi-Select', 'AdvMulti-Select', 'Multi-Select State/Province', - 'Multi-Select Country' + 'Multi-Select Country', ); // override the operator to handle separator ( note: this might have some performance issues ) diff --git a/CRM/Core/BAO/SchemaHandler.php b/CRM/Core/BAO/SchemaHandler.php index 0ebe06e597..1da5fcdb32 100644 --- a/CRM/Core/BAO/SchemaHandler.php +++ b/CRM/Core/BAO/SchemaHandler.php @@ -516,7 +516,7 @@ MODIFY {$columnName} varchar( $length ) array( 1 => $tableName, 2 => $columnName, - 3 => $customFieldID + 3 => $customFieldID, ) )); } diff --git a/CRM/Core/BAO/UFField.php b/CRM/Core/BAO/UFField.php index 0f698b1635..9ad651613b 100644 --- a/CRM/Core/BAO/UFField.php +++ b/CRM/Core/BAO/UFField.php @@ -825,7 +825,7 @@ SELECT id 'city', 'state_province', 'postal_code', - 'country' + 'country', ); $requiredBillingFields = array_diff($validBillingFields, array('middle_name', 'supplemental_address_1')); $validProfileFields = array(); diff --git a/CRM/Core/BAO/UFGroup.php b/CRM/Core/BAO/UFGroup.php index 928ca8d293..0ad80bebb1 100644 --- a/CRM/Core/BAO/UFGroup.php +++ b/CRM/Core/BAO/UFGroup.php @@ -1018,7 +1018,7 @@ class CRM_Core_BAO_UFGroup extends CRM_Core_DAO_UFGroup { elseif (in_array($name, array( 'state_province', 'country', - 'county' + 'county', ))) { $values[$index] = $details->$name; $idx = $name . '_id'; @@ -1183,7 +1183,7 @@ class CRM_Core_BAO_UFGroup extends CRM_Core_DAO_UFGroup { 'deceased_date', 'membership_start_date', 'membership_end_date', - 'join_date' + 'join_date', ))) { $values[$index] = CRM_Utils_Date::customFormat($details->$name); $params[$index] = CRM_Utils_Date::isoToMysql($details->$name); @@ -1233,7 +1233,7 @@ class CRM_Core_BAO_UFGroup extends CRM_Core_DAO_UFGroup { 'phone', 'im', 'email', - 'openid' + 'openid', ))) { if ($type) { $detailName .= "-{$type}"; @@ -1243,7 +1243,7 @@ class CRM_Core_BAO_UFGroup extends CRM_Core_DAO_UFGroup { if (in_array($fieldName, array( 'state_province', 'country', - 'county' + 'county', ))) { $values[$index] = $details->$detailName; $idx = $detailName . '_id'; @@ -1449,7 +1449,7 @@ class CRM_Core_BAO_UFGroup extends CRM_Core_DAO_UFGroup { 'is_update_dupe', 'is_edit_link', 'is_uf_link', - 'is_cms_user' + 'is_cms_user', ); foreach ($fields as $field) { $params[$field] = CRM_Utils_Array::value($field, $params, FALSE); @@ -1883,7 +1883,7 @@ AND ( entity_id IS NULL OR entity_id <= 0 ) $config = CRM_Core_Config::singleton(); if (!in_array($mode, array( CRM_Profile_Form::MODE_EDIT, - CRM_Profile_Form::MODE_SEARCH + CRM_Profile_Form::MODE_SEARCH, )) && $config->defaultContactStateProvince ) { @@ -1896,7 +1896,7 @@ AND ( entity_id IS NULL OR entity_id <= 0 ) $config = CRM_Core_Config::singleton(); if (!in_array($mode, array( CRM_Profile_Form::MODE_EDIT, - CRM_Profile_Form::MODE_SEARCH + CRM_Profile_Form::MODE_SEARCH, )) && $config->defaultContactCountry ) { @@ -1922,14 +1922,14 @@ AND ( entity_id IS NULL OR entity_id <= 0 ) } $form->add('select', $providerName, NULL, array( - '' => ts('- select -') + '' => ts('- select -'), ) + CRM_Core_PseudoConstant::get('CRM_Core_DAO_IM', 'provider_id'), $required ); } else { $form->add('select', $name . '-provider_id', $title, array( - '' => ts('- select -') + '' => ts('- select -'), ) + CRM_Core_PseudoConstant::get('CRM_Core_DAO_IM', 'provider_id'), $required ); } @@ -1945,7 +1945,7 @@ AND ( entity_id IS NULL OR entity_id <= 0 ) elseif (in_array($fieldName, array( 'membership_start_date', 'membership_end_date', - 'join_date' + 'join_date', ))) { $form->addDate($name, $title, $required, array('formatType' => 'custom')); } @@ -1969,7 +1969,7 @@ AND ( entity_id IS NULL OR entity_id <= 0 ) elseif (CRM_Utils_Array::value('name', $field) == 'membership_status') { $form->add('select', $name, $title, array( - '' => ts('- select -') + '' => ts('- select -'), ) + CRM_Member_PseudoConstant::membershipStatus(NULL, NULL, 'label'), $required ); } @@ -2039,7 +2039,7 @@ AND ( entity_id IS NULL OR entity_id <= 0 ) 'Contact', 'Contribution', 'Participant', - 'Membership' + 'Membership', )) ) { $profileType = 'Individual'; @@ -2053,7 +2053,7 @@ AND ( entity_id IS NULL OR entity_id <= 0 ) ); $form->add('select', $name, $title, array( - '' => ts('- select -') + '' => ts('- select -'), ) + CRM_Core_PseudoConstant::greeting($greeting), $required ); // add custom greeting element @@ -2136,7 +2136,7 @@ AND ( entity_id IS NULL OR entity_id <= 0 ) 'receive_date', 'receipt_date', 'thankyou_date', - 'cancel_date' + 'cancel_date', ))) { $form->addDateTime($name, $title, $required, array('formatType' => 'activityDateTime')); } @@ -2151,7 +2151,7 @@ AND ( entity_id IS NULL OR entity_id <= 0 ) list($products, $options) = CRM_Contribute_BAO_Premium::getPremiumProductInfo(); $sel = &$form->addElement('hierselect', $name, $title); $products = array( - '0' => ts('- select -') + '0' => ts('- select -'), ) + $products; $sel->setOptions(array($products, $options)); } @@ -2162,7 +2162,7 @@ AND ( entity_id IS NULL OR entity_id <= 0 ) elseif ($fieldName == 'financial_type') { $form->add('select', $name, $title, array( - '' => ts('- select -') + '' => ts('- select -'), ) + CRM_Contribute_PseudoConstant::financialType(), $required ); } @@ -2172,14 +2172,14 @@ AND ( entity_id IS NULL OR entity_id <= 0 ) foreach (array( 'In Progress', 'Overdue', - 'Refunded' + 'Refunded', ) as $suppress) { unset($contributionStatuses[CRM_Utils_Array::key($suppress, $statusName)]); } $form->add('select', $name, $title, array( - '' => ts('- select -') + '' => ts('- select -'), ) + $contributionStatuses, $required ); } @@ -2187,7 +2187,7 @@ AND ( entity_id IS NULL OR entity_id <= 0 ) $name = "soft_credit_type[$rowNumber]"; $form->add('select', $name, $title, array( - '' => ts('- select -') + '' => ts('- select -'), ) + CRM_Core_OptionGroup::values("soft_credit_type") ); //CRM-15350: choose SCT field default value as 'Gift' for membership use @@ -2204,7 +2204,7 @@ AND ( entity_id IS NULL OR entity_id <= 0 ) elseif ($fieldName == 'contribution_page_id') { $form->add('select', $name, $title, array( - '' => ts('- select -') + '' => ts('- select -'), ) + CRM_Contribute_PseudoConstant::contributionPage(), $required, 'class="big"' ); } @@ -2214,14 +2214,14 @@ AND ( entity_id IS NULL OR entity_id <= 0 ) elseif ($fieldName == 'activity_status_id') { $form->add('select', $name, $title, array( - '' => ts('- select -') + '' => ts('- select -'), ) + CRM_Core_PseudoConstant::activityStatus(), $required ); } elseif ($fieldName == 'activity_engagement_level') { $form->add('select', $name, $title, array( - '' => ts('- select -') + '' => ts('- select -'), ) + CRM_Campaign_PseudoConstant::engagementLevel(), $required ); } @@ -2235,7 +2235,7 @@ AND ( entity_id IS NULL OR entity_id <= 0 ) } $form->add('select', $name, $title, array( - '' => ts('- select -') + '' => ts('- select -'), ) + CRM_Event_PseudoConstant::participantStatus(NULL, $cond, 'label'), $required ); } @@ -2246,7 +2246,7 @@ AND ( entity_id IS NULL OR entity_id <= 0 ) else { $form->add('select', $name, $title, array( - '' => ts('- select -') + '' => ts('- select -'), ) + CRM_Event_PseudoConstant::participantRole(), $required ); } @@ -2267,7 +2267,7 @@ AND ( entity_id IS NULL OR entity_id <= 0 ) )); $form->add('select', $name, $title, array( - '' => ts('- select -') + '' => ts('- select -'), ) + $campaigns, $required, 'class="crm-select2 big"' ); } @@ -2314,7 +2314,7 @@ AND ( entity_id IS NULL OR entity_id <= 0 ) 'non_deductible_amount', 'total_amount', 'fee_amount', - 'net_amount' + 'net_amount', ))) { $form->addRule($name, ts('Please enter a valid amount.'), 'money'); } @@ -3133,7 +3133,7 @@ AND ( entity_id IS NULL OR entity_id <= 0 ) 'Contact', 'Individual', 'Organization', - 'Household' + 'Household', ), $componentGroupTypes, CRM_Contact_BAO_ContactType::subTypes()); $gTypes = $gTypeValues = array(); @@ -3277,7 +3277,7 @@ AND ( entity_id IS NULL OR entity_id <= 0 ) 'thankyou_date', 'membership_start_date', 'membership_end_date', - 'join_date' + 'join_date', ); foreach ($fields as $name => $field) { $fldName = $isStandalone ? $name : "field[$componentId][$name]"; @@ -3298,7 +3298,7 @@ AND ( entity_id IS NULL OR entity_id <= 0 ) 'financial_type', 'payment_instrument', 'participant_status', - 'participant_role' + 'participant_role', ))) { $defaults[$fldName] = $values["{$name}_id"]; } diff --git a/CRM/Core/BAO/UFMatch.php b/CRM/Core/BAO/UFMatch.php index 38cc161e94..8a704f0fa3 100644 --- a/CRM/Core/BAO/UFMatch.php +++ b/CRM/Core/BAO/UFMatch.php @@ -347,7 +347,7 @@ AND domain_id = %4 1 => $ufmatch->contact_id, 2 => $uf, 3 => $ufmatch->uf_id, - 4 => $conflict + 4 => $conflict, ) ); unset($conflict); diff --git a/CRM/Core/ClassLoader.php b/CRM/Core/ClassLoader.php index a96787f2fa..6ba1658c12 100644 --- a/CRM/Core/ClassLoader.php +++ b/CRM/Core/ClassLoader.php @@ -96,7 +96,7 @@ class CRM_Core_ClassLoader { $include_paths = array( '.', $civicrm_base_path, - $packages_path + $packages_path, ); $include_paths = implode(PATH_SEPARATOR, $include_paths); set_include_path($include_paths . PATH_SEPARATOR . get_include_path()); diff --git a/CRM/Core/Config.php b/CRM/Core/Config.php index 8912a343db..ccaf9c6700 100644 --- a/CRM/Core/Config.php +++ b/CRM/Core/Config.php @@ -484,7 +484,7 @@ class CRM_Core_Config extends CRM_Core_Config_Variables { $url = CRM_Utils_System::url('civicrm/admin/setting/path', 'reset=1'); CRM_Core_Session::setStatus(ts('%1 has an incorrect directory path. Please go to the path setting page and correct it.', array( 1 => $key, - 2 => $url + 2 => $url, )), ts('Check Settings'), 'alert'); } } diff --git a/CRM/Core/Form.php b/CRM/Core/Form.php index c152492868..9ef41bc756 100644 --- a/CRM/Core/Form.php +++ b/CRM/Core/Form.php @@ -1638,7 +1638,7 @@ class CRM_Core_Form extends HTML_QuickForm_Page { 'id_field' => 'select_contact_id', 'placeholder' => ts('Select someone else ...'), 'show_hide' => TRUE, - 'api' => array('params' => array('contact_type' => 'Individual')) + 'api' => array('params' => array('contact_type' => 'Individual')), ), $autoCompleteField); if ($this->canUseAjaxContactLookups()) { diff --git a/CRM/Core/Form/RecurringEntity.php b/CRM/Core/Form/RecurringEntity.php index a8818fe0c8..7a9b4332c7 100644 --- a/CRM/Core/Form/RecurringEntity.php +++ b/CRM/Core/Form/RecurringEntity.php @@ -173,7 +173,7 @@ class CRM_Core_Form_RecurringEntity { 'thursday' => 'Thursday', 'friday' => 'Friday', 'saturday' => 'Saturday', - 'sunday' => 'Sunday' + 'sunday' => 'Sunday', ); $form->add('select', 'repetition_frequency_unit', ts('Repeats:'), $freqUnitsDisplay); $numericOptions = CRM_Core_SelectValues::getNumericOptions(1, 30); @@ -195,7 +195,7 @@ class CRM_Core_Form_RecurringEntity { 'second' => 'Second', 'third' => 'Third', 'fourth' => 'Fourth', - 'last' => 'Last' + 'last' => 'Last', ); $form->add('select', 'entity_status_1', ts(''), $dayOfTheWeekNo); $form->add('select', 'entity_status_2', ts(''), $dayOfTheWeek); @@ -222,7 +222,7 @@ class CRM_Core_Form_RecurringEntity { ), array( 'type' => 'cancel', - 'name' => ts('Cancel') + 'name' => ts('Cancel'), ), ) ); @@ -370,7 +370,7 @@ class CRM_Core_Form_RecurringEntity { 'name' => $type . '_repeat_exclude_dates_' . $actionScheduleObj->entity_value, 'title' => $type . ' recursion', 'is_reserved' => 0, - 'is_active' => 1 + 'is_active' => 1, ); $opGroup = CRM_Core_BAO_OptionGroup::add($optionGroupParams); if ($opGroup->id) { @@ -385,7 +385,7 @@ class CRM_Core_Form_RecurringEntity { 'name' => $opGroup->name, 'description' => 'Used for recurring ' . $type, 'weight' => CRM_Utils_Weight::updateOtherWeights('CRM_Core_DAO_OptionValue', $oldWeight, CRM_Utils_Array::value('weight', $params), $fieldValues), - 'is_active' => 1 + 'is_active' => 1, ); $excludeDateList[] = $optionGroupValue['value']; CRM_Core_BAO_OptionValue::add($optionGroupValue); diff --git a/CRM/Core/InnoDBIndexer.php b/CRM/Core/InnoDBIndexer.php index 5f880e1d2b..a2d46e79e9 100644 --- a/CRM/Core/InnoDBIndexer.php +++ b/CRM/Core/InnoDBIndexer.php @@ -45,7 +45,7 @@ class CRM_Core_InnoDBIndexer { if ($fresh || self::$singleton === NULL) { $indices = array( 'civicrm_address' => array( - array('street_address', 'city', 'postal_code') + array('street_address', 'city', 'postal_code'), ), 'civicrm_activity' => array( array('subject', 'details'), @@ -57,7 +57,7 @@ class CRM_Core_InnoDBIndexer { array('source', 'amount_level', 'trxn_Id', 'invoice_id'), ), 'civicrm_email' => array( - array('email') + array('email'), ), 'civicrm_membership' => array( array('source'), diff --git a/CRM/Core/ManagedEntities.php b/CRM/Core/ManagedEntities.php index 5a562d6a1f..ca4deb4f27 100644 --- a/CRM/Core/ManagedEntities.php +++ b/CRM/Core/ManagedEntities.php @@ -279,7 +279,7 @@ class CRM_Core_ManagedEntities { case 'unused': $getRefCount = civicrm_api3($dao->entity_type, 'getrefcount', array( 'debug' => 1, - 'id' => $dao->entity_id + 'id' => $dao->entity_id, )); $total = 0; @@ -304,7 +304,7 @@ class CRM_Core_ManagedEntities { } CRM_Core_DAO::executeQuery('DELETE FROM civicrm_managed WHERE id = %1', array( - 1 => array($dao->id, 'Integer') + 1 => array($dao->id, 'Integer'), )); } } diff --git a/CRM/Core/Payment.php b/CRM/Core/Payment.php index 70c025d946..c52693c8e8 100644 --- a/CRM/Core/Payment.php +++ b/CRM/Core/Payment.php @@ -315,7 +315,7 @@ abstract class CRM_Core_Payment { 'attributes' => array( 'size' => 20, 'maxlength' => 20, - 'autocomplete' => 'off' + 'autocomplete' => 'off', ), 'is_required' => TRUE, ), @@ -327,7 +327,7 @@ abstract class CRM_Core_Payment { 'attributes' => array( 'size' => 5, 'maxlength' => 10, - 'autocomplete' => 'off' + 'autocomplete' => 'off', ), 'is_required' => CRM_Core_BAO_Setting::getItem(CRM_Core_BAO_Setting::CONTRIBUTE_PREFERENCES_NAME, 'cvv_backoffice_required', @@ -371,7 +371,7 @@ abstract class CRM_Core_Payment { 'attributes' => array( 'size' => 20, 'maxlength' => 34, - 'autocomplete' => 'on' + 'autocomplete' => 'on', ), 'is_required' => TRUE, ), @@ -384,7 +384,7 @@ abstract class CRM_Core_Payment { 'attributes' => array( 'size' => 20, 'maxlength' => 34, - 'autocomplete' => 'off' + 'autocomplete' => 'off', ), 'rules' => array( array( @@ -403,7 +403,7 @@ abstract class CRM_Core_Payment { 'attributes' => array( 'size' => 20, 'maxlength' => 11, - 'autocomplete' => 'off' + 'autocomplete' => 'off', ), 'is_required' => TRUE, 'rules' => array( @@ -421,11 +421,11 @@ abstract class CRM_Core_Payment { 'attributes' => array( 'size' => 20, 'maxlength' => 64, - 'autocomplete' => 'off' + 'autocomplete' => 'off', ), 'is_required' => TRUE, - ) + ), ); } diff --git a/CRM/Core/Payment/PayPalProIPN.php b/CRM/Core/Payment/PayPalProIPN.php index 2a0ff4dc0e..673bbc60f6 100644 --- a/CRM/Core/Payment/PayPalProIPN.php +++ b/CRM/Core/Payment/PayPalProIPN.php @@ -569,7 +569,7 @@ INNER JOIN civicrm_membership_payment mp ON m.id = mp.membership_id AND mp.contr public function transactionExists($trxn_id) { if (CRM_Core_DAO::singleValueQuery("SELECT count(*) FROM civicrm_contribution WHERE trxn_id = %1", array( - 1 => array($trxn_id, 'String') + 1 => array($trxn_id, 'String'), ))) { return TRUE; } diff --git a/CRM/Core/Payment/Realex.php b/CRM/Core/Payment/Realex.php index c1901c6001..000ccc6d73 100644 --- a/CRM/Core/Payment/Realex.php +++ b/CRM/Core/Payment/Realex.php @@ -314,7 +314,7 @@ class CRM_Core_Payment_Realex extends CRM_Core_Payment { array( 1 => xml_get_error_code($xmlparser), 2 => xml_get_current_line_number($xmlparser), - 3 => xml_get_current_column_number($xmlparser) + 3 => xml_get_current_column_number($xmlparser), ) ); } diff --git a/CRM/Core/Permission.php b/CRM/Core/Permission.php index 05cdc7d335..b917d2af77 100644 --- a/CRM/Core/Permission.php +++ b/CRM/Core/Permission.php @@ -591,7 +591,7 @@ class CRM_Core_Permission { static $permissions = array(); if (empty($permissions)) { $permissions = array( - 'administer CiviCRM' + 'administer CiviCRM', ); $components = CRM_Core_Component::getComponents(); foreach ($components as $comp) { diff --git a/CRM/Core/Reference/Basic.php b/CRM/Core/Reference/Basic.php index 572e963058..fcfc5436a9 100644 --- a/CRM/Core/Reference/Basic.php +++ b/CRM/Core/Reference/Basic.php @@ -79,7 +79,7 @@ class CRM_Core_Reference_Basic implements CRM_Core_Reference_Interface { public function findReferences($targetDao) { $targetColumn = $this->getTargetKey(); $params = array( - 1 => array($targetDao->$targetColumn, 'String') + 1 => array($targetDao->$targetColumn, 'String'), ); $sql = <<getTargetKey(); $params = array( - 1 => array($targetDao->$targetColumn, 'String') + 1 => array($targetDao->$targetColumn, 'String'), ); $sql = << get_class($this), 'table' => $this->getReferenceTable(), 'key' => $this->getReferenceKey(), - 'count' => CRM_Core_DAO::singleValueQuery($sql, $params) + 'count' => CRM_Core_DAO::singleValueQuery($sql, $params), ); } } diff --git a/CRM/Core/Reference/Dynamic.php b/CRM/Core/Reference/Dynamic.php index 32b9f1caa5..863018d9ad 100644 --- a/CRM/Core/Reference/Dynamic.php +++ b/CRM/Core/Reference/Dynamic.php @@ -74,7 +74,7 @@ EOS; 'type' => get_class($this), 'table' => $this->getReferenceTable(), 'key' => $this->getReferenceKey(), - 'count' => CRM_Core_DAO::singleValueQuery($sql, $params) + 'count' => CRM_Core_DAO::singleValueQuery($sql, $params), ); } diff --git a/CRM/Core/SelectValues.php b/CRM/Core/SelectValues.php index d65ddff757..09fe679c7b 100644 --- a/CRM/Core/SelectValues.php +++ b/CRM/Core/SelectValues.php @@ -120,7 +120,7 @@ class CRM_Core_SelectValues { 'automatic' => ts("Automatic"), 'location-only' => ts("Only send to email addresses assigned to the specified location"), 'location-prefer' => ts("Prefer email addresses assigned to the specified location"), - 'location-exclude' => ts("Exclude email addresses assigned to the specified location") + 'location-exclude' => ts("Exclude email addresses assigned to the specified location"), ); } @@ -143,7 +143,7 @@ class CRM_Core_SelectValues { return array( ts('No auto-renew option'), ts('Give option, but not required'), - ts('Auto-renew required') + ts('Auto-renew required'), ); } @@ -519,7 +519,7 @@ class CRM_Core_SelectValues { '{event.fee_amount}' => ts('Event Fees'), '{event.info_url}' => ts('Event Info URL'), '{event.registration_url}' => ts('Event Registration URL'), - '{event.balance}' => ts('Event Balance') + '{event.balance}' => ts('Event Balance'), ); } diff --git a/CRM/Custom/Form/Group.php b/CRM/Custom/Form/Group.php index a3d623ba10..0e7ee54da2 100644 --- a/CRM/Custom/Form/Group.php +++ b/CRM/Custom/Form/Group.php @@ -292,7 +292,7 @@ class CRM_Custom_Form_Group extends CRM_Core_Form { ts('Used For'), array( 'name' => 'extends[0]', - 'style' => 'vertical-align: top;' + 'style' => 'vertical-align: top;', ), TRUE ); diff --git a/CRM/Custom/Form/MoveField.php b/CRM/Custom/Form/MoveField.php index 1a94fd5ba5..f3f24ad943 100644 --- a/CRM/Custom/Form/MoveField.php +++ b/CRM/Custom/Form/MoveField.php @@ -174,7 +174,7 @@ class CRM_Custom_Form_MoveField extends CRM_Core_Form { array( 1 => $this->_srcFieldLabel, 2 => $dstGroup, - 3 => $srcUrl + 3 => $srcUrl, )), '', 'success'); } } diff --git a/CRM/Dedupe/Merger.php b/CRM/Dedupe/Merger.php index f29b9c9c57..2b5198dca2 100644 --- a/CRM/Dedupe/Merger.php +++ b/CRM/Dedupe/Merger.php @@ -1039,7 +1039,7 @@ INNER JOIN civicrm_membership membership2 ON membership1.membership_type_id = m array( 1 => $block, 2 => $count, - 3 => $allLocationTypes[$locTypeId] + 3 => $allLocationTypes[$locTypeId], ) ); @@ -1633,7 +1633,7 @@ INNER JOIN civicrm_membership membership2 ON membership1.membership_type_id = m 'start_date' => CRM_Utils_Date::isoToMysql($dao->start_date), 'end_date' => CRM_Utils_Date::isoToMysql($dao->end_date), 'source' => $dao->source, - 'status_id' => $dao->status_id + 'status_id' => $dao->status_id, ); // create/update membership(s) for related contact(s) CRM_Member_BAO_Membership::createRelatedMemberships($membershipParams, $dao); diff --git a/CRM/Event/BAO/Event.php b/CRM/Event/BAO/Event.php index a41c375459..9b122cd824 100644 --- a/CRM/Event/BAO/Event.php +++ b/CRM/Event/BAO/Event.php @@ -702,7 +702,7 @@ WHERE civicrm_address.geo_code_1 IS NOT NULL $addressValues = CRM_Core_BAO_Location::getValues($params, TRUE); $location['address'] = str_replace(array( "\r", - "\n" + "\n", ), '', addslashes(nl2br($addressValues['address'][1]['display_text']))); $location['url'] = CRM_Utils_System::url('civicrm/event/register', 'reset=1&id=' . $dao->event_id); @@ -930,7 +930,7 @@ WHERE civicrm_event.is_active = 1 'is_show_location', 'default_fee_id', 'default_discount_fee_id', - 'is_template' + 'is_template', ); CRM_Core_DAO::commonRetrieve('CRM_Event_DAO_Event', $eventParams, $eventValues, $returnProperties); @@ -1524,7 +1524,7 @@ WHERE civicrm_event.is_active = 1 elseif (in_array($name, array( 'addressee', 'email_greeting', - 'postal_greeting' + 'postal_greeting', ))) { $filterCondition = array('greeting_type' => $name); $greeting = CRM_Core_PseudoConstant::greeting($filterCondition); @@ -1589,7 +1589,7 @@ WHERE civicrm_event.is_active = 1 if (in_array($fieldName, array( 'state_province', 'country', - 'county' + 'county', ))) { $values[$index] = $params[$detailName]; $idx = $detailName . '_id'; @@ -1700,7 +1700,7 @@ WHERE id = $cfID elseif (in_array($name, array( 'birth_date', 'deceased_date', - 'participant_register_date' + 'participant_register_date', ))) { $values[$index] = CRM_Utils_Date::customFormat(CRM_Utils_Date::format($params[$name])); } diff --git a/CRM/Event/BAO/Participant.php b/CRM/Event/BAO/Participant.php index 01c738d53b..892657bf5a 100644 --- a/CRM/Event/BAO/Participant.php +++ b/CRM/Event/BAO/Participant.php @@ -244,7 +244,7 @@ class CRM_Event_BAO_Participant extends CRM_Event_DAO_Participant { $hasNoteField = FALSE; foreach (array( 'note', - 'participant_note' + 'participant_note', ) as $noteFld) { if (array_key_exists($noteFld, $params)) { $noteValue = $params[$noteFld]; @@ -646,7 +646,7 @@ GROUP BY participant.event_id 'title' => ts('Participant Note'), 'name' => 'participant_note', 'headerPattern' => '/(participant.)?note$/i', - ) + ), ); // Split status and status id into 2 fields @@ -656,7 +656,7 @@ GROUP BY participant.event_id 'title' => ts('Participant Status'), 'name' => 'participant_status', 'data_type' => CRM_Utils_Type::T_STRING, - ) + ), ); $tmpFields['participant_status_id']['title'] = ts('Participant Status Id'); @@ -667,7 +667,7 @@ GROUP BY participant.event_id 'title' => ts('Participant Role'), 'name' => 'participant_role', 'data_type' => CRM_Utils_Type::T_STRING, - ) + ), ); $tmpFields['participant_role_id']['title'] = ts('Participant Role Id'); @@ -676,7 +676,7 @@ GROUP BY participant.event_id 'title' => ts('Event Type'), 'name' => 'event_type', 'data_type' => CRM_Utils_Type::T_STRING, - ) + ), ); $tmpContactField = $contactFields = array(); @@ -750,21 +750,21 @@ GROUP BY participant.event_id 'participant_note' => array( 'title' => 'Participant Note', 'name' => 'participant_note', - ) + ), ); $participantStatus = array( 'participant_status' => array( 'title' => 'Participant Status', 'name' => 'participant_status', - ) + ), ); $participantRole = array( 'participant_role' => array( 'title' => 'Participant Role', 'name' => 'participant_role', - ) + ), ); //CRM-13595 add event id to participant export @@ -772,13 +772,13 @@ GROUP BY participant.event_id 'event_id' => array( 'title' => 'Event ID', 'name' => 'event_id', - ) + ), ); $eventtitle = array( 'event_title' => array( 'title' => 'Event Title', 'name' => 'event_title', - ) + ), ); $discountFields = CRM_Core_DAO_Discount::export(); @@ -1649,7 +1649,7 @@ UPDATE civicrm_participant if (is_string($emptySeats) && $emptySeats !== NULL) { $maxParticipants = CRM_Core_DAO::getFieldValue('CRM_Event_DAO_Event', $eventId, 'max_participants'); $eventfullMsg = ts("This event currently has the maximum number of participants registered (%1). However, you can still override this limit and register additional participants using this form.", array( - 1 => $maxParticipants + 1 => $maxParticipants, )) . '
'; } @@ -1772,7 +1772,7 @@ WHERE civicrm_participant.contact_id = {$contactID} AND // get additional participant ids (including cancelled) if ($participantId) { $ids = array_merge(array( - $participantId + $participantId, ), self::getAdditionalParticipantIds($participantId, $excludeCancelled )); @@ -1829,7 +1829,7 @@ LEFT JOIN civicrm_price_field cpf ON cpfv.price_field_id = cpf.id WHERE cpf.price_set_id = %1 AND cpfv.label LIKE %2"; $params = array( 1 => array($priceSetId, 'Integer'), - 2 => array($feeLevel, 'String') + 2 => array($feeLevel, 'String'), ); $mainAmount = CRM_Core_DAO::singleValueQuery($query, $params); $relationTypeId = key(CRM_Core_PseudoConstant::accountOptionValues('account_relationship', NULL, " AND v.name LIKE 'Discounts Account is' ")); @@ -2127,7 +2127,7 @@ WHERE (li.entity_table = 'civicrm_participant' AND li.entity_id = {$participantI 'payment_instrument_id' => $updatedContribution->payment_instrument_id, 'contribution_id' => $updatedContribution->id, 'trxn_date' => date('YmdHis'), - 'currency' => $updatedContribution->currency + 'currency' => $updatedContribution->currency, ); $adjustedTrxn = CRM_Core_BAO_FinancialTrxn::create($adjustedTrxnValues); } diff --git a/CRM/Event/Form/ManageEvent/Fee.php b/CRM/Event/Form/ManageEvent/Fee.php index 4eada5b45b..bcfa6d288c 100644 --- a/CRM/Event/Form/ManageEvent/Fee.php +++ b/CRM/Event/Form/ManageEvent/Fee.php @@ -616,7 +616,7 @@ class CRM_Event_Form_ManageEvent_Fee extends CRM_Event_Form_ManageEvent { 'value' => CRM_Utils_Rule::cleanMoney(trim($values[$i])), 'weight' => $i, 'is_active' => 1, - 'is_default' => $default == $i + 'is_default' => $default == $i, ); } } @@ -697,7 +697,7 @@ class CRM_Event_Form_ManageEvent_Fee extends CRM_Event_Form_ManageEvent { 'value' => CRM_Utils_Rule::cleanMoney(trim($values[$i][$j])), 'weight' => $i, 'is_active' => 1, - 'is_default' => $default == $i + 'is_default' => $default == $i, ); } } diff --git a/CRM/Event/Form/ManageEvent/Repeat.php b/CRM/Event/Form/ManageEvent/Repeat.php index bb442f8244..d6f7ee2370 100644 --- a/CRM/Event/Form/ManageEvent/Repeat.php +++ b/CRM/Event/Form/ManageEvent/Repeat.php @@ -117,7 +117,7 @@ class CRM_Event_Form_ManageEvent_Repeat extends CRM_Event_Form_ManageEvent { 'table' => 'civicrm_price_set_entity', 'findCriteria' => array( 'entity_id' => $this->_id, - 'entity_table' => 'civicrm_event' + 'entity_table' => 'civicrm_event', ), 'linkedColumns' => array('entity_id'), 'isRecurringEntityRecord' => FALSE, @@ -126,7 +126,7 @@ class CRM_Event_Form_ManageEvent_Repeat extends CRM_Event_Form_ManageEvent { 'table' => 'civicrm_uf_join', 'findCriteria' => array( 'entity_id' => $this->_id, - 'entity_table' => 'civicrm_event' + 'entity_table' => 'civicrm_event', ), 'linkedColumns' => array('entity_id'), 'isRecurringEntityRecord' => FALSE, @@ -135,7 +135,7 @@ class CRM_Event_Form_ManageEvent_Repeat extends CRM_Event_Form_ManageEvent { 'table' => 'civicrm_tell_friend', 'findCriteria' => array( 'entity_id' => $this->_id, - 'entity_table' => 'civicrm_event' + 'entity_table' => 'civicrm_event', ), 'linkedColumns' => array('entity_id'), 'isRecurringEntityRecord' => TRUE, @@ -144,7 +144,7 @@ class CRM_Event_Form_ManageEvent_Repeat extends CRM_Event_Form_ManageEvent { 'table' => 'civicrm_pcp_block', 'findCriteria' => array( 'entity_id' => $this->_id, - 'entity_table' => 'civicrm_event' + 'entity_table' => 'civicrm_event', ), 'linkedColumns' => array('entity_id'), 'isRecurringEntityRecord' => TRUE, diff --git a/CRM/Event/Form/Participant.php b/CRM/Event/Form/Participant.php index e87b4aab7d..c2506d53b2 100644 --- a/CRM/Event/Form/Participant.php +++ b/CRM/Event/Form/Participant.php @@ -647,7 +647,7 @@ class CRM_Event_Form_Participant extends CRM_Contribute_Form_AbstractEditPayment 'select' => array('minimumInputLength' => 0), 'api' => array( 'extra' => array('campaign_id', 'default_role_id', 'event_type_id'), - ) + ), ); if ($this->_mode) { @@ -752,7 +752,7 @@ class CRM_Event_Form_Participant extends CRM_Contribute_Form_AbstractEditPayment $path = CRM_Utils_System::currentPath(); $excludeForPaths = array( 'civicrm/contact/search', - 'civicrm/group/search' + 'civicrm/group/search', ); if (!in_array($path, $excludeForPaths)) { $buttons[] = array( diff --git a/CRM/Event/Form/ParticipantFeeSelection.php b/CRM/Event/Form/ParticipantFeeSelection.php index f96fc73e89..44eafbc624 100644 --- a/CRM/Event/Form/ParticipantFeeSelection.php +++ b/CRM/Event/Form/ParticipantFeeSelection.php @@ -208,7 +208,7 @@ class CRM_Event_Form_ParticipantFeeSelection extends CRM_Core_Form { $buttons[] = array( 'type' => 'upload', 'name' => ts('Save and Record Payment'), - 'subName' => 'new' + 'subName' => 'new', ); } $buttons[] = array( diff --git a/CRM/Event/Form/Registration/Register.php b/CRM/Event/Form/Registration/Register.php index f661630730..f67dceeeec 100644 --- a/CRM/Event/Form/Registration/Register.php +++ b/CRM/Event/Form/Registration/Register.php @@ -324,7 +324,7 @@ class CRM_Event_Form_Registration_Register extends CRM_Event_Form_Registration { $profileAddressFields = array(); foreach ($this->_fields as $key => $value) { CRM_Core_BAO_UFField::assignAddressField($key, $profileAddressFields, array( - 'uf_group_id' => $this->_values['custom_pre_id'] + 'uf_group_id' => $this->_values['custom_pre_id'], )); } $this->set('profileAddressFields', $profileAddressFields); diff --git a/CRM/Event/Form/Task/Batch.php b/CRM/Event/Form/Task/Batch.php index 54fd23af49..ceac39f145 100644 --- a/CRM/Event/Form/Task/Batch.php +++ b/CRM/Event/Form/Task/Batch.php @@ -388,7 +388,7 @@ class CRM_Event_Form_Task_Batch extends CRM_Event_Form_Task { 'componentName' => 'Event', 'contribution_id' => $contributionId, 'contribution_status_id' => $contributionStatusId, - 'skipComponentSync' => 1 + 'skipComponentSync' => 1, ); //change related contribution status. diff --git a/CRM/Event/Import/Parser/Participant.php b/CRM/Event/Import/Parser/Participant.php index ca9037a79d..62da7d43d4 100644 --- a/CRM/Event/Import/Parser/Participant.php +++ b/CRM/Event/Import/Parser/Participant.php @@ -380,7 +380,7 @@ class CRM_Event_Import_Parser_Participant extends CRM_Event_Import_Parser { if (!empty($formatted['fee_level'])) { $otherParams = array( 'fee_label' => $formatted['fee_level'], - 'event_id' => $newParticipant->event_id + 'event_id' => $newParticipant->event_id, ); CRM_Price_BAO_LineItem::syncLineItems($newParticipant->id, 'civicrm_participant', $newParticipant->fee_amount, $otherParams); } diff --git a/CRM/Event/Page/ManageEvent.php b/CRM/Event/Page/ManageEvent.php index 6273688e56..46b03191a9 100644 --- a/CRM/Event/Page/ManageEvent.php +++ b/CRM/Event/Page/ManageEvent.php @@ -91,7 +91,7 @@ class CRM_Event_Page_ManageEvent extends CRM_Core_Page { 'qs' => 'reset=1&action=copy&id=%%id%%', 'extra' => 'onclick = "return confirm(\'' . $copyExtra . '\');"', 'title' => ts('Copy Event'), - ) + ), ); } return self::$_actionLinks; @@ -114,7 +114,7 @@ class CRM_Event_Page_ManageEvent extends CRM_Core_Page { array( 'title' => ts('Info and Settings'), 'url' => 'civicrm/event/manage/settings', - 'field' => 'id' + 'field' => 'id', ); self::$_tabLinks[$cacheKey]['location'] = array( diff --git a/CRM/Export/BAO/Export.php b/CRM/Export/BAO/Export.php index 1c9e216bb1..77e75cafa7 100644 --- a/CRM/Export/BAO/Export.php +++ b/CRM/Export/BAO/Export.php @@ -926,7 +926,7 @@ INSERT INTO {$componentTable} SELECT distinct gc.contact_id FROM civicrm_group_c elseif (is_object($relDAO) && in_array($relationField, array( 'email_greeting', 'postal_greeting', - 'addressee' + 'addressee', )) ) { //special case for greeting replacement @@ -1047,7 +1047,7 @@ INSERT INTO {$componentTable} SELECT distinct gc.contact_id FROM civicrm_group_c elseif (in_array($field, array( 'email_greeting', 'postal_greeting', - 'addressee' + 'addressee', ))) { //special case for greeting replacement $fldValue = "{$field}_display"; @@ -1410,7 +1410,7 @@ INSERT INTO {$componentTable} SELECT distinct gc.contact_id FROM civicrm_group_c $changeFields = array( 'groups', 'tags', - 'notes' + 'notes', ); if (in_array($fieldName, $changeFields)) { @@ -1844,7 +1844,7 @@ WHERE id IN ( $deleteIDString ) 'contact_is_deleted' => 'is_deleted', 'name' => 'address_name', 'provider_id' => 'im_service_provider', - 'phone_type_id' => 'phone_type' + 'phone_type_id' => 'phone_type', ); //figure out which columns are to be replaced by which ones diff --git a/CRM/Extension/Downloader.php b/CRM/Extension/Downloader.php index a9698a5287..75b46517b9 100644 --- a/CRM/Extension/Downloader.php +++ b/CRM/Extension/Downloader.php @@ -75,7 +75,7 @@ class CRM_Extension_Downloader { //1 => $this->containerDir, 1 => $url, ) - ) + ), ); } diff --git a/CRM/Financial/BAO/PaymentProcessor.php b/CRM/Financial/BAO/PaymentProcessor.php index d9d1165003..7908545f28 100644 --- a/CRM/Financial/BAO/PaymentProcessor.php +++ b/CRM/Financial/BAO/PaymentProcessor.php @@ -78,7 +78,7 @@ class CRM_Financial_BAO_PaymentProcessor extends CRM_Financial_DAO_PaymentProces 'entity_table' => 'civicrm_payment_processor', 'entity_id' => $processor->id, 'account_relationship' => $relationTypeId, - 'financial_account_id' => $params['financial_account_id'] + 'financial_account_id' => $params['financial_account_id'], ); CRM_Financial_BAO_FinancialTypeAccount::add($values); } diff --git a/CRM/Financial/Form/BatchTransaction.php b/CRM/Financial/Form/BatchTransaction.php index bbd3c7006b..2cfd7adf1b 100644 --- a/CRM/Financial/Form/BatchTransaction.php +++ b/CRM/Financial/Form/BatchTransaction.php @@ -137,7 +137,7 @@ class CRM_Financial_Form_BatchTransaction extends CRM_Contribute_Form { 'type' => 'submit', 'name' => ts('Search'), 'isDefault' => TRUE, - ) + ), ) ); @@ -189,7 +189,7 @@ class CRM_Financial_Form_BatchTransaction extends CRM_Contribute_Form { 'ref' => 'disable-action', 'title' => ts('Assign Transaction'), 'extra' => 'onclick = "assignRemove( %%id%%,\'' . 'assign' . '\' );"', - ) + ), ); } return self::$_links; diff --git a/CRM/Financial/Form/FinancialAccount.php b/CRM/Financial/Form/FinancialAccount.php index bdc0406a5c..fdfb277576 100644 --- a/CRM/Financial/Form/FinancialAccount.php +++ b/CRM/Financial/Form/FinancialAccount.php @@ -158,7 +158,7 @@ class CRM_Financial_Form_FinancialAccount extends CRM_Contribute_Form { $relationshipId = key(CRM_Core_PseudoConstant::accountOptionValues('account_relationship', NULL, " AND v.name LIKE 'Sales Tax Account is' ")); $params = array( 'financial_account_id' => $self->_id, - 'account_relationship' => $relationshipId + 'account_relationship' => $relationshipId, ); $result = CRM_Financial_BAO_FinancialTypeAccount::retrieve($params, $defaults); if ($result) { diff --git a/CRM/Financial/Form/FinancialTypeAccount.php b/CRM/Financial/Form/FinancialTypeAccount.php index e1d396a348..0e0f58151b 100644 --- a/CRM/Financial/Form/FinancialTypeAccount.php +++ b/CRM/Financial/Form/FinancialTypeAccount.php @@ -113,7 +113,7 @@ class CRM_Financial_Form_FinancialTypeAccount extends CRM_Contribute_Form { array( 'title' => ts('Financial Type Accounts'), 'url' => $url, - ) + ), ); CRM_Utils_System::appendBreadCrumb($breadCrumb); } @@ -171,7 +171,7 @@ class CRM_Financial_Form_FinancialTypeAccount extends CRM_Contribute_Form { '6' => 1, //Asset '7' => 4, //cost of sales '8' => 1, //premium inventory - '9' => 3 //discount account is + '9' => 3 //discount account is, ); $financialAccountType = CRM_Utils_Array::value($this->_submitValues['account_relationship'], $financialAccountType); @@ -181,7 +181,7 @@ class CRM_Financial_Form_FinancialTypeAccount extends CRM_Contribute_Form { } else { $financialAccountSelect = array( - 'select' => ts('- select -') + 'select' => ts('- select -'), ) + CRM_Contribute_PseudoConstant::financialAccount(); } } @@ -193,7 +193,7 @@ class CRM_Financial_Form_FinancialTypeAccount extends CRM_Contribute_Form { '6' => 1, //Asset '7' => 4, //cost of sales '8' => 1, //premium inventory - '9' => 3 //discount account is + '9' => 3 //discount account is, ); $financialAccountType = $financialAccountType[$this->_defaultValues['account_relationship']]; @@ -213,16 +213,16 @@ class CRM_Financial_Form_FinancialTypeAccount extends CRM_Contribute_Form { array( 'type' => 'next', 'name' => ts('Save'), - 'isDefault' => TRUE + 'isDefault' => TRUE, ), array( 'type' => 'next', 'name' => ts('Save and New'), - 'subName' => 'new' + 'subName' => 'new', ), array( 'type' => 'cancel', - 'name' => ts('Cancel') + 'name' => ts('Cancel'), )) ); $this->addFormRule(array('CRM_Financial_Form_FinancialTypeAccount', 'formRule'), $this); @@ -264,7 +264,7 @@ class CRM_Financial_Form_FinancialTypeAccount extends CRM_Contribute_Form { if (!empty($values['account_relationship']) && !empty($values['financial_account_id'])) { $params = array( 'account_relationship' => $values['account_relationship'], - 'entity_id' => $self->_aid + 'entity_id' => $self->_aid, ); $defaults = array(); if ($self->_action == CRM_Core_Action::ADD) { diff --git a/CRM/Financial/Form/Search.php b/CRM/Financial/Form/Search.php index df27a3b326..d136309f3a 100644 --- a/CRM/Financial/Form/Search.php +++ b/CRM/Financial/Form/Search.php @@ -113,7 +113,7 @@ class CRM_Financial_Form_Search extends CRM_Core_Form { 'type' => 'refresh', 'name' => ts('Search'), 'isDefault' => TRUE, - ) + ), ) ); parent::buildQuickForm(); diff --git a/CRM/Financial/Page/AJAX.php b/CRM/Financial/Page/AJAX.php index fb58e1e299..d91d819b57 100644 --- a/CRM/Financial/Page/AJAX.php +++ b/CRM/Financial/Page/AJAX.php @@ -76,7 +76,7 @@ class CRM_Financial_Page_AJAX { array( 'name' => ts('- select -'), 'value' => 'select', - ) + ), ); if (!empty($result)) { @@ -121,7 +121,7 @@ class CRM_Financial_Page_AJAX { array( 'name' => ts('- Select Financial Account Relationship -'), 'value' => 'select', - ) + ), ); $countResult = count($financialAccountType[$financialAccountTypeId]); @@ -397,7 +397,7 @@ class CRM_Financial_Page_AJAX { array( 'id' => $financialItem->id, 'contid' => $financialItem->contributionID, - 'cid' => $financialItem->contact_id + 'cid' => $financialItem->contact_id, ), ts('more'), FALSE, @@ -415,7 +415,7 @@ class CRM_Financial_Page_AJAX { array( 'id' => $financialItem->id, 'contid' => $financialItem->contributionID, - 'cid' => $financialItem->contact_id + 'cid' => $financialItem->contact_id, ), ts('more'), FALSE, @@ -435,7 +435,7 @@ class CRM_Financial_Page_AJAX { array( 'id' => $financialItem->id, 'contid' => $financialItem->contributionID, - 'cid' => $financialItem->contact_id + 'cid' => $financialItem->contact_id, ), ts('more'), FALSE, diff --git a/CRM/Financial/Page/BatchTransaction.php b/CRM/Financial/Page/BatchTransaction.php index 3ac585d7ac..4e5fb2d32b 100644 --- a/CRM/Financial/Page/BatchTransaction.php +++ b/CRM/Financial/Page/BatchTransaction.php @@ -109,7 +109,7 @@ class CRM_Financial_Page_BatchTransaction extends CRM_Core_Page_Basic { 'title' => ts('Accounting Batches'), 'url' => CRM_Utils_System::url('civicrm/financial/financialbatches', "reset=1&batchStatus=$statusID"), - ) + ), ); CRM_Utils_System::appendBreadCrumb($breadCrumb); diff --git a/CRM/Friend/BAO/Friend.php b/CRM/Friend/BAO/Friend.php index 95f5c55861..91e54dd471 100644 --- a/CRM/Friend/BAO/Friend.php +++ b/CRM/Friend/BAO/Friend.php @@ -157,7 +157,7 @@ class CRM_Friend_BAO_Friend extends CRM_Friend_DAO_Friend { $targetParams = array( 'activity_id' => $activity->id, 'contact_id' => $contact, - 'record_type_id' => $targetID + 'record_type_id' => $targetID, ); // See if it already exists diff --git a/CRM/Logging/ReportSummary.php b/CRM/Logging/ReportSummary.php index e81fdbce48..1f4f58424d 100644 --- a/CRM/Logging/ReportSummary.php +++ b/CRM/Logging/ReportSummary.php @@ -79,7 +79,7 @@ class CRM_Logging_ReportSummary extends CRM_Report_Form { 'entity_table' => TRUE, 'bracket_info' => array( 'table' => 'log_civicrm_note', - 'column' => 'subject' + 'column' => 'subject', ), ), 'log_civicrm_note_comment' => array( @@ -87,12 +87,12 @@ class CRM_Logging_ReportSummary extends CRM_Report_Form { 'table_name' => 'log_civicrm_note', 'joins' => array( 'table' => 'log_civicrm_note', - 'join' => "entity_log_civireport.entity_id = fk_table.id AND entity_log_civireport.entity_table = 'civicrm_note'" + 'join' => "entity_log_civireport.entity_id = fk_table.id AND entity_log_civireport.entity_table = 'civicrm_note'", ), 'entity_table' => TRUE, 'bracket_info' => array( 'table' => 'log_civicrm_note', - 'column' => 'subject' + 'column' => 'subject', ), ), 'log_civicrm_group_contact' => array( @@ -100,7 +100,7 @@ class CRM_Logging_ReportSummary extends CRM_Report_Form { 'bracket_info' => array( 'entity_column' => 'group_id', 'table' => 'log_civicrm_group', - 'column' => 'title' + 'column' => 'title', ), 'action_column' => 'status', 'log_type' => 'Group', @@ -110,16 +110,16 @@ class CRM_Logging_ReportSummary extends CRM_Report_Form { 'bracket_info' => array( 'entity_column' => 'tag_id', 'table' => 'log_civicrm_tag', - 'column' => 'name' + 'column' => 'name', ), - 'entity_table' => TRUE + 'entity_table' => TRUE, ), 'log_civicrm_relationship' => array( 'fk' => 'contact_id_a', 'bracket_info' => array( 'entity_column' => 'relationship_type_id', 'table' => 'log_civicrm_relationship_type', - 'column' => 'label_a_b' + 'column' => 'label_a_b', ), ), 'log_civicrm_activity_for_target' => array( @@ -127,11 +127,11 @@ class CRM_Logging_ReportSummary extends CRM_Report_Form { 'table_name' => 'log_civicrm_activity', 'joins' => array( 'table' => 'log_civicrm_activity_contact', - 'join' => "(entity_log_civireport.id = fk_table.activity_id AND fk_table.record_type_id = {$targetID})" + 'join' => "(entity_log_civireport.id = fk_table.activity_id AND fk_table.record_type_id = {$targetID})", ), 'bracket_info' => array( 'entity_column' => 'activity_type_id', - 'options' => CRM_Core_PseudoConstant::activityType(TRUE, TRUE, FALSE, 'label', TRUE) + 'options' => CRM_Core_PseudoConstant::activityType(TRUE, TRUE, FALSE, 'label', TRUE), ), 'log_type' => 'Activity', ), @@ -140,11 +140,11 @@ class CRM_Logging_ReportSummary extends CRM_Report_Form { 'table_name' => 'log_civicrm_activity', 'joins' => array( 'table' => 'log_civicrm_activity_contact', - 'join' => "entity_log_civireport.id = fk_table.activity_id AND fk_table.record_type_id = {$assigneeID}" + 'join' => "entity_log_civireport.id = fk_table.activity_id AND fk_table.record_type_id = {$assigneeID}", ), 'bracket_info' => array( 'entity_column' => 'activity_type_id', - 'options' => CRM_Core_PseudoConstant::activityType(TRUE, TRUE, FALSE, 'label', TRUE) + 'options' => CRM_Core_PseudoConstant::activityType(TRUE, TRUE, FALSE, 'label', TRUE), ), 'log_type' => 'Activity', ), @@ -153,11 +153,11 @@ class CRM_Logging_ReportSummary extends CRM_Report_Form { 'table_name' => 'log_civicrm_activity', 'joins' => array( 'table' => 'log_civicrm_activity_contact', - 'join' => "entity_log_civireport.id = fk_table.activity_id AND fk_table.record_type_id = {$sourceID}" + 'join' => "entity_log_civireport.id = fk_table.activity_id AND fk_table.record_type_id = {$sourceID}", ), 'bracket_info' => array( 'entity_column' => 'activity_type_id', - 'options' => CRM_Core_PseudoConstant::activityType(TRUE, TRUE, FALSE, 'label', TRUE) + 'options' => CRM_Core_PseudoConstant::activityType(TRUE, TRUE, FALSE, 'label', TRUE), ), 'log_type' => 'Activity', ), @@ -165,11 +165,11 @@ class CRM_Logging_ReportSummary extends CRM_Report_Form { 'fk' => 'contact_id', 'joins' => array( 'table' => 'log_civicrm_case_contact', - 'join' => 'entity_log_civireport.id = fk_table.case_id' + 'join' => 'entity_log_civireport.id = fk_table.case_id', ), 'bracket_info' => array( 'entity_column' => 'case_type_id', - 'options' => CRM_Case_PseudoConstant::caseType('title', FALSE) + 'options' => CRM_Case_PseudoConstant::caseType('title', FALSE), ), ), ); @@ -181,7 +181,7 @@ class CRM_Logging_ReportSummary extends CRM_Report_Form { foreach ($customTables as $table) { $this->_logTables[$table] = array( 'fk' => 'entity_id', - 'log_type' => 'Contact' + 'log_type' => 'Contact', ); } @@ -193,9 +193,9 @@ class CRM_Logging_ReportSummary extends CRM_Report_Form { 'fk' => 'contact_id',// for join of fk_table with contact table 'joins' => array( 'table' => 'log_civicrm_address', // fk_table - 'join' => 'entity_log_civireport.entity_id = fk_table.id' + 'join' => 'entity_log_civireport.entity_id = fk_table.id', ), - 'log_type' => 'Contact' + 'log_type' => 'Contact', ); } @@ -333,7 +333,7 @@ ORDER BY log_civicrm_entity_log_date DESC {$this->_limit}"; $sql = str_replace('modified_contact_civireport.id', 'entity_log_civireport.altered_contact_id', $sql); $sql = str_replace(array( 'modified_contact_civireport.', - 'altered_by_contact_civireport.' + 'altered_by_contact_civireport.', ), 'entity_log_civireport.', $sql); $this->buildRows($sql, $rows); @@ -378,9 +378,9 @@ SELECT {$this->_logTables[$entity]['bracket_info']['entity_column']} $entityID = CRM_Core_DAO::singleValueQuery($sql, array( 1 => array( CRM_Utils_Date::isoToMysql($logDate), - 'Timestamp' + 'Timestamp', ), - 2 => array($id, 'Integer') + 2 => array($id, 'Integer'), )); } else { @@ -397,7 +397,7 @@ FROM `{$this->loggingDB}`.{$this->_logTables[$entity]['bracket_info']['table']} WHERE log_date <= %1 AND id = %2 ORDER BY log_date DESC LIMIT 1"; return CRM_Core_DAO::singleValueQuery($sql, array( 1 => array(CRM_Utils_Date::isoToMysql($logDate), 'Timestamp'), - 2 => array($entityID, 'Integer') + 2 => array($entityID, 'Integer'), )); } else { @@ -424,7 +424,7 @@ WHERE log_date <= %1 AND id = %2 ORDER BY log_date DESC LIMIT 1"; $sql = "select {$this->_logTables[$entity]['action_column']} from `{$this->loggingDB}`.{$entity} where id = %1 AND log_conn_id = %2"; $newAction = CRM_Core_DAO::singleValueQuery($sql, array( 1 => array($id, 'Integer'), - 2 => array($connId, 'Integer') + 2 => array($connId, 'Integer'), )); switch ($entity) { diff --git a/CRM/Logging/Schema.php b/CRM/Logging/Schema.php index 670a754e16..d5e7608d58 100644 --- a/CRM/Logging/Schema.php +++ b/CRM/Logging/Schema.php @@ -413,7 +413,7 @@ WHERE table_schema IN ('{$this->db}', '{$civiDB}')"; 'COLUMN_NAME' => $dao->COLUMN_NAME, 'DATA_TYPE' => $dao->DATA_TYPE, 'IS_NULLABLE' => $dao->IS_NULLABLE, - 'COLUMN_DEFAULT' => $dao->COLUMN_DEFAULT + 'COLUMN_DEFAULT' => $dao->COLUMN_DEFAULT, ); } } diff --git a/CRM/Mailing/BAO/Mailing.php b/CRM/Mailing/BAO/Mailing.php index 48aa7e62f9..c016b194f3 100644 --- a/CRM/Mailing/BAO/Mailing.php +++ b/CRM/Mailing/BAO/Mailing.php @@ -2973,7 +2973,7 @@ AND m.id = %1 'url' => 'civicrm/mailing/report', 'qs' => "mid=%%mid%%&reset=1&cid=%%cid%%&context=mailing", 'title' => ts('View Mailing Report'), - ) + ), ); $mailingKey = $values['mailing_id']; diff --git a/CRM/Mailing/BAO/Query.php b/CRM/Mailing/BAO/Query.php index 4cc084c077..d1d8ec871d 100644 --- a/CRM/Mailing/BAO/Query.php +++ b/CRM/Mailing/BAO/Query.php @@ -216,7 +216,7 @@ class CRM_Mailing_BAO_Query { 'mailing_job_end_date' => 1, 'contact_type' => 1, 'contact_sub_type' => 1, - 'mailing_recipients_id' => 1 + 'mailing_recipients_id' => 1, ); } return $properties; @@ -399,7 +399,7 @@ class CRM_Mailing_BAO_Query { 'Complete' => 'Complete', 'Scheduled' => 'Scheduled', 'Running' => 'Running', - 'Canceled' => 'Canceled' + 'Canceled' => 'Canceled', ); $form->addElement('select', 'mailing_job_status', ts('Mailing Job Status'), $mailingJobStatuses, FALSE); diff --git a/CRM/Mailing/Form/Component.php b/CRM/Mailing/Form/Component.php index d2d3cae9aa..14f70362e8 100644 --- a/CRM/Mailing/Form/Component.php +++ b/CRM/Mailing/Form/Component.php @@ -140,7 +140,7 @@ class CRM_Mailing_Form_Component extends CRM_Core_Form { $component = CRM_Mailing_BAO_Component::add($params); CRM_Core_Session::setStatus(ts('The mailing component \'%1\' has been saved.', array( - 1 => $component->name + 1 => $component->name, ) ), ts('Saved'), 'success'); diff --git a/CRM/Mailing/Form/Group.php b/CRM/Mailing/Form/Group.php index 6c0d168d89..097390ab34 100644 --- a/CRM/Mailing/Form/Group.php +++ b/CRM/Mailing/Form/Group.php @@ -128,7 +128,7 @@ class CRM_Mailing_Form_Group extends CRM_Contact_Form_Task { $mailingGroups = array( 'civicrm_group' => array(), - 'civicrm_mailing' => array() + 'civicrm_mailing' => array(), ); $dao->mailing_id = $this->_mailingID; $dao->find(); diff --git a/CRM/Mailing/Selector/Search.php b/CRM/Mailing/Selector/Search.php index 2173cc9ba9..d570f14ab3 100644 --- a/CRM/Mailing/Selector/Search.php +++ b/CRM/Mailing/Selector/Search.php @@ -72,7 +72,7 @@ class CRM_Mailing_Selector_Search extends CRM_Core_Selector_Base implements CRM_ 'email_on_hold', 'contact_opt_out', 'mailing_job_status', - 'mailing_job_end_date' + 'mailing_job_end_date', ); /** diff --git a/CRM/Member/BAO/Membership.php b/CRM/Member/BAO/Membership.php index 1bac5735b6..506612f6e4 100644 --- a/CRM/Member/BAO/Membership.php +++ b/CRM/Member/BAO/Membership.php @@ -348,7 +348,7 @@ class CRM_Member_BAO_Membership extends CRM_Member_DAO_Membership { if (!empty($params['relate_contribution_id'])) { CRM_Member_BAO_MembershipPayment::create(array( 'membership_id' => $membership->id, - 'contribution_id' => $params['relate_contribution_id'] + 'contribution_id' => $params['relate_contribution_id'], )); } @@ -534,7 +534,7 @@ class CRM_Member_BAO_Membership extends CRM_Member_DAO_Membership { $statusANDType = self::getStatusANDTypeValues($membership->id); foreach (array( 'status', - 'membership_type' + 'membership_type', ) as $fld) { $defaults[$fld] = CRM_Utils_Array::value($fld, $statusANDType[$membership->id]); } @@ -583,7 +583,7 @@ INNER JOIN civicrm_membership_type type ON ( type.id = membership.membership_ty 'membership_type', 'membership_type_id', 'is_current_member', - 'relationship_type_id' + 'relationship_type_id', ); while ($dao->fetch()) { foreach ($properties as $property) { @@ -644,7 +644,7 @@ INNER JOIN civicrm_membership_type type ON ( type.id = membership.membership_ty 'Membership Renewal', 'Change Membership Status', 'Change Membership Type', - 'Membership Renewal Reminder' + 'Membership Renewal Reminder', ); foreach ($membershipActivities as $membershipActivity) { $activityId = array_search($membershipActivity, $activityTypes); @@ -1163,7 +1163,7 @@ INNER JOIN civicrm_membership_type type ON ( type.id = membership.membership_ty 'name' => 'membership_status', 'type' => CRM_Utils_Type::T_STRING, 'where' => 'civicrm_membership_status.name', - ) + ), ); //CRM-6161 fix for customdata export $fields = array_merge($fields, $membershipStatus, CRM_Core_BAO_CustomField::getFieldsForImport('Membership')); @@ -1454,7 +1454,7 @@ AND civicrm_membership.is_test = %2"; try { civicrm_api3('contribution', 'completetransaction', array( 'id' => $membershipContribution->id, - 'trxn_id' => $membershipContribution->trxn_id + 'trxn_id' => $membershipContribution->trxn_id, )); } catch (CiviCRM_API3_Exception $e) { @@ -2289,7 +2289,7 @@ INNER JOIN civicrm_contact contact ON ( contact.id = membership.contact_id AND public static function linkMembershipPayment($membership, $membershipContribution) { CRM_Member_BAO_MembershipPayment::create(array( 'membership_id' => $membership->id, - 'contribution_id' => $membershipContribution->id + 'contribution_id' => $membershipContribution->id, )); } @@ -2824,7 +2824,7 @@ WHERE civicrm_membership.is_test = 0"; array( 'membership_id' => $dao->membership_id, 'version' => 3, - 'ignore_admin_only' => FALSE + 'ignore_admin_only' => FALSE, ), TRUE ); $statusId = CRM_Utils_Array::value('id', $newStatus); @@ -2864,7 +2864,7 @@ WHERE civicrm_membership.is_test = 0"; $result['is_error'] = 0; $result['messages'] = ts('Processed %1 membership records. Updated %2 records.', array( 1 => $processCount, - 2 => $updateCount + 2 => $updateCount, )); return $result; } @@ -2946,7 +2946,7 @@ WHERE civicrm_membership.is_test = 0"; 'is_pay_later', 'membership_id', 'tax_amount', - 'skipLineItem' + 'skipLineItem', ); foreach ($recordContribution as $f) { $contributionParams[$f] = CRM_Utils_Array::value($f, $params); @@ -2994,7 +2994,7 @@ WHERE civicrm_membership.is_test = 0"; if (empty($ids['contribution']) || !empty($params['is_recur'])) { CRM_Member_BAO_MembershipPayment::create(array( 'membership_id' => $membershipId, - 'contribution_id' => $contribution->id + 'contribution_id' => $contribution->id, )); } return $contribution; @@ -3082,7 +3082,7 @@ WHERE civicrm_membership.is_test = 0"; TRUE ) ), - 'Integer' + 'Integer', ), 3 => array($isTest, 'Boolean'), ); diff --git a/CRM/Member/Form.php b/CRM/Member/Form.php index 5e58261d08..43e2da35e5 100644 --- a/CRM/Member/Form.php +++ b/CRM/Member/Form.php @@ -135,12 +135,12 @@ class CRM_Member_Form extends CRM_Contribute_Form_AbstractEditPayment { array( 'type' => 'upload', 'name' => ts('Renew'), - 'isDefault' => TRUE + 'isDefault' => TRUE, ), array( 'type' => 'cancel', - 'name' => ts('Cancel') - ) + 'name' => ts('Cancel'), + ), ) ); } @@ -149,12 +149,12 @@ class CRM_Member_Form extends CRM_Contribute_Form_AbstractEditPayment { array( 'type' => 'next', 'name' => ts('Delete'), - 'isDefault' => TRUE + 'isDefault' => TRUE, ), array( 'type' => 'cancel', - 'name' => ts('Cancel') - ) + 'name' => ts('Cancel'), + ), ) ); } @@ -163,17 +163,17 @@ class CRM_Member_Form extends CRM_Contribute_Form_AbstractEditPayment { array( 'type' => 'upload', 'name' => ts('Save'), - 'isDefault' => TRUE + 'isDefault' => TRUE, ), array( 'type' => 'upload', 'name' => ts('Save and New'), - 'subName' => 'new' + 'subName' => 'new', ), array( 'type' => 'cancel', - 'name' => ts('Cancel') - ) + 'name' => ts('Cancel'), + ), ) ); } diff --git a/CRM/Member/Form/Membership.php b/CRM/Member/Form/Membership.php index 054e10836b..3af48bb184 100644 --- a/CRM/Member/Form/Membership.php +++ b/CRM/Member/Form/Membership.php @@ -426,7 +426,7 @@ class CRM_Member_Form_Membership extends CRM_Member_Form { if ($buildPriceSet) { $this->add('select', 'price_set_id', ts('Choose price set'), array( - '' => ts('Choose price set') + '' => ts('Choose price set'), ) + $priceSets, NULL, array('onchange' => "buildAmount( this.value );") ); @@ -553,7 +553,7 @@ WHERE id IN ( ' . implode(' , ', array_keys($membershipType)) . ' )'; 'id', 'auto_renew', 'duration_unit', - 'duration_interval' + 'duration_interval', ) as $fld) { $this->_recurMembershipTypes[$recurMembershipTypes->id][$fld] = $recurMembershipTypes->$fld; } @@ -652,7 +652,7 @@ WHERE id IN ( ' . implode(' , ', array_keys($membershipType)) . ' )'; foreach ($statusNames as $val => $name) { if (in_array($name, array( 'In Progress', - 'Overdue' + 'Overdue', )) ) { continue; @@ -1645,7 +1645,7 @@ WHERE id IN ( ' . implode(' , ', array_keys($membershipType)) . ' )'; foreach ($membershipTypes as $memType => $membershipType) { $statusMsg[$memType] = ts('%1 membership for %2 has been added.', array( 1 => $membershipType, - 2 => $this->_memberDisplayName + 2 => $this->_memberDisplayName, )); $membership = $createdMemberships[$memType]; @@ -1859,7 +1859,7 @@ WHERE id IN ( ' . implode(' , ', array_keys($membershipType)) . ' )'; 'PDFFilename' => ts('receipt') . '.pdf', 'isEmailPdf' => $isEmailPdf, 'contributionId' => $formValues['contribution_id'], - 'isTest' => (bool) ($form->_action & CRM_Core_Action::PREVIEW) + 'isTest' => (bool) ($form->_action & CRM_Core_Action::PREVIEW), ) ); diff --git a/CRM/Member/Form/MembershipConfig.php b/CRM/Member/Form/MembershipConfig.php index 93b8fd1872..f044f0b8b1 100644 --- a/CRM/Member/Form/MembershipConfig.php +++ b/CRM/Member/Form/MembershipConfig.php @@ -107,12 +107,12 @@ class CRM_Member_Form_MembershipConfig extends CRM_Core_Form { array( 'type' => 'upload', 'name' => ts('Renew'), - 'isDefault' => TRUE + 'isDefault' => TRUE, ), array( 'type' => 'cancel', - 'name' => ts('Cancel') - ) + 'name' => ts('Cancel'), + ), ) ); } @@ -121,12 +121,12 @@ class CRM_Member_Form_MembershipConfig extends CRM_Core_Form { array( 'type' => 'next', 'name' => ts('Delete'), - 'isDefault' => TRUE + 'isDefault' => TRUE, ), array( 'type' => 'cancel', - 'name' => ts('Cancel') - ) + 'name' => ts('Cancel'), + ), ) ); } @@ -135,17 +135,17 @@ class CRM_Member_Form_MembershipConfig extends CRM_Core_Form { array( 'type' => 'upload', 'name' => ts('Save'), - 'isDefault' => TRUE + 'isDefault' => TRUE, ), array( 'type' => 'upload', 'name' => ts('Save and New'), - 'subName' => 'new' + 'subName' => 'new', ), array( 'type' => 'cancel', - 'name' => ts('Cancel') - ) + 'name' => ts('Cancel'), + ), ) ); } diff --git a/CRM/Member/Form/MembershipRenewal.php b/CRM/Member/Form/MembershipRenewal.php index 4e621ff87e..98dac2dfc6 100644 --- a/CRM/Member/Form/MembershipRenewal.php +++ b/CRM/Member/Form/MembershipRenewal.php @@ -294,7 +294,7 @@ class CRM_Member_Form_MembershipRenewal extends CRM_Member_Form { $allMembershipInfo[$key] = array( 'financial_type_id' => CRM_Utils_Array::value('financial_type_id', $values), 'total_amount' => CRM_Utils_Money::format($values['minimum_fee'], NULL, '%a'), - 'total_amount_numeric' => CRM_Utils_Array::value('minimum_fee', $values) + 'total_amount_numeric' => CRM_Utils_Array::value('minimum_fee', $values), ); if (!empty($values['auto_renew'])) { diff --git a/CRM/Member/Form/MembershipType.php b/CRM/Member/Form/MembershipType.php index e365c21917..13dee0da3e 100644 --- a/CRM/Member/Form/MembershipType.php +++ b/CRM/Member/Form/MembershipType.php @@ -322,7 +322,7 @@ class CRM_Member_Form_MembershipType extends CRM_Member_Form_MembershipConfig { 'fixed_period_start_day', 'fixed_period_rollover_day', 'month_fixed_period_rollover_day', - 'max_related' + 'max_related', ); $params = $ids = array(); diff --git a/CRM/Member/Form/MembershipView.php b/CRM/Member/Form/MembershipView.php index 5558b47c07..d052c33068 100644 --- a/CRM/Member/Form/MembershipView.php +++ b/CRM/Member/Form/MembershipView.php @@ -272,7 +272,7 @@ SELECT r.id, c.id as cid, c.display_name as name, c.job_title as comment, 'start_date', 'end_date', 'is_current_member', - 'status' + 'status', ); while ($dao->fetch()) { diff --git a/CRM/PCP/BAO/PCP.php b/CRM/PCP/BAO/PCP.php index 47d008585b..9dc4926209 100644 --- a/CRM/PCP/BAO/PCP.php +++ b/CRM/PCP/BAO/PCP.php @@ -394,7 +394,7 @@ WHERE pcp.id = %1 AND cc.contribution_status_id =1 AND cc.is_test = 0"; } CRM_Core_DAO::commonRetrieveAll('CRM_Core_DAO_UFGroup', 'is_cms_user', $isUserRequired, $profiles, array( 'title', - 'is_active' + 'is_active', )); if (!empty($profiles)) { foreach ($profiles as $key => $value) { @@ -614,7 +614,7 @@ WHERE pcp.id = %1 AND cc.contribution_status_id =1 AND cc.is_test = 0"; CRM_Core_Session::setStatus(ts("%1 status has been updated to %2.", array( 1 => $pcpTitle, - 2 => $pcpStatus + 2 => $pcpStatus, )), 'Status Updated', 'success'); // send status change mail diff --git a/CRM/Price/BAO/LineItem.php b/CRM/Price/BAO/LineItem.php index e62eacbdfd..cf5ca5e0d2 100644 --- a/CRM/Price/BAO/LineItem.php +++ b/CRM/Price/BAO/LineItem.php @@ -506,7 +506,7 @@ AND li.entity_id = {$entityId} 'unit_price' => $totalAmount, 'line_total' => $totalAmount, 'financial_type_id' => $financialType, - 'membership_type_id' => $values['membership_type_id'] + 'membership_type_id' => $values['membership_type_id'], ); break; } diff --git a/CRM/Price/Page/Field.php b/CRM/Price/Page/Field.php index 4f9b192cc0..cc3e045631 100644 --- a/CRM/Price/Page/Field.php +++ b/CRM/Price/Page/Field.php @@ -269,7 +269,7 @@ class CRM_Price_Page_Field extends CRM_Core_Page { $comps = array( 'Event' => 'civicrm_event', 'Contribution' => 'civicrm_contribution_page', - 'EventTemplate' => 'civicrm_event_template' + 'EventTemplate' => 'civicrm_event_template', ); $priceSetContexts = array(); foreach ($comps as $name => $table) { diff --git a/CRM/Price/Page/Set.php b/CRM/Price/Page/Set.php index 272a42cbc6..1773c0face 100644 --- a/CRM/Price/Page/Set.php +++ b/CRM/Price/Page/Set.php @@ -178,7 +178,7 @@ class CRM_Price_Page_Set extends CRM_Core_Page { $comps = array( 'Event' => 'civicrm_event', 'Contribution' => 'civicrm_contribution_page', - 'EventTemplate' => 'civicrm_event_template' + 'EventTemplate' => 'civicrm_event_template', ); $priceSetContexts = array(); foreach ($comps as $name => $table) { diff --git a/CRM/Profile/Form.php b/CRM/Profile/Form.php index 3bcc0e73d9..aa8d60cdd4 100644 --- a/CRM/Profile/Form.php +++ b/CRM/Profile/Form.php @@ -1073,7 +1073,7 @@ class CRM_Profile_Form extends CRM_Core_Form { $sql = "DELETE FROM {$tableName} WHERE id = %1 AND entity_id = %2"; $sqlParams = array( 1 => array($this->_recordId, 'Integer'), - 2 => array($this->_id, 'Integer') + 2 => array($this->_id, 'Integer'), ); CRM_Core_DAO::executeQuery($sql, $sqlParams); CRM_Core_Session::setStatus(ts('Your record has been deleted.'), ts('Deleted'), 'success'); diff --git a/CRM/Profile/Page/MultipleRecordFieldsListing.php b/CRM/Profile/Page/MultipleRecordFieldsListing.php index c8bdf03abf..f06e64eeec 100644 --- a/CRM/Profile/Page/MultipleRecordFieldsListing.php +++ b/CRM/Profile/Page/MultipleRecordFieldsListing.php @@ -120,7 +120,7 @@ class CRM_Profile_Page_MultipleRecordFieldsListing extends CRM_Core_Page_Basic { 'name' => ts('Copy'), 'title' => ts('Copy %1', array(1 => $this->_customGroupTitle . ' record')), 'url' => 'civicrm/contact/view/cd/edit', - 'qs' => 'reset=1&type=%%type%%&groupID=%%groupID%%&entityID=%%entityID%%&cgcount=%%newCgCount%%&multiRecordDisplay=single©ValueId=%%cgcount%%&mode=copy' + 'qs' => 'reset=1&type=%%type%%&groupID=%%groupID%%&entityID=%%entityID%%&cgcount=%%newCgCount%%&multiRecordDisplay=single©ValueId=%%cgcount%%&mode=copy', ); } diff --git a/CRM/Report/Form.php b/CRM/Report/Form.php index 525f4a975f..8b9ba4dd28 100644 --- a/CRM/Report/Form.php +++ b/CRM/Report/Form.php @@ -478,7 +478,7 @@ class CRM_Report_Form extends CRM_Core_Form { array( 'title' => ts('Report Templates'), 'url' => CRM_Utils_System::url('civicrm/admin/report/template/list', 'reset=1'), - ) + ), ); CRM_Utils_System::appendBreadCrumb($breadCrumbs); @@ -597,7 +597,7 @@ class CRM_Report_Form extends CRM_Core_Form { array( '' => ts('Any'), '0' => ts('No'), - '1' => ts('Yes') + '1' => ts('Yes'), ); } break; @@ -962,7 +962,7 @@ class CRM_Report_Form extends CRM_Core_Form { $this->addChainSelect($fieldName . '_value', array( 'multiple' => TRUE, 'label' => NULL, - 'class' => 'huge' + 'class' => 'huge', )); } else { @@ -1114,13 +1114,13 @@ class CRM_Report_Form extends CRM_Core_Form { if (!empty($options)) { $options = array( - '-' => ' - none - ' + '-' => ' - none - ', ) + $options; for ($i = 1; $i <= 5; $i++) { $this->addElement('select', "order_bys[{$i}][column]", ts('Order by Column'), $options); $this->addElement('select', "order_bys[{$i}][order]", ts('Order by Order'), array( 'ASC' => 'Ascending', - 'DESC' => 'Descending' + 'DESC' => 'Descending', )); $this->addElement('checkbox', "order_bys[{$i}][section]", ts('Order by Section'), FALSE, array('id' => "order_by_section_$i")); $this->addElement('checkbox', "order_bys[{$i}][pageBreak]", ts('Page Break'), FALSE, array('id' => "order_by_pagebreak_$i")); @@ -1195,7 +1195,7 @@ class CRM_Report_Form extends CRM_Core_Form { //add form rule for report if (is_callable(array( $this, - 'formRule' + 'formRule', ))) { $this->addFormRule(array(get_class($this), 'formRule'), $this); } @@ -1715,7 +1715,7 @@ class CRM_Report_Form extends CRM_Core_Form { 'data_type', 'html_type', 'option_group_id', - 'id' + 'id', ); // skip for type date and ContactReference since date format is already handled @@ -1812,7 +1812,7 @@ WHERE cg.extends IN ('" . implode("','", $this->_customGroupExtends) . "') AND case 'Int': if (in_array($htmlType, array( 'Text', - 'TextArea' + 'TextArea', ))) { $retValue = $value; break; @@ -3227,7 +3227,7 @@ ORDER BY cg.weight, cf.weight"; foreach (array( 'fields', 'filters', - 'group_bys' + 'group_bys', ) as $colKey) { if (!array_key_exists($colKey, $this->_columns[$curTable])) { $this->_columns[$curTable][$colKey] = array(); @@ -3298,7 +3298,7 @@ ORDER BY cg.weight, cf.weight"; if (in_array($customDAO->html_type, array( 'Multi-Select', 'AdvMulti-Select', - 'CheckBox' + 'CheckBox', ))) { $curFilters[$fieldName]['operatorType'] = CRM_Report_Form::OP_MULTISELECT_SEPARATOR; } @@ -3310,8 +3310,8 @@ ORDER BY cg.weight, cf.weight"; $ogDAO = CRM_Core_DAO::executeQuery("SELECT ov.value, ov.label FROM civicrm_option_value ov WHERE ov.option_group_id = %1 ORDER BY ov.weight", array( 1 => array( $customDAO->option_group_id, - 'Integer' - ) + 'Integer', + ), )); while ($ogDAO->fetch()) { $curFilters[$fieldName]['options'][$ogDAO->value] = $ogDAO->label; @@ -3322,7 +3322,7 @@ ORDER BY cg.weight, cf.weight"; case 'StateProvince': if (in_array($customDAO->html_type, array( - 'Multi-Select State/Province' + 'Multi-Select State/Province', ))) { $curFilters[$fieldName]['operatorType'] = CRM_Report_Form::OP_MULTISELECT_SEPARATOR; } @@ -3334,7 +3334,7 @@ ORDER BY cg.weight, cf.weight"; case 'Country': if (in_array($customDAO->html_type, array( - 'Multi-Select Country' + 'Multi-Select Country', ))) { $curFilters[$fieldName]['operatorType'] = CRM_Report_Form::OP_MULTISELECT_SEPARATOR; } @@ -3470,7 +3470,7 @@ LEFT JOIN civicrm_contact {$field['alias']} ON {$field['alias']}.id = {$this->_a 'max', 'relative', 'from', - 'to' + 'to', ) as $attach) { if (isset($this->_params[$fieldAlias . '_' . $attach]) && (!empty($this->_params[$fieldAlias . '_' . $attach]) @@ -3899,7 +3899,7 @@ LEFT JOIN civicrm_contact {$field['alias']} ON {$field['alias']}.id = {$this->_a 'fields' => array( $options['prefix'] . 'phone' => array( 'title' => ts($options['prefix_label'] . 'Phone'), - 'name' => 'phone' + 'name' => 'phone', ), ), ), diff --git a/CRM/Report/Form/Activity.php b/CRM/Report/Form/Activity.php index 8224e3a647..f5e4eb2230 100644 --- a/CRM/Report/Form/Activity.php +++ b/CRM/Report/Form/Activity.php @@ -36,7 +36,7 @@ class CRM_Report_Form_Activity extends CRM_Report_Form { protected $_selectAliasesTotal = array(); protected $_customGroupExtends = array( - 'Activity' + 'Activity', ); protected $_nonDisplayFields = array(); @@ -207,7 +207,7 @@ class CRM_Report_Form_Activity extends CRM_Report_Form { ), 'details' => array( 'title' => ts('Activity Details'), - ) + ), ), 'filters' => array( 'activity_date_time' => array( @@ -228,18 +228,18 @@ class CRM_Report_Form_Activity extends CRM_Report_Form { 'details' => array( 'title' => ts('Activity Details'), 'type' => CRM_Utils_Type::T_TEXT, - ) + ), ), 'order_bys' => array( 'activity_date_time' => array( 'title' => ts('Activity Date'), 'default_weight' => '1', - 'dbAlias' => 'civicrm_activity_activity_date_time' + 'dbAlias' => 'civicrm_activity_activity_date_time', ), 'activity_type_id' => array( 'title' => ts('Activity Type'), 'default_weight' => '2', - 'dbAlias' => "option_value_civireport" + 'dbAlias' => "option_value_civireport", ), ), 'grouping' => 'activity-fields', diff --git a/CRM/Report/Form/ActivitySummary.php b/CRM/Report/Form/ActivitySummary.php index 34756bfdff..807d92d17e 100644 --- a/CRM/Report/Form/ActivitySummary.php +++ b/CRM/Report/Form/ActivitySummary.php @@ -73,7 +73,7 @@ class CRM_Report_Form_ActivitySummary extends CRM_Report_Form { ), 'order_bys' => array( 'sort_name' => array( - 'title' => ts('Contact Name') + 'title' => ts('Contact Name'), ), ), 'grouping' => 'contact-fields', @@ -88,7 +88,7 @@ class CRM_Report_Form_ActivitySummary extends CRM_Report_Form { ), 'order_bys' => array( 'email' => array( - 'title' => ts('Email') + 'title' => ts('Email'), ), ), 'grouping' => 'contact-fields', @@ -97,7 +97,7 @@ class CRM_Report_Form_ActivitySummary extends CRM_Report_Form { 'dao' => 'CRM_Core_DAO_Email', 'fields' => array( 'phone' => array( - 'title' => 'Phone' + 'title' => 'Phone', ), ), 'grouping' => 'contact-fields', @@ -126,7 +126,7 @@ class CRM_Report_Form_ActivitySummary extends CRM_Report_Form { ), 'filters' => array( 'activity_date_time' => array( - 'operatorType' => CRM_Report_Form::OP_DATE + 'operatorType' => CRM_Report_Form::OP_DATE, ), 'activity_type_id' => array( 'title' => ts('Activity Type'), @@ -156,10 +156,10 @@ class CRM_Report_Form_ActivitySummary extends CRM_Report_Form { ), 'order_bys' => array( 'activity_date_time' => array( - 'title' => ts('Activity Date') + 'title' => ts('Activity Date'), ), 'activity_type_id' => array( - 'title' => ts('Activity Type') + 'title' => ts('Activity Type'), ), ), 'grouping' => 'activity-fields', diff --git a/CRM/Report/Form/Campaign/SurveyDetails.php b/CRM/Report/Form/Campaign/SurveyDetails.php index f070f017c6..f5e0571de3 100644 --- a/CRM/Report/Form/Campaign/SurveyDetails.php +++ b/CRM/Report/Form/Campaign/SurveyDetails.php @@ -47,7 +47,7 @@ class CRM_Report_Form_Campaign_SurveyDetails extends CRM_Report_Form { 'Individual', 'Household', 'Organization', - 'Activity' + 'Activity', ); public $_drilldownReport = array('contact/detail' => 'Link to Detail Report'); @@ -101,9 +101,9 @@ class CRM_Report_Form_Campaign_SurveyDetails extends CRM_Report_Form { 'type' => CRM_Utils_Type::T_INT, 'operatorType' => CRM_Report_Form::OP_SELECT, 'options' => array( - '' => ts('- any interviewer -') + '' => ts('- any interviewer -'), ) + $allSurveyInterviewers, - ) + ), ), 'grouping' => 'survey-interviewer-fields', ), @@ -125,14 +125,14 @@ class CRM_Report_Form_Campaign_SurveyDetails extends CRM_Report_Form { 'sort_name' => array( 'title' => ts('Respondent Name'), 'operator' => 'like', - ) + ), ), 'grouping' => 'contact-fields', 'order_bys' => array( 'sort_name' => array( 'title' => ts('Respondent Name'), 'required' => TRUE, - ) + ), ), ), 'civicrm_phone' => array( @@ -141,7 +141,7 @@ class CRM_Report_Form_Campaign_SurveyDetails extends CRM_Report_Form { 'phone' => array( 'name' => 'phone', 'title' => ts('Phone'), - ) + ), ), 'grouping' => 'location-fields', ), @@ -233,7 +233,7 @@ class CRM_Report_Form_Campaign_SurveyDetails extends CRM_Report_Form { 'email' => array( 'name' => 'email', 'title' => ts('Email'), - ) + ), ), 'grouping' => 'location-fields', ), @@ -458,7 +458,7 @@ class CRM_Report_Form_Campaign_SurveyDetails extends CRM_Report_Form { $orderBys = CRM_Utils_Array::value('order_bys', $this->_params, array()); if (in_array($this->_outputMode, array( 'print', - 'pdf' + 'pdf', ))) { $outPut = array(); @@ -814,7 +814,7 @@ INNER JOIN civicrm_custom_group cg ON ( cg.id = cf.custom_group_id ) $value = $responseField->label; if (in_array($this->_outputMode, array( 'print', - 'pdf' + 'pdf', ))) { $value = $responseField->value; } @@ -941,7 +941,7 @@ INNER JOIN civicrm_custom_field cf ON ( cg.id = cf.custom_group_id ) $title = $responseFields[$fieldName]['title']; if (in_array($this->_outputMode, array( 'print', - 'pdf' + 'pdf', ))) { $title = 'Q' . $fildCnt++; } diff --git a/CRM/Report/Form/Case/Demographics.php b/CRM/Report/Form/Case/Demographics.php index 7abdc9b789..2dd854bbdd 100644 --- a/CRM/Report/Form/Case/Demographics.php +++ b/CRM/Report/Form/Case/Demographics.php @@ -169,7 +169,7 @@ class CRM_Report_Form_Case_Demographics extends CRM_Report_Form { 'options' => array( 1 => ts('Exclude non-case'), 2 => ts('Exclude cases'), - 3 => ts('Include Both') + 3 => ts('Include Both'), ), 'default' => 3, ), diff --git a/CRM/Report/Form/Case/Detail.php b/CRM/Report/Form/Case/Detail.php index 2b02d2b133..1ce27a138a 100644 --- a/CRM/Report/Form/Case/Detail.php +++ b/CRM/Report/Form/Case/Detail.php @@ -70,7 +70,7 @@ class CRM_Report_Form_Case_Detail extends CRM_Report_Form { $this->deleted_labels = array( '' => ts('- select -'), 0 => ts('No'), - 1 => ts('Yes') + 1 => ts('Yes'), ); $this->caseActivityTypes = array(); @@ -279,7 +279,7 @@ class CRM_Report_Form_Case_Detail extends CRM_Report_Form { $elements = array(); $elements[] = &$this->createElement('select', 'case_activity_all_dates', NULL, array( - '' => ts('- select -') + '' => ts('- select -'), ) + $this->caseActivityTypes ); $this->addGroup($elements, 'case_detail_extra'); diff --git a/CRM/Report/Form/Case/Summary.php b/CRM/Report/Form/Case/Summary.php index 4d40101c9a..0d619b9c93 100644 --- a/CRM/Report/Form/Case/Summary.php +++ b/CRM/Report/Form/Case/Summary.php @@ -56,7 +56,7 @@ class CRM_Report_Form_Case_Summary extends CRM_Report_Form { $this->deleted_labels = array( '' => ts('- select -'), 0 => ts('No'), - 1 => ts('Yes') + 1 => ts('Yes'), ); $this->_columns = array( diff --git a/CRM/Report/Form/Case/TimeSpent.php b/CRM/Report/Form/Case/TimeSpent.php index 584673a5cf..cb13438858 100644 --- a/CRM/Report/Form/Case/TimeSpent.php +++ b/CRM/Report/Form/Case/TimeSpent.php @@ -154,7 +154,7 @@ class CRM_Report_Form_Case_TimeSpent extends CRM_Report_Form { 'options' => array( 1 => ts('Exclude non-case'), 2 => ts('Exclude cases'), - 3 => ts('Include Both') + 3 => ts('Include Both'), ), 'default' => 3, ), diff --git a/CRM/Report/Form/Contact/CurrentEmployer.php b/CRM/Report/Form/Contact/CurrentEmployer.php index 22c6f2a57e..55e7935629 100644 --- a/CRM/Report/Form/Contact/CurrentEmployer.php +++ b/CRM/Report/Form/Contact/CurrentEmployer.php @@ -39,7 +39,7 @@ class CRM_Report_Form_Contact_CurrentEmployer extends CRM_Report_Form { protected $_customGroupExtends = array( 'Contact', - 'Individual' + 'Individual', ); public $_drilldownReport = array('contact/detail' => 'Link to Detail Report'); @@ -302,7 +302,7 @@ FROM civicrm_contact {$this->_aliases['civicrm_contact']} // get the acl clauses built before we assemble the query $this->buildACLClause(array( $this->_aliases['civicrm_contact'], - $this->_aliases['civicrm_employer'] + $this->_aliases['civicrm_employer'], )); parent::postProcess(); } diff --git a/CRM/Report/Form/Contact/Detail.php b/CRM/Report/Form/Contact/Detail.php index fb04d5da78..5d64032f57 100644 --- a/CRM/Report/Form/Contact/Detail.php +++ b/CRM/Report/Form/Contact/Detail.php @@ -41,7 +41,7 @@ class CRM_Report_Form_Contact_Detail extends CRM_Report_Form { 'Contact', 'Individual', 'Household', - 'Organization' + 'Organization', ); /** @@ -100,7 +100,7 @@ class CRM_Report_Form_Contact_Detail extends CRM_Report_Form { 'title' => ts('Last Name, First Name'), 'default' => '1', 'default_weight' => '0', - 'default_order' => 'ASC' + 'default_order' => 'ASC', ), ), ), @@ -335,8 +335,8 @@ class CRM_Report_Form_Contact_Detail extends CRM_Report_Form { 'fields' => array( 'phone' => NULL, 'phone_ext' => array( - 'title' => ts('Phone Extension') - ) + 'title' => ts('Phone Extension'), + ), ), 'grouping' => 'contact-fields', ), @@ -359,7 +359,7 @@ class CRM_Report_Form_Contact_Detail extends CRM_Report_Form { 'membership_civireport', 'participant_civireport', 'relationship_civireport', - 'activity_civireport' + 'activity_civireport', ); foreach ($this->_columns as $tableName => $table) { if (array_key_exists('fields', $table)) { diff --git a/CRM/Report/Form/Contact/Relationship.php b/CRM/Report/Form/Contact/Relationship.php index e6a4e6ffb4..eeaad5a89a 100644 --- a/CRM/Report/Form/Contact/Relationship.php +++ b/CRM/Report/Form/Contact/Relationship.php @@ -41,7 +41,7 @@ class CRM_Report_Form_Contact_Relationship extends CRM_Report_Form { protected $_phoneField_a = FALSE; protected $_phoneField_b = FALSE; protected $_customGroupExtends = array( - 'Relationship' + 'Relationship', ); public $_drilldownReport = array('contact/detail' => 'Link to Detail Report'); @@ -169,11 +169,11 @@ class CRM_Report_Form_Contact_Relationship extends CRM_Report_Form { 'fields' => array( 'phone_b' => array( 'title' => ts('Phone (Contact B)'), - 'name' => 'phone' + 'name' => 'phone', ), 'phone_ext_b' => array( 'title' => ts('Phone Ext (Contact B)'), - 'name' => 'phone_ext' + 'name' => 'phone_ext', ), ), 'grouping' => 'conact_b_fields', @@ -224,7 +224,7 @@ class CRM_Report_Form_Contact_Relationship extends CRM_Report_Form { 'title' => ts('Relationship'), 'operatorType' => CRM_Report_Form::OP_SELECT, 'options' => array( - '' => '- any relationship type -' + '' => '- any relationship type -', ) + CRM_Contact_BAO_Relationship::getContactRelationshipType(NULL, 'null', NULL, NULL, TRUE), 'type' => CRM_Utils_Type::T_INT, @@ -542,7 +542,7 @@ class CRM_Report_Form_Contact_Relationship extends CRM_Report_Form { $this->buildACLClause(array( $this->_aliases['civicrm_contact'], - $this->_aliases['civicrm_contact_b'] + $this->_aliases['civicrm_contact_b'], )); $sql = $this->buildQuery(); $this->buildRows($sql, $rows); diff --git a/CRM/Report/Form/Contact/Summary.php b/CRM/Report/Form/Contact/Summary.php index cea8831991..5f532f367e 100644 --- a/CRM/Report/Form/Contact/Summary.php +++ b/CRM/Report/Form/Contact/Summary.php @@ -45,7 +45,7 @@ class CRM_Report_Form_Contact_Summary extends CRM_Report_Form { 'Contact', 'Individual', 'Household', - 'Organization' + 'Organization', ); public $_drilldownReport = array('contact/detail' => 'Link to Detail Report'); @@ -152,8 +152,8 @@ class CRM_Report_Form_Contact_Summary extends CRM_Report_Form { 'fields' => array( 'phone' => NULL, 'phone_ext' => array( - 'title' => ts('Phone Extension') - ) + 'title' => ts('Phone Extension'), + ), ), 'grouping' => 'contact-fields', ), diff --git a/CRM/Report/Form/Contribute/Bookkeeping.php b/CRM/Report/Form/Contribute/Bookkeeping.php index 58f2b07e58..50b3d81555 100644 --- a/CRM/Report/Form/Contribute/Bookkeeping.php +++ b/CRM/Report/Form/Contribute/Bookkeeping.php @@ -41,7 +41,7 @@ class CRM_Report_Form_Contribute_Bookkeeping extends CRM_Report_Form { protected $_summary = NULL; protected $_customGroupExtends = array( - 'Membership' + 'Membership', ); /** @@ -176,7 +176,7 @@ class CRM_Report_Form_Contribute_Bookkeeping extends CRM_Report_Form { 'dao' => 'CRM_Contribute_DAO_Contribution', 'fields' => array( 'receive_date' => array( - 'default' => TRUE + 'default' => TRUE, ), 'invoice_id' => array( 'title' => ts('Invoice ID'), diff --git a/CRM/Report/Form/Contribute/Detail.php b/CRM/Report/Form/Contribute/Detail.php index d737bd8198..951fcad46c 100644 --- a/CRM/Report/Form/Contribute/Detail.php +++ b/CRM/Report/Form/Contribute/Detail.php @@ -101,7 +101,7 @@ class CRM_Report_Form_Contribute_Detail extends CRM_Report_Form { 'title' => ts('Last Name, First Name'), 'default' => '1', 'default_weight' => '0', - 'default_order' => 'ASC' + 'default_order' => 'ASC', ), ), 'grouping' => 'contact-fields', @@ -174,15 +174,15 @@ class CRM_Report_Form_Contribute_Detail extends CRM_Report_Form { 'net_amount' => NULL, 'contribution_or_soft' => array( 'title' => ts('Contribution OR Soft Credit?'), - 'dbAlias' => "'Contribution'" + 'dbAlias' => "'Contribution'", ), 'soft_credits' => array( 'title' => ts('Soft Credits'), - 'dbAlias' => "NULL" + 'dbAlias' => "NULL", ), 'soft_credit_for' => array( 'title' => ts('Soft Credit For'), - 'dbAlias' => "NULL" + 'dbAlias' => "NULL", ), ), 'filters' => array( @@ -898,7 +898,7 @@ WHERE civicrm_contribution_contribution_id={$row['civicrm_contribution_contribu foreach ($totals as $key => $total) { $totalandsum[$key] = ts($title, array( 1 => $total, - 2 => CRM_Utils_Money::format($sumcontribs[$key]) + 2 => CRM_Utils_Money::format($sumcontribs[$key]), )); } $this->assign('sectionTotals', $totalandsum); diff --git a/CRM/Report/Form/Contribute/History.php b/CRM/Report/Form/Contribute/History.php index d86105ebcb..2a71bf5b27 100644 --- a/CRM/Report/Form/Contribute/History.php +++ b/CRM/Report/Form/Contribute/History.php @@ -723,7 +723,7 @@ class CRM_Report_Form_Contribute_History extends CRM_Report_Form { if ($fieldName == 'this_year' || $fieldName == 'other_year') { return array( 'calendar' => ts('Is Calendar Year'), - 'fiscal' => ts('Fiscal Year Starting') + 'fiscal' => ts('Fiscal Year Starting'), ); } return parent::getOperationPair($type, $fieldName); diff --git a/CRM/Report/Form/Contribute/HouseholdSummary.php b/CRM/Report/Form/Contribute/HouseholdSummary.php index 1c63b59671..8182c8a4ee 100644 --- a/CRM/Report/Form/Contribute/HouseholdSummary.php +++ b/CRM/Report/Form/Contribute/HouseholdSummary.php @@ -179,7 +179,7 @@ class CRM_Report_Form_Contribute_HouseholdSummary extends CRM_Report_Form { 'civicrm_email' => array( 'dao' => 'CRM_Core_DAO_Email', 'fields' => array( - 'email' => NULL + 'email' => NULL, ), 'grouping' => 'contact-fields', ), @@ -353,7 +353,7 @@ class CRM_Report_Form_Contribute_HouseholdSummary extends CRM_Report_Form { $this->beginPostProcess(); $this->buildACLClause(array( $this->_aliases['civicrm_contact'], - $this->_aliases['civicrm_contact_household'] + $this->_aliases['civicrm_contact_household'], )); $sql = $this->buildQuery(TRUE); $rows = array(); diff --git a/CRM/Report/Form/Contribute/Lybunt.php b/CRM/Report/Form/Contribute/Lybunt.php index 466e7d741d..73ff1e4a90 100644 --- a/CRM/Report/Form/Contribute/Lybunt.php +++ b/CRM/Report/Form/Contribute/Lybunt.php @@ -512,7 +512,7 @@ class CRM_Report_Form_Contribute_Lybunt extends CRM_Report_Form { if ($fieldName == 'yid') { return array( 'calendar' => ts('Is Calendar Year'), - 'fiscal' => ts('Fiscal Year Starting') + 'fiscal' => ts('Fiscal Year Starting'), ); } return parent::getOperationPair($type, $fieldName); diff --git a/CRM/Report/Form/Contribute/PCP.php b/CRM/Report/Form/Contribute/PCP.php index 695156785b..874ace7308 100644 --- a/CRM/Report/Form/Contribute/PCP.php +++ b/CRM/Report/Form/Contribute/PCP.php @@ -278,22 +278,22 @@ LEFT JOIN civicrm_contribution_page {$this->_aliases['civicrm_contribution_page' $statistics['counts']['goal_total'] = array( 'title' => ts('Goal Total'), 'value' => $dao->goal_total, - 'type' => CRM_Utils_Type::T_MONEY + 'type' => CRM_Utils_Type::T_MONEY, ); $statistics['counts']['committed_total'] = array( 'title' => ts('Total Committed'), 'value' => $dao->committed_total, - 'type' => CRM_Utils_Type::T_MONEY + 'type' => CRM_Utils_Type::T_MONEY, ); $statistics['counts']['received_total'] = array( 'title' => ts('Total Received'), 'value' => $dao->received_total, - 'type' => CRM_Utils_Type::T_MONEY + 'type' => CRM_Utils_Type::T_MONEY, ); $statistics['counts']['donors_total'] = array( 'title' => ts('Total Donors'), 'value' => $dao->donors_total, - 'type' => CRM_Utils_Type::T_INT + 'type' => CRM_Utils_Type::T_INT, ); return $statistics; } diff --git a/CRM/Report/Form/Contribute/Recur.php b/CRM/Report/Form/Contribute/Recur.php index bad820c4e7..d7521b31f2 100644 --- a/CRM/Report/Form/Contribute/Recur.php +++ b/CRM/Report/Form/Contribute/Recur.php @@ -85,7 +85,7 @@ class CRM_Report_Form_Contribute_Recur extends CRM_Report_Form { 'total_amount' => array( 'title' => ts('Amount Contributed to Date'), 'statistics' => array( - 'sum' => ts("Total Amount Contributed") + 'sum' => ts("Total Amount Contributed"), ), ), ), @@ -200,10 +200,10 @@ class CRM_Report_Form_Contribute_Recur extends CRM_Report_Form { 'title' => ts('Calculated end date (either end date or date all installments will be made)'), 'description' => "does this work?", 'operatorType' => CRM_Report_Form::OP_DATE, - 'pseudofield' => TRUE + 'pseudofield' => TRUE, ), ), - ) + ), ); $this->_currencyColumn = 'civicrm_contribution_recur_currency'; parent::__construct(); diff --git a/CRM/Report/Form/Contribute/Repeat.php b/CRM/Report/Form/Contribute/Repeat.php index 51b76f4d99..9ad338b290 100644 --- a/CRM/Report/Form/Contribute/Repeat.php +++ b/CRM/Report/Form/Contribute/Repeat.php @@ -503,7 +503,7 @@ LEFT JOIN civicrm_temp_civireport_repeat2 {$this->_aliases['civicrm_contribution $erorrGrps = implode(',', $invlidGroups); $tempErrors[] = ts("Do not select field %1 with Group by %2.", array( 1 => $idMapping[$fld_id], - 2 => $erorrGrps + 2 => $erorrGrps, )); } } @@ -623,7 +623,7 @@ LEFT JOIN civicrm_temp_civireport_repeat2 $contact_sums[$dao->contact_id] = array( 'contribution1_total_amount_sum' => $dao->contribution1_total_amount_sum, - 'contribution2_total_amount_sum' => $dao->contribution2_total_amount_sum + 'contribution2_total_amount_sum' => $dao->contribution2_total_amount_sum, ); } diff --git a/CRM/Report/Form/Contribute/SoftCredit.php b/CRM/Report/Form/Contribute/SoftCredit.php index d5d610cfda..8d095dee6b 100644 --- a/CRM/Report/Form/Contribute/SoftCredit.php +++ b/CRM/Report/Form/Contribute/SoftCredit.php @@ -103,7 +103,7 @@ class CRM_Report_Form_Contribute_SoftCredit extends CRM_Report_Form { 'filters' => array( 'sort_name' => array( 'name' => 'sort_name', - 'title' => ts('Soft Credit Name') + 'title' => ts('Soft Credit Name'), ), ), 'grouping' => 'contact-fields', @@ -152,7 +152,7 @@ class CRM_Report_Form_Contribute_SoftCredit extends CRM_Report_Form { 'name' => 'id', 'title' => ts('Financial Type'), 'operatorType' => CRM_Report_Form::OP_MULTISELECT, - 'options' => CRM_Contribute_PseudoConstant::financialType() + 'options' => CRM_Contribute_PseudoConstant::financialType(), ), ), 'grouping' => 'softcredit-fields', diff --git a/CRM/Report/Form/Contribute/Summary.php b/CRM/Report/Form/Contribute/Summary.php index c0f5162356..4c0c174276 100644 --- a/CRM/Report/Form/Contribute/Summary.php +++ b/CRM/Report/Form/Contribute/Summary.php @@ -408,7 +408,7 @@ class CRM_Report_Form_Contribute_Summary extends CRM_Report_Form { foreach (array( 'total_count_value', 'total_sum_value', - 'total_avg_value' + 'total_avg_value', ) as $val) { if (!empty($fields[$val])) { $errors[$val] = ts("Please select the Amount Statistics"); diff --git a/CRM/Report/Form/Contribute/Sybunt.php b/CRM/Report/Form/Contribute/Sybunt.php index d166b6c2e2..ff87350f92 100644 --- a/CRM/Report/Form/Contribute/Sybunt.php +++ b/CRM/Report/Form/Contribute/Sybunt.php @@ -528,7 +528,7 @@ class CRM_Report_Form_Contribute_Sybunt extends CRM_Report_Form { if ($fieldName == 'yid') { return array( 'calendar' => ts('Is Calendar Year'), - 'fiscal' => ts('Fiscal Year Starting') + 'fiscal' => ts('Fiscal Year Starting'), ); } return parent::getOperationPair($type, $fieldName); diff --git a/CRM/Report/Form/Contribute/TopDonor.php b/CRM/Report/Form/Contribute/TopDonor.php index 79abd52203..b2af1b5e96 100644 --- a/CRM/Report/Form/Contribute/TopDonor.php +++ b/CRM/Report/Form/Contribute/TopDonor.php @@ -234,7 +234,7 @@ class CRM_Report_Form_Contribute_TopDonor extends CRM_Report_Form { if (!in_array($op, array( 'eq', - 'lte' + 'lte', )) ) { $errors['total_range_op'] = ts("Please select 'Is equal to' OR 'Is Less than or equal to' operator"); diff --git a/CRM/Report/Form/Event/IncomeCountSummary.php b/CRM/Report/Form/Event/IncomeCountSummary.php index 6bf2ebdecf..046945d952 100644 --- a/CRM/Report/Form/Event/IncomeCountSummary.php +++ b/CRM/Report/Form/Event/IncomeCountSummary.php @@ -45,7 +45,7 @@ class CRM_Report_Form_Event_IncomeCountSummary extends CRM_Report_Form_Event { protected $_add2groupSupported = FALSE; protected $_customGroupExtends = array( - 'Event' + 'Event', ); public $_drilldownReport = array('event/participantlist' => 'Link to Detail Report'); @@ -75,7 +75,7 @@ class CRM_Report_Form_Event_IncomeCountSummary extends CRM_Report_Form_Event { 'title' => ts('Event Type'), ), 'fee_label' => array( - 'title' => ts('Fee Label') + 'title' => ts('Fee Label'), ), 'event_start_date' => array( 'title' => ts('Event Start Date'), diff --git a/CRM/Report/Form/Event/ParticipantListCount.php b/CRM/Report/Form/Event/ParticipantListCount.php index 761d123b80..c8e3453640 100644 --- a/CRM/Report/Form/Event/ParticipantListCount.php +++ b/CRM/Report/Form/Event/ParticipantListCount.php @@ -163,7 +163,7 @@ class CRM_Report_Form_Event_ParticipantListCount extends CRM_Report_Form_Event { 'type' => CRM_Utils_Type::T_INT, 'attributes' => array( 'entity' => 'event', - 'select' => array('minimumInputLength' => 0) + 'select' => array('minimumInputLength' => 0), ), ), 'sid' => array( diff --git a/CRM/Report/Form/Event/ParticipantListing.php b/CRM/Report/Form/Event/ParticipantListing.php index 5d86efb0ea..6f4af5d2e6 100644 --- a/CRM/Report/Form/Event/ParticipantListing.php +++ b/CRM/Report/Form/Event/ParticipantListing.php @@ -47,7 +47,7 @@ class CRM_Report_Form_Event_ParticipantListing extends CRM_Report_Form_Event { 'Participant', 'Contact', 'Individual', - 'Event' + 'Event', ); public $_drilldownReport = array('event/income' => 'Link to Detail Report'); @@ -142,7 +142,7 @@ class CRM_Report_Form_Event_ParticipantListing extends CRM_Report_Form_Event { 'birth_date' => array( 'title' => 'Birth Date', 'operatorType' => CRM_Report_Form::OP_DATE, - 'type' => CRM_Utils_Type::T_DATE + 'type' => CRM_Utils_Type::T_DATE, ), ), ), @@ -215,7 +215,7 @@ class CRM_Report_Form_Event_ParticipantListing extends CRM_Report_Form_Event { 'type' => CRM_Utils_Type::T_INT, 'attributes' => array( 'entity' => 'event', - 'select' => array('minimumInputLength' => 0) + 'select' => array('minimumInputLength' => 0), ), ), 'sid' => array( @@ -252,7 +252,7 @@ class CRM_Report_Form_Event_ParticipantListing extends CRM_Report_Form_Event { 'event_id' => array( 'title' => ts('Event'), 'default_weight' => '1', - 'default_order' => 'ASC' + 'default_order' => 'ASC', ), ), ), @@ -290,7 +290,7 @@ class CRM_Report_Form_Event_ParticipantListing extends CRM_Report_Form_Event { 'event_type_id' => array( 'title' => ts('Event Type'), 'default_weight' => '2', - 'default_order' => 'ASC' + 'default_order' => 'ASC', ), ), ), @@ -314,11 +314,11 @@ class CRM_Report_Form_Event_ParticipantListing extends CRM_Report_Form_Event { ), 'currency' => array( 'required' => TRUE, - 'no_display' => TRUE + 'no_display' => TRUE, ), 'trxn_id' => NULL, 'fee_amount' => array('title' => ts('Transaction Fee')), - 'net_amount' => NULL + 'net_amount' => NULL, ), 'grouping' => 'contrib-fields', 'filters' => array( @@ -347,7 +347,7 @@ class CRM_Report_Form_Event_ParticipantListing extends CRM_Report_Form_Event { 'title' => ts('Contribution Status'), 'operatorType' => CRM_Report_Form::OP_MULTISELECT, 'options' => CRM_Contribute_PseudoConstant::contributionStatus(), - 'default' => NULL + 'default' => NULL, ), ), ), diff --git a/CRM/Report/Form/Event/Summary.php b/CRM/Report/Form/Event/Summary.php index b15bc97ec4..c5a058e1ee 100644 --- a/CRM/Report/Form/Event/Summary.php +++ b/CRM/Report/Form/Event/Summary.php @@ -46,7 +46,7 @@ class CRM_Report_Form_Event_Summary extends CRM_Report_Form_Event { protected $_add2groupSupported = FALSE; protected $_customGroupExtends = array( - 'Event' + 'Event', ); public $_drilldownReport = array('event/income' => 'Link to Detail Report'); diff --git a/CRM/Report/Form/Extended.php b/CRM/Report/Form/Extended.php index 5b865fe85e..18578f611b 100644 --- a/CRM/Report/Form/Extended.php +++ b/CRM/Report/Form/Extended.php @@ -358,7 +358,7 @@ class CRM_Report_Form_Extended extends CRM_Report_Form { 'event_id' => array( 'title' => ts('Event'), 'default_weight' => '1', - 'default_order' => 'ASC' + 'default_order' => 'ASC', ), ), 'group_bys' => array( @@ -623,41 +623,41 @@ class CRM_Report_Form_Extended extends CRM_Report_Form { 'fields' => array( 'id' => array( 'title' => ts('Case ID'), - 'required' => FALSE + 'required' => FALSE, ), 'subject' => array( 'title' => ts('Case Subject'), - 'default' => TRUE + 'default' => TRUE, ), 'status_id' => array( 'title' => ts('Status'), - 'default' => TRUE + 'default' => TRUE, ), 'case_type_id' => array( 'title' => ts('Case Type'), - 'default' => TRUE + 'default' => TRUE, ), 'case_start_date' => array( 'title' => ts('Case Start Date'), 'name' => 'start_date', - 'default' => TRUE + 'default' => TRUE, ), 'case_end_date' => array( 'title' => ts('Case End Date'), 'name' => 'end_date', - 'default' => TRUE + 'default' => TRUE, ), 'case_duration' => array( 'name' => 'duration', 'title' => ts('Duration (Days)'), - 'default' => FALSE + 'default' => FALSE, ), 'case_is_deleted' => array( 'name' => 'is_deleted', 'title' => ts('Case Deleted?'), 'default' => FALSE, - 'type' => CRM_Utils_Type::T_INT - ) + 'type' => CRM_Utils_Type::T_INT, + ), ), 'filters' => array( 'case_start_date' => array( @@ -670,18 +670,18 @@ class CRM_Report_Form_Extended extends CRM_Report_Form { 'title' => ts('Case End Date'), 'operatorType' => CRM_Report_Form::OP_DATE, 'type' => CRM_Utils_Type::T_DATE, - 'name' => 'end_date' + 'name' => 'end_date', ), 'case_type_id' => array( 'title' => ts('Case Type'), 'operatorType' => CRM_Report_Form::OP_MULTISELECT, - 'options' => $this->case_types + 'options' => $this->case_types, ), 'case_status_id' => array( 'title' => ts('Case Status'), 'operatorType' => CRM_Report_Form::OP_MULTISELECT, 'options' => $this->case_statuses, - 'name' => 'status_id' + 'name' => 'status_id', ), 'case_is_deleted' => array( 'title' => ts('Case Deleted?'), @@ -689,10 +689,10 @@ class CRM_Report_Form_Extended extends CRM_Report_Form { 'operatorType' => CRM_Report_Form::OP_SELECT, 'options' => $this->deleted_labels, 'default' => 0, - 'name' => 'is_deleted' - ) - ) - ) + 'name' => 'is_deleted', + ), + ), + ), ); } @@ -730,7 +730,7 @@ class CRM_Report_Form_Extended extends CRM_Report_Form { 'order_by' => TRUE, 'filters' => TRUE, 'defaults' => array( - 'country_id' => TRUE + 'country_id' => TRUE, ), ); diff --git a/CRM/Report/Form/Grant/Detail.php b/CRM/Report/Form/Grant/Detail.php index 832ad76d4c..d09f93bfe2 100644 --- a/CRM/Report/Form/Grant/Detail.php +++ b/CRM/Report/Form/Grant/Detail.php @@ -38,7 +38,7 @@ class CRM_Report_Form_Grant_Detail extends CRM_Report_Form { protected $_addressField = FALSE; protected $_customGroupExtends = array( - 'Grant' + 'Grant', ); /** diff --git a/CRM/Report/Form/Grant/Statistics.php b/CRM/Report/Form/Grant/Statistics.php index 700c782ce1..9b7bca5704 100644 --- a/CRM/Report/Form/Grant/Statistics.php +++ b/CRM/Report/Form/Grant/Statistics.php @@ -215,7 +215,7 @@ class CRM_Report_Form_Grant_Statistics extends CRM_Report_Form { foreach ($this->_columns as $tableName => $table) { if (in_array($tableName, array( 'civicrm_address', - 'civicrm_world_region' + 'civicrm_world_region', ))) { $this->_addressField = TRUE; } diff --git a/CRM/Report/Form/Instance.php b/CRM/Report/Form/Instance.php index 0e47961d23..974413e0bd 100644 --- a/CRM/Report/Form/Instance.php +++ b/CRM/Report/Form/Instance.php @@ -89,7 +89,7 @@ class CRM_Report_Form_Instance { ts('Limit Dashboard Results'), array( 'maxlength' => 64, - 'size' => 5 + 'size' => 5, ) ); diff --git a/CRM/Report/Form/Mailing/Bounce.php b/CRM/Report/Form/Mailing/Bounce.php index dde606de27..533121d3bd 100644 --- a/CRM/Report/Form/Mailing/Bounce.php +++ b/CRM/Report/Form/Mailing/Bounce.php @@ -48,7 +48,7 @@ class CRM_Report_Form_Mailing_Bounce extends CRM_Report_Form { 'Contact', 'Individual', 'Household', - 'Organization' + 'Organization', ); protected $_charts = array( @@ -95,7 +95,7 @@ class CRM_Report_Form_Mailing_Bounce extends CRM_Report_Form { 'sort_name' => array( 'title' => ts('Contact Name'), 'default' => TRUE, - 'default_order' => 'ASC' + 'default_order' => 'ASC', ), ), 'grouping' => 'contact-fields', diff --git a/CRM/Report/Form/Mailing/Clicks.php b/CRM/Report/Form/Mailing/Clicks.php index 6dc6696671..15dbd9c735 100644 --- a/CRM/Report/Form/Mailing/Clicks.php +++ b/CRM/Report/Form/Mailing/Clicks.php @@ -45,7 +45,7 @@ class CRM_Report_Form_Mailing_Clicks extends CRM_Report_Form { 'Contact', 'Individual', 'Household', - 'Organization' + 'Organization', ); protected $_charts = array( @@ -92,7 +92,7 @@ class CRM_Report_Form_Mailing_Clicks extends CRM_Report_Form { 'sort_name' => array( 'title' => ts('Contact Name'), 'default' => TRUE, - 'default_order' => 'ASC' + 'default_order' => 'ASC', ), ), 'grouping' => 'contact-fields', diff --git a/CRM/Report/Form/Mailing/Detail.php b/CRM/Report/Form/Mailing/Detail.php index 3b0090983c..8d0ffd2c1e 100644 --- a/CRM/Report/Form/Mailing/Detail.php +++ b/CRM/Report/Form/Mailing/Detail.php @@ -160,7 +160,7 @@ class CRM_Report_Form_Mailing_Detail extends CRM_Report_Form { 'options' => array( '' => ts('Any'), '0' => ts('No'), - '1' => ts('Yes') + '1' => ts('Yes'), ), 'clause' => 'mailing_event_unsubscribe_civireport.id IS NULL', ), @@ -171,7 +171,7 @@ class CRM_Report_Form_Mailing_Detail extends CRM_Report_Form { 'options' => array( '' => ts('Any'), '0' => ts('No'), - '1' => ts('Yes') + '1' => ts('Yes'), ), 'clause' => 'mailing_event_unsubscribe_civireport2.id IS NULL', ), @@ -196,7 +196,7 @@ class CRM_Report_Form_Mailing_Detail extends CRM_Report_Form { 'options' => array( '' => ts('Any'), '0' => ts('No'), - '1' => ts('Yes') + '1' => ts('Yes'), ), 'clause' => 'mailing_event_reply_civireport.id IS NULL', ), @@ -221,7 +221,7 @@ class CRM_Report_Form_Mailing_Detail extends CRM_Report_Form { 'options' => array( '' => ts('Any'), '0' => ts('No'), - '1' => ts('Yes') + '1' => ts('Yes'), ), 'clause' => 'mailing_event_forward_civireport.id IS NULL', ), @@ -264,7 +264,7 @@ class CRM_Report_Form_Mailing_Detail extends CRM_Report_Form { 'unsubscribe_id', 'optout_id', 'forward_id', - 'reply_id' + 'reply_id', ))) { $select[] = "IF({$field['dbAlias']} IS NULL, 'No', 'Yes') as {$tableName}_{$fieldName}"; $this->_columnHeaders["{$tableName}_{$fieldName}"]['type'] = CRM_Utils_Array::value('type', $field); diff --git a/CRM/Report/Form/Mailing/Opened.php b/CRM/Report/Form/Mailing/Opened.php index c866b84205..152387f2fe 100644 --- a/CRM/Report/Form/Mailing/Opened.php +++ b/CRM/Report/Form/Mailing/Opened.php @@ -45,7 +45,7 @@ class CRM_Report_Form_Mailing_Opened extends CRM_Report_Form { 'Contact', 'Individual', 'Household', - 'Organization' + 'Organization', ); protected $_charts = array( @@ -92,7 +92,7 @@ class CRM_Report_Form_Mailing_Opened extends CRM_Report_Form { 'sort_name' => array( 'title' => ts('Contact Name'), 'default' => TRUE, - 'default_order' => 'ASC' + 'default_order' => 'ASC', ), ), 'grouping' => 'contact-fields', diff --git a/CRM/Report/Form/Member/ContributionDetail.php b/CRM/Report/Form/Member/ContributionDetail.php index b9e34aac17..e99cb59c3c 100644 --- a/CRM/Report/Form/Member/ContributionDetail.php +++ b/CRM/Report/Form/Member/ContributionDetail.php @@ -43,7 +43,7 @@ class CRM_Report_Form_Member_ContributionDetail extends CRM_Report_Form { protected $_customGroupExtends = array( 'Contribution', - 'Membership' + 'Membership', ); /** diff --git a/CRM/Report/Form/Member/Detail.php b/CRM/Report/Form/Member/Detail.php index 952f5cb1a8..92122e0f2e 100644 --- a/CRM/Report/Form/Member/Detail.php +++ b/CRM/Report/Form/Member/Detail.php @@ -111,7 +111,7 @@ class CRM_Report_Form_Member_Detail extends CRM_Report_Form { 'title' => ts('Last Name, First Name'), 'default' => '1', 'default_weight' => '0', - 'default_order' => 'ASC' + 'default_order' => 'ASC', ), ), 'grouping' => 'contact-fields', diff --git a/CRM/Report/Form/Member/Lapse.php b/CRM/Report/Form/Member/Lapse.php index 371d4cbbb6..eee3cc3a5d 100644 --- a/CRM/Report/Form/Member/Lapse.php +++ b/CRM/Report/Form/Member/Lapse.php @@ -40,7 +40,7 @@ class CRM_Report_Form_Member_Lapse extends CRM_Report_Form { protected $_phoneField = FALSE; protected $_charts = array('' => 'Tabular'); protected $_customGroupExtends = array( - 'Membership' + 'Membership', ); public $_drilldownReport = array('member/detail' => 'Link to Detail Report'); diff --git a/CRM/Report/Form/Membership/Summary.php b/CRM/Report/Form/Membership/Summary.php index 2163a08fed..599382f036 100644 --- a/CRM/Report/Form/Membership/Summary.php +++ b/CRM/Report/Form/Membership/Summary.php @@ -354,7 +354,7 @@ LEFT JOIN civicrm_contribution {$this->_aliases['civicrm_contribution']} foreach (array( 'receive_date', $this->_interval, - 'value' + 'value', ) as $ignore) { unset($graphRows[$ignore][$count - 1]); } diff --git a/CRM/Report/Form/Pledge/Detail.php b/CRM/Report/Form/Pledge/Detail.php index 4711c56a72..68f3e524c7 100644 --- a/CRM/Report/Form/Pledge/Detail.php +++ b/CRM/Report/Form/Pledge/Detail.php @@ -50,7 +50,7 @@ class CRM_Report_Form_Pledge_Detail extends CRM_Report_Form { protected $_pledgeStatuses = array(); protected $_customGroupExtends = array( 'Pledge', - 'Individual' + 'Individual', ); /** @@ -223,7 +223,7 @@ class CRM_Report_Form_Pledge_Detail extends CRM_Report_Form { $this->_totalPaid = TRUE; // add pledge_payment join $this->_columnHeaders["{$tableName}_{$fieldName}"] = array( 'title' => $field['title'], - 'type' => $field['type'] + 'type' => $field['type'], ); return "COALESCE(sum({$this->_aliases[$tableName]}.actual_amount), 0) as {$tableName}_{$fieldName}"; } @@ -234,7 +234,7 @@ class CRM_Report_Form_Pledge_Detail extends CRM_Report_Form { $this->_columnHeaders["{$tableName}_{$fieldName}"] = $field['title']; $this->_columnHeaders["{$tableName}_{$fieldName}"] = array( 'title' => $field['title'], - 'type' => $field['type'] + 'type' => $field['type'], ); return "IF({$this->_aliases['civicrm_pledge']}.status_id IN({$cancelledStatus}, $completedStatus), 0, COALESCE({$this->_aliases['civicrm_pledge']}.amount, 0) - COALESCE(sum({$this->_aliases[$tableName]}.actual_amount),0)) as {$tableName}_{$fieldName}"; } @@ -436,7 +436,7 @@ class CRM_Report_Form_Pledge_Detail extends CRM_Report_Form { */ $tableHeaders = array( 'civicrm_pledge_payment_total_paid', - 'civicrm_pledge_payment_balance_due' + 'civicrm_pledge_payment_balance_due', ); foreach ($tableHeaders as $header) { diff --git a/CRM/Report/Form/Pledge/Pbnp.php b/CRM/Report/Form/Pledge/Pbnp.php index a59a6774f3..7771143722 100644 --- a/CRM/Report/Form/Pledge/Pbnp.php +++ b/CRM/Report/Form/Pledge/Pbnp.php @@ -41,7 +41,7 @@ class CRM_Report_Form_Pledge_Pbnp extends CRM_Report_Form { public $_drilldownReport = array('pledge/summary' => 'Link to Detail Report'); protected $_customGroupExtends = array( - 'Pledge' + 'Pledge', ); /** @@ -233,7 +233,7 @@ class CRM_Report_Form_Pledge_Pbnp extends CRM_Report_Form { foreach (array( 'Pending', 'In Progress', - 'Overdue' + 'Overdue', ) as $statusKey) { if ($key = CRM_Utils_Array::key($statusKey, $allStatus)) { $unpaidStatus[] = $key; diff --git a/CRM/Report/Form/Walklist/Walklist.php b/CRM/Report/Form/Walklist/Walklist.php index 839b9e33c9..1164f84613 100644 --- a/CRM/Report/Form/Walklist/Walklist.php +++ b/CRM/Report/Form/Walklist/Walklist.php @@ -48,7 +48,7 @@ class CRM_Report_Form_Walklist_Walklist extends CRM_Report_Form { 'Contact', 'Individual', 'Household', - 'Organization' + 'Organization', ); /** @@ -84,7 +84,7 @@ class CRM_Report_Form_Walklist_Walklist extends CRM_Report_Form { 'sort_name' => array( 'title' => ts('Contact Name'), 'required' => TRUE, - ) + ), ), ), 'civicrm_address' => array( diff --git a/CRM/Report/Utils/Report.php b/CRM/Report/Utils/Report.php index f32b631a9a..9009f4fab7 100644 --- a/CRM/Report/Utils/Report.php +++ b/CRM/Report/Utils/Report.php @@ -434,7 +434,7 @@ WHERE inst.report_id = %1"; 'default' => 'null', ), ), - 'ignoreKey' => TRUE + 'ignoreKey' => TRUE, ); $messages[] = $wrapper->run($templateInfo['name'], NULL, $arguments); } diff --git a/CRM/SMS/Provider.php b/CRM/SMS/Provider.php index c6f6e5c89c..274bff6f70 100644 --- a/CRM/SMS/Provider.php +++ b/CRM/SMS/Provider.php @@ -213,13 +213,13 @@ INNER JOIN civicrm_mailing_job mj ON mj.mailing_id = m.id AND mj.id = %1"; 'email' => array( 1 => array( 'location_type_id' => $phoneloc, - 'email' => $stripFrom . '@mobile.sms' + 'email' => $stripFrom . '@mobile.sms', )), 'phone' => array( 1 => array( 'phone_type_id' => $phonetype, 'location_type_id' => $phoneloc, - 'phone' => $stripFrom + 'phone' => $stripFrom, )), ); $fromContact = CRM_Contact_BAO_Contact::create($contactparams, FALSE, TRUE, FALSE); @@ -246,7 +246,7 @@ INNER JOIN civicrm_mailing_job mj ON mj.mailing_id = m.id AND mj.id = %1"; 'activity_date_time' => date('YmdHis'), 'status_id' => $actStatusIDs['Completed'], 'details' => $body, - 'phone_number' => $from + 'phone_number' => $from, ); if ($trackID) { $trackID = CRM_Utils_Type::escape($trackID, 'String'); diff --git a/CRM/UF/Form/Preview.php b/CRM/UF/Form/Preview.php index 489b49645c..cc6105482d 100644 --- a/CRM/UF/Form/Preview.php +++ b/CRM/UF/Form/Preview.php @@ -91,7 +91,7 @@ class CRM_UF_Form_Preview extends CRM_UF_Form_AbstractPreview { 'county', 'phone', 'email', - 'im' + 'im', ); if ($fieldDAO->location_type_id) { diff --git a/CRM/Upgrade/Form.php b/CRM/Upgrade/Form.php index 78bb47fa42..2aa3dc1ffa 100644 --- a/CRM/Upgrade/Form.php +++ b/CRM/Upgrade/Form.php @@ -501,7 +501,7 @@ SET version = '$version' array( 1 => $minPhpVersion, 2 => $phpVersion, - 3 => $latestVer + 3 => $latestVer, )); } @@ -514,7 +514,7 @@ SET version = '$version' if (CRM_Core_DAO::getGlobalSetting('thread_stack', 0) < (1024 * self::MINIMUM_THREAD_STACK)) { $error = ts('CiviCRM %1 requires MySQL thread stack >= %2k', array( 1 => $latestVer, - 2 => self::MINIMUM_THREAD_STACK + 2 => self::MINIMUM_THREAD_STACK, )); } diff --git a/CRM/Upgrade/Incremental/Legacy.php b/CRM/Upgrade/Incremental/Legacy.php index 87ca1f4c13..7743a01e00 100644 --- a/CRM/Upgrade/Incremental/Legacy.php +++ b/CRM/Upgrade/Incremental/Legacy.php @@ -103,12 +103,12 @@ SELECT id if (file_exists($ofcFile)) { if (@unlink($ofcFile)) { $preUpgradeMessage .= '
' . ts('This system included an outdated, insecure script (%1). The file was automatically deleted.', array( - 1 => $ofcFile + 1 => $ofcFile, )); } else { $preUpgradeMessage .= '
' . ts('This system includes an outdated, insecure script (%1). Please delete it.', array( - 1 => $ofcFile + 1 => $ofcFile, )); } } diff --git a/CRM/Upgrade/Incremental/php/FourFour.php b/CRM/Upgrade/Incremental/php/FourFour.php index 3fff837096..16b80da6e5 100644 --- a/CRM/Upgrade/Incremental/php/FourFour.php +++ b/CRM/Upgrade/Incremental/php/FourFour.php @@ -69,7 +69,7 @@ class CRM_Upgrade_Incremental_php_FourFour { } if ($oversizedEntries > 0) { $preUpgradeMessage .= '
' . ts("WARNING: There are %1 word-replacement entries which will not be valid in v4.4+ (eg with over 255 characters). They will be dropped during upgrade. For details, consult the CiviCRM log.", array( - 1 => $oversizedEntries + 1 => $oversizedEntries, )); } } diff --git a/CRM/Upgrade/Incremental/php/FourThree.php b/CRM/Upgrade/Incremental/php/FourThree.php index 39e046d4f5..f6cc5ef714 100644 --- a/CRM/Upgrade/Incremental/php/FourThree.php +++ b/CRM/Upgrade/Incremental/php/FourThree.php @@ -516,7 +516,7 @@ AND ceft.entity_table = 'civicrm_contribution' $queryParams = array( 1 => array($completedStatus, 'Integer'), 2 => array($pendingStatus, 'Integer'), - 3 => array($cancelledStatus, 'Integer') + 3 => array($cancelledStatus, 'Integer'), ); $accountType = key(CRM_Core_PseudoConstant::accountOptionValues('financial_account_type', NULL, " AND v.name = 'Asset' ")); @@ -872,7 +872,7 @@ WHERE cc.contact_type = 'Organization' AND cc.organization_name = %1 'display_name' => $dao->name, 'legal_name' => $dao->name, 'organization_name' => $dao->name, - 'contact_type' => 'Organization' + 'contact_type' => 'Organization', ); $contact = CRM_Contact_BAO_Contact::add($params); $contactID = $contact->id; diff --git a/CRM/Upgrade/Incremental/php/FourTwo.php b/CRM/Upgrade/Incremental/php/FourTwo.php index 2eb0e4b6aa..7c9b4a33e4 100644 --- a/CRM/Upgrade/Incremental/php/FourTwo.php +++ b/CRM/Upgrade/Incremental/php/FourTwo.php @@ -108,7 +108,7 @@ ORDER BY mp.contribution_id, mp.membership_id"; // note: error conditions are also checked in upgrade_4_2_beta2() if (!defined('CIVICRM_SETTINGS_PATH')) { $preUpgradeMessage .= '
' . ts('Could not determine path to civicrm.settings.php. Please manually locate it and add these lines at the bottom:
%1
', array( - 1 => self::SETTINGS_SNIPPET + 1 => self::SETTINGS_SNIPPET, )); } elseif (preg_match(self::SETTINGS_SNIPPET_PATTERN, file_get_contents(CIVICRM_SETTINGS_PATH))) { @@ -117,7 +117,7 @@ ORDER BY mp.contribution_id, mp.membership_id"; elseif (!is_writable(CIVICRM_SETTINGS_PATH)) { $preUpgradeMessage .= '
' . ts('The settings file (%1) must be updated. Please make it writable or manually add these lines:
%2
', array( 1 => CIVICRM_SETTINGS_PATH, - 2 => self::SETTINGS_SNIPPET + 2 => self::SETTINGS_SNIPPET, )); } } @@ -160,7 +160,7 @@ INNER JOIN civicrm_price_set cps ON cps.id = cpf.price_set_id AND cps.name <>'de $config = CRM_Core_Config::singleton(); if (!empty($config->extensionsDir)) { $postUpgradeMessage .= '
' . ts('Please configure the Extension Resource URL.', array( - 1 => CRM_Utils_System::url('civicrm/admin/setting/url', 'reset=1') + 1 => CRM_Utils_System::url('civicrm/admin/setting/url', 'reset=1'), )); } } @@ -398,11 +398,11 @@ HAVING COUNT(cpse.price_set_id) > 1 AND MIN(cpse1.id) <> cpse.id "; $daoName = array( 'civicrm_contribution_page' => array( 'CRM_Contribute_BAO_ContributionPage', - CRM_Core_Component::getComponentID('CiviContribute') + CRM_Core_Component::getComponentID('CiviContribute'), ), 'civicrm_event' => array( 'CRM_Event_BAO_Event', - CRM_Core_Component::getComponentID('CiviEvent') + CRM_Core_Component::getComponentID('CiviEvent'), ), ); diff --git a/CRM/Utils/Geocode/Yahoo.php b/CRM/Utils/Geocode/Yahoo.php index 10d01f4c5c..4d0ad97ed5 100644 --- a/CRM/Utils/Geocode/Yahoo.php +++ b/CRM/Utils/Geocode/Yahoo.php @@ -174,7 +174,7 @@ class CRM_Utils_Geocode_Yahoo { if (CRM_Utils_System::isUserLoggedIn()) { $msg = ts('The Yahoo Geocoding system returned a different postal code (%1) than the one you entered (%2). If you want the Yahoo value, please delete the current postal code and save again.', array( 1 => $ret['postal'], - 2 => $current_pc_suffix ? "$current_pc-$current_pc_suffix" : $current_pc + 2 => $current_pc_suffix ? "$current_pc-$current_pc_suffix" : $current_pc, )); CRM_Core_Session::setStatus($msg, ts('Postal Code Mismatch'), 'error'); diff --git a/CRM/Utils/HttpClient.php b/CRM/Utils/HttpClient.php index 0e084fda3c..59c56eb810 100644 --- a/CRM/Utils/HttpClient.php +++ b/CRM/Utils/HttpClient.php @@ -195,7 +195,7 @@ class CRM_Utils_HttpClient { protected function createCurl($remoteFile) { require_once 'CA/Config/Curl.php'; $caConfig = CA_Config_Curl::probe(array( - 'verify_peer' => (bool) CRM_Core_BAO_Setting::getItem(CRM_Core_BAO_Setting::SYSTEM_PREFERENCES_NAME, 'verifySSL', NULL, TRUE) + 'verify_peer' => (bool) CRM_Core_BAO_Setting::getItem(CRM_Core_BAO_Setting::SYSTEM_PREFERENCES_NAME, 'verifySSL', NULL, TRUE), )); $ch = curl_init(); diff --git a/CRM/Utils/Migrate/Export.php b/CRM/Utils/Migrate/Export.php index a1886d3a5e..dbb1965dcc 100644 --- a/CRM/Utils/Migrate/Export.php +++ b/CRM/Utils/Migrate/Export.php @@ -75,7 +75,7 @@ class CRM_Utils_Migrate_Export { 'mappedFields' => array( array('optionGroup', 'option_group_id', 'option_group_name'), array('customGroup', 'custom_group_id', 'custom_group_name'), - ) + ), ), 'optionGroup' => array( 'data' => array(), @@ -127,7 +127,7 @@ class CRM_Utils_Migrate_Export { 'required' => FALSE, 'idNameMap' => array(), 'mappedFields' => array( - array('profileGroup', 'uf_group_id', 'profile_group_name') + array('profileGroup', 'uf_group_id', 'profile_group_name'), ), ), 'profileJoin' => array( @@ -137,7 +137,7 @@ class CRM_Utils_Migrate_Export { 'required' => FALSE, 'idNameMap' => array(), 'mappedFields' => array( - array('profileGroup', 'uf_group_id', 'profile_group_name') + array('profileGroup', 'uf_group_id', 'profile_group_name'), ), ), 'mappingGroup' => array( @@ -149,7 +149,7 @@ class CRM_Utils_Migrate_Export { 'idNameMap' => array(), 'mappedFields' => array( array('optionValue', 'mapping_type_id', 'mapping_type_name', 'mapping_type'), - ) + ), ), 'mappingField' => array( 'data' => array(), diff --git a/CRM/Utils/Migrate/ExportJSON.php b/CRM/Utils/Migrate/ExportJSON.php index ed286b59a5..8388c61e6f 100644 --- a/CRM/Utils/Migrate/ExportJSON.php +++ b/CRM/Utils/Migrate/ExportJSON.php @@ -470,7 +470,7 @@ WHERE ac.contact_id IN ( $ids ) 'id' => $dao->acID, 'contact_id' => $dao->contact_id, 'activity_id' => $dao->activity_id, - 'record_type_id' => $dao->record_type_id + 'record_type_id' => $dao->record_type_id, ); $this->appendValue($dao->acID, 'civicrm_activity_contact', $activityContacts); diff --git a/CRM/Utils/Migrate/Import.php b/CRM/Utils/Migrate/Import.php index f40e1cb54f..30ebc296b3 100644 --- a/CRM/Utils/Migrate/Import.php +++ b/CRM/Utils/Migrate/Import.php @@ -110,7 +110,7 @@ class CRM_Utils_Migrate_Import { array( 1 => $keyName, 2 => $dao->$keyName, - 3 => $dao->__table + 3 => $dao->__table, ) ), '', 'info'); return FALSE; @@ -283,7 +283,7 @@ AND v.name = %1 1 => array( (string ) $customGroupXML->extends_entity_column_value_option_group, 'String', - ) + ), ); $valueID = (int ) CRM_Core_DAO::singleValueQuery($sql, $params); if ($valueID) { @@ -447,7 +447,7 @@ AND f.column_name = %2 array( 1 => $profileField->field_name, 2 => $tableName, - 3 => $columnName + 3 => $columnName, ) ) . "
"); } diff --git a/CRM/Utils/Rule.php b/CRM/Utils/Rule.php index b17809a550..ec0591c31a 100644 --- a/CRM/Utils/Rule.php +++ b/CRM/Utils/Rule.php @@ -428,7 +428,7 @@ class CRM_Utils_Rule { 'CRM_Contribute_DAO_Contribution', 'currency', array( 'keyColumn' => 'name', - 'labelColumn' => 'symbol' + 'labelColumn' => 'symbol', )); $value = str_replace($currencySymbols, '', $value); diff --git a/api/v3/Attachment.php b/api/v3/Attachment.php index 2755a23cd8..4120bdf62d 100644 --- a/api/v3/Attachment.php +++ b/api/v3/Attachment.php @@ -147,7 +147,7 @@ function civicrm_api3_attachment_create($params) { } $result = array( - $fileDao->id => _civicrm_api3_attachment_format_result($fileDao, $entityFileDao, $returnContent, $isTrusted) + $fileDao->id => _civicrm_api3_attachment_format_result($fileDao, $entityFileDao, $returnContent, $isTrusted), ); return civicrm_api3_create_success($result, $params, 'Attachment', 'create'); } diff --git a/api/v3/Constant.php b/api/v3/Constant.php index ef0a33d5d9..f9c96b894c 100644 --- a/api/v3/Constant.php +++ b/api/v3/Constant.php @@ -187,7 +187,7 @@ function _civicrm_api3_constant_get_spec(&$params) { 'title' => 'Constant Name', 'name' => 'name', 'api.required' => 1, - 'options' => array_combine($options, $options) + 'options' => array_combine($options, $options), )) ); } diff --git a/api/v3/Contact.php b/api/v3/Contact.php index 13b832c77e..6b597cc564 100644 --- a/api/v3/Contact.php +++ b/api/v3/Contact.php @@ -393,7 +393,7 @@ function _civicrm_api3_contact_check_params(&$params, $dupeCheck = TRUE, $dupeEr else { $result = civicrm_api3('contact', 'create', array( 'organization_name' => $params['current_employer'], - 'contact_type' => 'Organization' + 'contact_type' => 'Organization', )); $params['employer_id'] = $result['id']; } @@ -834,16 +834,16 @@ LIMIT 0, {$limit} $contactList = array( array( 'data' => $currEmpDetails['data'], - 'id' => $currEmpDetails['id'] - ) + 'id' => $currEmpDetails['id'], + ), ); } else { $contactList = array( array( 'data' => $name, - 'id' => $name - ) + 'id' => $name, + ), ); } } diff --git a/api/v3/Contribution.php b/api/v3/Contribution.php index 749ec6ce70..2e8cee81cc 100644 --- a/api/v3/Contribution.php +++ b/api/v3/Contribution.php @@ -158,14 +158,14 @@ function _civicrm_api3_contribution_create_legacy_support_45(&$params) { $params['soft_credit'][] = array( 'contact_id' => $params['soft_credit_to'], 'amount' => $params['total_amount'], - 'soft_credit_type_id' => CRM_Core_OptionGroup::getDefaultValue("soft_credit_type") + 'soft_credit_type_id' => CRM_Core_OptionGroup::getDefaultValue("soft_credit_type"), ); } if (!empty($params['honor_contact_id'])) { $params['soft_credit'][] = array( 'contact_id' => $params['honor_contact_id'], 'amount' => $params['total_amount'], - 'soft_credit_type_id' => CRM_Utils_Array::value('honor_type_id', $params, CRM_Core_OptionGroup::getValue('soft_credit_type', 'in_honor_of', 'name')) + 'soft_credit_type_id' => CRM_Utils_Array::value('honor_type_id', $params, CRM_Core_OptionGroup::getValue('soft_credit_type', 'in_honor_of', 'name')), ); } } @@ -381,7 +381,7 @@ function civicrm_api3_contribution_sendconfirmation($params) { function _civicrm_api3_contribution_sendconfirmation_spec(&$params) { $params['id'] = array( 'api.required' => 1, - 'title' => 'Contribution ID' + 'title' => 'Contribution ID', ); $params['receipt_from_email'] = array( 'api.required' => 1, diff --git a/api/v3/Domain.php b/api/v3/Domain.php index ae9ce6498b..dea2958350 100644 --- a/api/v3/Domain.php +++ b/api/v3/Domain.php @@ -63,7 +63,7 @@ function civicrm_api3_domain_get($params) { if (!empty($domain['contact_id'])) { $values = array(); $locparams = array( - 'contact_id' => $domain['contact_id'] + 'contact_id' => $domain['contact_id'], ); $values['location'] = CRM_Core_BAO_Location::getValues($locparams, TRUE); @@ -89,7 +89,7 @@ function civicrm_api3_domain_get($params) { 'phone' => CRM_Utils_Array::value( 'phone', $values['location']['phone'][1] - ) + ), ); } diff --git a/api/v3/GroupContact.php b/api/v3/GroupContact.php index cdf473b400..f6e5aa2b97 100644 --- a/api/v3/GroupContact.php +++ b/api/v3/GroupContact.php @@ -190,7 +190,7 @@ function _civicrm_api3_group_contact_common($params, $op = 'Added') { $extraReturnValues= array( 'total_count' => 0, 'added' => 0, - 'not_added' => 0 + 'not_added' => 0, ); foreach ($groupIDs as $groupID) { list($tc, $a, $na) = CRM_Contact_BAO_GroupContact::addContactsToGroup($contactIDs, @@ -208,7 +208,7 @@ function _civicrm_api3_group_contact_common($params, $op = 'Added') { $extraReturnValues= array( 'total_count' => 0, 'removed' => 0, - 'not_removed' => 0 + 'not_removed' => 0, ); foreach ($groupIDs as $groupID) { list($tc, $r, $nr) = CRM_Contact_BAO_GroupContact::removeContactsFromGroup($contactIDs, $groupID, $method, $status, $tracking); diff --git a/api/v3/Job.php b/api/v3/Job.php index f69c1ebd69..481e47f6ef 100644 --- a/api/v3/Job.php +++ b/api/v3/Job.php @@ -213,7 +213,7 @@ function _civicrm_api3_job_send_reminder(&$params) { // as it is calling the api fn to set the filters - update getfields to reflect $params['id'] = array( 'type' => CRM_Utils_Type::T_INT, - 'title' => 'Action Schedule ID' + 'title' => 'Action Schedule ID', ); } /** diff --git a/api/v3/Mailing.php b/api/v3/Mailing.php index f32f4a2fa5..a6029c757f 100755 --- a/api/v3/Mailing.php +++ b/api/v3/Mailing.php @@ -479,7 +479,7 @@ function civicrm_api3_mailing_send_test($params) { $contact = civicrm_api3('Contact', 'create', array('contact_type' => 'Individual', 'email' => $email, - 'api.Email.get' => array('return' => 'id') + 'api.Email.get' => array('return' => 'id'), ) ); $contactId = $contact['id']; @@ -488,7 +488,7 @@ function civicrm_api3_mailing_send_test($params) { civicrm_api3('MailingEventQueue', 'create', array('job_id' => $job['id'], 'email_id' => $emailId, - 'contact_id' => $contactId + 'contact_id' => $contactId, ) ); } @@ -545,27 +545,27 @@ function civicrm_api3_mailing_stats($params) { switch ($detail) { case 'Delivered': $stats[$params['mailing_id']] += array( - $detail => CRM_Mailing_Event_BAO_Delivered::getTotalCount($params['mailing_id'], $params['job_id'], FALSE, $params['date']) + $detail => CRM_Mailing_Event_BAO_Delivered::getTotalCount($params['mailing_id'], $params['job_id'], FALSE, $params['date']), ); break; case 'Bounces': $stats[$params['mailing_id']] += array( - $detail => CRM_Mailing_Event_BAO_Bounce::getTotalCount($params['mailing_id'], $params['job_id'], FALSE, $params['date']) + $detail => CRM_Mailing_Event_BAO_Bounce::getTotalCount($params['mailing_id'], $params['job_id'], FALSE, $params['date']), ); break; case 'Unsubscribers': $stats[$params['mailing_id']] += array( - $detail => CRM_Mailing_Event_BAO_Unsubscribe::getTotalCount($params['mailing_id'], $params['job_id'], FALSE, NULL, $params['date']) + $detail => CRM_Mailing_Event_BAO_Unsubscribe::getTotalCount($params['mailing_id'], $params['job_id'], FALSE, NULL, $params['date']), ); break; case 'Unique Clicks': $stats[$params['mailing_id']] += array( - $detail => CRM_Mailing_Event_BAO_TrackableURLOpen::getTotalCount($params['mailing_id'], $params['job_id'], FALSE, NULL, $params['date']) + $detail => CRM_Mailing_Event_BAO_TrackableURLOpen::getTotalCount($params['mailing_id'], $params['job_id'], FALSE, NULL, $params['date']), ); break; case 'Opened': $stats[$params['mailing_id']] += array( - $detail => CRM_Mailing_Event_BAO_Opened::getTotalCount($params['mailing_id'], $params['job_id'], FALSE, $params['date']) + $detail => CRM_Mailing_Event_BAO_Opened::getTotalCount($params['mailing_id'], $params['job_id'], FALSE, $params['date']), ); break; } diff --git a/api/v3/MailingAB.php b/api/v3/MailingAB.php index d230f203c6..065474dc2d 100755 --- a/api/v3/MailingAB.php +++ b/api/v3/MailingAB.php @@ -223,8 +223,8 @@ function civicrm_api3_mailing_a_b_graph_stats($params) { $graphStats[$name] = array( $params['split_count_select'] => array( 'count' => CRM_Mailing_Event_BAO_Opened::getTotalCount($mailingAB[$column], NULL, TRUE, $toDate), - 'time' => CRM_Utils_Date::customFormat($toDate) - ) + 'time' => CRM_Utils_Date::customFormat($toDate), + ), ); break; case 'total unique clicks': @@ -237,8 +237,8 @@ function civicrm_api3_mailing_a_b_graph_stats($params) { $graphStats[$name] = array( $params['split_count_select'] => array( 'count' => CRM_Mailing_Event_BAO_TrackableURLOpen::getTotalCount($params['mailing_id'], NULL, FALSE, NULL, $toDate), - 'time' => CRM_Utils_Date::customFormat($toDate) - ) + 'time' => CRM_Utils_Date::customFormat($toDate), + ), ); break; case 'total clicks on a particular link': @@ -256,8 +256,8 @@ function civicrm_api3_mailing_a_b_graph_stats($params) { $graphStats[$name] = array( $params['split_count_select'] => array( 'count' => CRM_Mailing_Event_BAO_TrackableURLOpen::getTotalCount($params['mailing_id'], NULL, FALSE, $url_id, $toDate), - 'time' => CRM_Utils_Date::customFormat($toDate) - ) + 'time' => CRM_Utils_Date::customFormat($toDate), + ), ); break; } diff --git a/api/v3/MailingContact.php b/api/v3/MailingContact.php index 4ca17da256..f807114bff 100644 --- a/api/v3/MailingContact.php +++ b/api/v3/MailingContact.php @@ -92,7 +92,7 @@ function _civicrm_api3_mailing_contact_get_spec(&$params) { 'options' => array( 'Delivered' => 'Delivered', 'Bounced' => 'Bounced', - ) + ), ); } @@ -136,13 +136,13 @@ GROUP BY m.id "; $qParams = array( - 1 => array($contactID, 'Integer') + 1 => array($contactID, 'Integer'), ); $dao = CRM_Core_DAO::executeQuery($sql, $qParams); $params = array( 'type' => $type, - 'contact_id' => $contactID + 'contact_id' => $contactID, ); $results = $dao->N; @@ -196,7 +196,7 @@ LIMIT %2, %3 $qParams = array( 1 => array($contactID, 'Integer'), 2 => array($offset, 'Integer'), - 3 => array($limit, 'Integer') + 3 => array($limit, 'Integer'), ); $dao = CRM_Core_DAO::executeQuery($sql, $qParams); diff --git a/api/v3/Membership.php b/api/v3/Membership.php index a6a29785e6..742e4236ea 100644 --- a/api/v3/Membership.php +++ b/api/v3/Membership.php @@ -158,7 +158,7 @@ function _civicrm_api3_membership_create_spec(&$params) { $params['membership_type_id']['api.aliases'] = array('membership_type'); $params['status_id']['api.aliases'] = array('membership_status'); $params['skipStatusCal'] = array( - 'title' => 'Skip status calculation. By default this is 0 if id is not set and 1 if it is set.' + 'title' => 'Skip status calculation. By default this is 0 if id is not set and 1 if it is set.', ); $params['num_terms'] = array( 'title' => 'Number of terms to add/renew. If this parameter is passed, dates will be calculated automatically. If no id is passed (new membership) and no dates are given, num_terms will be assumed to be 1.', diff --git a/api/v3/Pledge.php b/api/v3/Pledge.php index 1bebdf83e0..b4bf07fffe 100644 --- a/api/v3/Pledge.php +++ b/api/v3/Pledge.php @@ -77,7 +77,7 @@ function civicrm_api3_pledge_create($params) { function civicrm_api3_pledge_delete($params) { if (CRM_Pledge_BAO_Pledge::deletePledge($params['id'])) { return civicrm_api3_create_success(array( - 'id' => $params['id'] + 'id' => $params['id'], ), $params, 'pledge', 'delete'); } else { diff --git a/api/v3/Profile.php b/api/v3/Profile.php index 79498d08db..ffa64e8b3a 100644 --- a/api/v3/Profile.php +++ b/api/v3/Profile.php @@ -218,14 +218,14 @@ function civicrm_api3_profile_submit($params) { if (isset($contactParams['api.contribution.create']) && isset($contactParams['api.membership.create'])) { $contactParams['api.membership_payment.create'] = array( 'contribution_id' => '$value.api.contribution.create.id', - 'membership_id' => '$value.api.membership.create.id' + 'membership_id' => '$value.api.membership.create.id', ); } if (isset($contactParams['api.contribution.create']) && isset($contactParams['api.participant.create'])) { $contactParams['api.participant_payment.create'] = array( 'contribution_id' => '$value.api.contribution.create.id', - 'participant_id' => '$value.api.participant.create.id' + 'participant_id' => '$value.api.participant.create.id', ); } diff --git a/api/v3/Setting.php b/api/v3/Setting.php index 63f16cfd3a..5e1a3ee55f 100644 --- a/api/v3/Setting.php +++ b/api/v3/Setting.php @@ -46,7 +46,7 @@ function civicrm_api3_setting_getfields($params) { 'api.required' => 0, 'title' => 'Setting Group', 'description' => 'Settings Group. This is required if the setting is not stored in config', - 'type' => CRM_Utils_Type::T_STRING) + 'type' => CRM_Utils_Type::T_STRING), ); return civicrm_api3_create_success($result, $params, 'setting', 'getfields'); } @@ -168,7 +168,7 @@ function civicrm_api3_setting_fill(&$params) { foreach ($domains as $domainID) { $apiArray = array( 'version' => $params['version'], - 'domain_id' => $domainID + 'domain_id' => $domainID, ); $existing = civicrm_api3('setting', 'get', $apiArray); $valuesToFill = array_diff_key($defaults['values'][$domainID], $existing['values'][$domainID]); @@ -189,7 +189,7 @@ function _civicrm_api3_setting_fill_spec(&$params) { 'api.default' => 'current_domain', 'title' => 'Setting Domain', 'description' => 'Defaults may differ by domain - if you do not pass in a domain id this will default to the current domain - an array or "all" are acceptable values for multiple domains' + an array or "all" are acceptable values for multiple domains', ); } @@ -222,11 +222,11 @@ function _civicrm_api3_setting_create_spec(&$params) { 'api.default' => 'current_domain', 'title' => 'Setting Domain', 'description' => 'if you do not pass in a domain id this will default to the current domain - an array or "all" are acceptable values for multiple domains' + an array or "all" are acceptable values for multiple domains', ); $params['group'] = array( 'title' => 'Setting Group', - 'description' => 'if you know the group defining it will make the api more efficient' + 'description' => 'if you know the group defining it will make the api more efficient', ); } @@ -256,11 +256,11 @@ function _civicrm_api3_setting_get_spec(&$params) { $params['domain_id'] = array( 'api.default' => 'current_domain', 'title' => 'Setting Domain', - 'description' => 'if you do not pass in a domain id this will default to the current domain' + 'description' => 'if you do not pass in a domain id this will default to the current domain', ); $params['group'] = array( 'title' => 'Setting Group', - 'description' => 'if you know the group defining it will make the api more efficient' + 'description' => 'if you know the group defining it will make the api more efficient', ); } /** @@ -317,7 +317,7 @@ function _civicrm_api3_setting_getvalue_spec(&$params) { ); $params['domain_id'] = array( 'title' => 'Setting Domain', - 'description' => 'if you do not pass in a domain id this will default to the current domain' + 'description' => 'if you do not pass in a domain id this will default to the current domain', ); } diff --git a/settings/Event.setting.php b/settings/Event.setting.php index 5ab390605b..b4148f703e 100644 --- a/settings/Event.setting.php +++ b/settings/Event.setting.php @@ -49,6 +49,6 @@ return array( 'is_domain' => 1, 'is_contact' => 1, 'description' => "WRITE ME", - 'help_text' => 'WRITE ME' + 'help_text' => 'WRITE ME', ), ); diff --git a/tests/phpunit/CRM/Case/BAO/CaseTypeForkTest.php b/tests/phpunit/CRM/Case/BAO/CaseTypeForkTest.php index 8597d25ca9..89c1c3f163 100644 --- a/tests/phpunit/CRM/Case/BAO/CaseTypeForkTest.php +++ b/tests/phpunit/CRM/Case/BAO/CaseTypeForkTest.php @@ -36,7 +36,7 @@ class CRM_Case_BAO_CaseTypeForkTest extends CiviCaseTestCase { array('name' => 'First act'), array('name' => 'Second act'), ), - ) + ), )); $this->assertTrue(CRM_Case_BAO_CaseType::isForkable($caseTypeId)); @@ -71,7 +71,7 @@ class CRM_Case_BAO_CaseTypeForkTest extends CiviCaseTestCase { array('name' => 'First act'), array('name' => 'Second act'), ), - ) + ), )); $this->assertFalse(CRM_Case_BAO_CaseType::isForkable($caseTypeId)); diff --git a/tests/phpunit/CRM/Contact/BAO/QueryTest.php b/tests/phpunit/CRM/Contact/BAO/QueryTest.php index 8dd9886069..19a8e71f68 100644 --- a/tests/phpunit/CRM/Contact/BAO/QueryTest.php +++ b/tests/phpunit/CRM/Contact/BAO/QueryTest.php @@ -76,7 +76,7 @@ class CRM_Contact_BAO_QueryTest extends CiviUnitTestCase { 2 => 'Cool City', 3 => 1, 4 => 0, - ) + ), ); $returnProperties = array( 'contact_type' => 1, @@ -114,7 +114,7 @@ class CRM_Contact_BAO_QueryTest extends CiviUnitTestCase { 2 => 'Dumb City', 3 => 1, 4 => 0, - ) + ), ); $returnProperties = array( 'contact_type' => 1, @@ -153,7 +153,7 @@ class CRM_Contact_BAO_QueryTest extends CiviUnitTestCase { 2 => 'Cool City', 3 => 1, 4 => 0, - ) + ), ); $returnProperties = array( 'contact_type' => 1, diff --git a/tests/phpunit/CRM/Core/BAO/RecurringEntityTest.php b/tests/phpunit/CRM/Core/BAO/RecurringEntityTest.php index 5aacef45b0..72f7cd13ed 100644 --- a/tests/phpunit/CRM/Core/BAO/RecurringEntityTest.php +++ b/tests/phpunit/CRM/Core/BAO/RecurringEntityTest.php @@ -72,7 +72,7 @@ class CRM_Core_BAO_RecurringEntityTest extends CiviUnitTestCase { 'repetition_frequency_unit' => 'month', 'repetition_frequency_interval' => 3, 'start_action_offset' => 5, - 'used_for' => 'activity' + 'used_for' => 'activity', ); $generatedEntities = $recursion->generate(); @@ -82,7 +82,7 @@ class CRM_Core_BAO_RecurringEntityTest extends CiviUnitTestCase { '20141227103000', '20150328103000', '20150627103000', - '20150926103000' + '20150926103000', ); foreach ($generatedEntities['civicrm_activity'] as $entityID) { $this->assertDBNotNull('CRM_Activity_DAO_Activity', $entityID, 'id', @@ -146,7 +146,7 @@ class CRM_Core_BAO_RecurringEntityTest extends CiviUnitTestCase { 'repetition_frequency_unit' => 'week', 'repetition_frequency_interval' => 1, 'start_action_offset' => 4, - 'used_for' => 'event' + 'used_for' => 'event', ); $recursion->linkedEntities = array( @@ -154,7 +154,7 @@ class CRM_Core_BAO_RecurringEntityTest extends CiviUnitTestCase { 'table' => 'civicrm_tell_friend', 'findCriteria' => array( 'entity_id' => $recursion->entity_id, - 'entity_table' => 'civicrm_event' + 'entity_table' => 'civicrm_event', ), 'linkedColumns' => array('entity_id'), 'isRecurringEntityRecord' => TRUE, @@ -169,7 +169,7 @@ class CRM_Core_BAO_RecurringEntityTest extends CiviUnitTestCase { '20141027103000' => '20141029103000', '20141103103000' => '20141105103000', '20141110103000' => '20141112103000', - '20141117103000' => '20141119103000' + '20141117103000' => '20141119103000', ); $this->assertCount($recursion->schedule['start_action_offset'], $generatedEntities['civicrm_event'], 'Check if the number of events created are right'); @@ -214,22 +214,22 @@ class CRM_Core_BAO_RecurringEntityTest extends CiviUnitTestCase { //Cross check event exists before we test deletion $searchParamsEventBeforeDelete = array( 'entity_id' => $generatedEntities['civicrm_event'][$key], - 'entity_table' => 'civicrm_event' + 'entity_table' => 'civicrm_event', ); $expectedValuesEventBeforeDelete = array( 'entity_id' => $generatedEntities['civicrm_event'][$key], - 'entity_table' => 'civicrm_event' + 'entity_table' => 'civicrm_event', ); $this->assertDBCompareValues('CRM_Core_DAO_RecurringEntity', $searchParamsEventBeforeDelete, $expectedValuesEventBeforeDelete); //Cross check event exists before we test deletion $searchParamsTellAFriendBeforeDelete = array( 'entity_id' => $generatedEntities['civicrm_tell_friend'][$actKey], - 'entity_table' => 'civicrm_tell_friend' + 'entity_table' => 'civicrm_tell_friend', ); $expectedValuesTellAFriendBeforeDelete = array( 'entity_id' => $generatedEntities['civicrm_tell_friend'][$actKey], - 'entity_table' => 'civicrm_tell_friend' + 'entity_table' => 'civicrm_tell_friend', ); $this->assertDBCompareValues('CRM_Core_DAO_RecurringEntity', $searchParamsTellAFriendBeforeDelete, $expectedValuesTellAFriendBeforeDelete); @@ -245,7 +245,7 @@ class CRM_Core_BAO_RecurringEntityTest extends CiviUnitTestCase { $this->assertDBNull('CRM_Event_DAO_Event', $generatedEntities['civicrm_event'][$key], 'id', 'id', 'Check if event was deleted'); $searchParams = array( 'entity_id' => $generatedEntities['civicrm_event'][$key], - 'entity_table' => 'civicrm_event' + 'entity_table' => 'civicrm_event', ); $compareParams = array(); $this->assertDBCompareValues('CRM_Core_DAO_RecurringEntity', $searchParams, $compareParams); @@ -253,7 +253,7 @@ class CRM_Core_BAO_RecurringEntityTest extends CiviUnitTestCase { //Find tell_a_friend id if that was deleted from civicrm $searchActParams = array( 'entity_id' => $generatedEntities['civicrm_tell_friend'][$actKey], - 'entity_table' => 'civicrm_tell_friend' + 'entity_table' => 'civicrm_tell_friend', ); $compareActParams = array(); $this->assertDBCompareValues('CRM_Friend_DAO_Friend', $searchActParams, $compareActParams); diff --git a/tests/phpunit/CRM/Core/BAO/SettingTest.php b/tests/phpunit/CRM/Core/BAO/SettingTest.php index 8e40c24fc0..2032949d88 100644 --- a/tests/phpunit/CRM/Core/BAO/SettingTest.php +++ b/tests/phpunit/CRM/Core/BAO/SettingTest.php @@ -147,7 +147,7 @@ class CRM_Core_BAO_SettingTest extends CiviUnitTestCase { 'version' => 3, 'name' => 'max_attachments', 'group' => CRM_Core_BAO_Setting::SYSTEM_PREFERENCES_NAME, - 'domain_id' => 2 + 'domain_id' => 2, )); $this->assertEquals(3, $value); @@ -221,7 +221,7 @@ class CRM_Core_BAO_SettingTest extends CiviUnitTestCase { 'description' => NULL, 'help_text' => NULL, 'on_change' => array(// list of callbacks - array(__CLASS__, '_testOnChange_onChangeExample') + array(__CLASS__, '_testOnChange_onChangeExample'), ), ), )); diff --git a/tests/phpunit/CRM/Core/BAO/UFFieldTest.php b/tests/phpunit/CRM/Core/BAO/UFFieldTest.php index 93effc4684..cbb01a5e3e 100644 --- a/tests/phpunit/CRM/Core/BAO/UFFieldTest.php +++ b/tests/phpunit/CRM/Core/BAO/UFFieldTest.php @@ -41,7 +41,7 @@ class CRM_Core_BAO_UFFieldTest extends CiviUnitTestCase { array( 'field_name' => 'activity_date_time', 'field_type' => 'Activity', - ) + ), )); $fields = CRM_Core_BAO_UFField::getAvailableFields($ufGroupId); diff --git a/tests/phpunit/CRM/Core/CommunityMessagesTest.php b/tests/phpunit/CRM/Core/CommunityMessagesTest.php index 9998c0ce80..55c5e59825 100644 --- a/tests/phpunit/CRM/Core/CommunityMessagesTest.php +++ b/tests/phpunit/CRM/Core/CommunityMessagesTest.php @@ -58,11 +58,11 @@ class CRM_Core_CommunityMessagesTest extends CiviUnitTestCase { self::$webResponses = array( 'http-error' => array( CRM_Utils_HttpClient::STATUS_DL_ERROR, - NULL + NULL, ), 'bad-json' => array( CRM_Utils_HttpClient::STATUS_OK, - 'this is not json!' + 'this is not json!', ), 'invalid-ttl-document' => array( CRM_Utils_HttpClient::STATUS_OK, @@ -74,7 +74,7 @@ class CRM_Core_CommunityMessagesTest extends CiviUnitTestCase { 'markup' => '

Invalid document

', ), ), - )) + )), ), 'first-valid-response' => array( CRM_Utils_HttpClient::STATUS_OK, @@ -86,7 +86,7 @@ class CRM_Core_CommunityMessagesTest extends CiviUnitTestCase { 'markup' => '

First valid response

', ), ), - )) + )), ), 'second-valid-response' => array( CRM_Utils_HttpClient::STATUS_OK, @@ -98,7 +98,7 @@ class CRM_Core_CommunityMessagesTest extends CiviUnitTestCase { 'markup' => '

Second valid response

', ), ), - )) + )), ), 'two-messages' => array( CRM_Utils_HttpClient::STATUS_OK, @@ -115,7 +115,7 @@ class CRM_Core_CommunityMessagesTest extends CiviUnitTestCase { 'components' => array('CiviMail'), ), ), - )) + )), ), 'two-messages-halfbadcomp' => array( CRM_Utils_HttpClient::STATUS_OK, @@ -132,7 +132,7 @@ class CRM_Core_CommunityMessagesTest extends CiviUnitTestCase { 'components' => array('CiviMail'), ), ), - )) + )), ), ); } diff --git a/tests/phpunit/CRM/Core/Config/MailerTest.php b/tests/phpunit/CRM/Core/Config/MailerTest.php index 1e8de86e7f..37dd86123a 100644 --- a/tests/phpunit/CRM/Core/Config/MailerTest.php +++ b/tests/phpunit/CRM/Core/Config/MailerTest.php @@ -60,7 +60,7 @@ class CRM_Core_Config_MailerTest extends CiviUnitTestCase { $test->calls['send']++; $test->assertEquals(array('to@example.org'), $recipients); $test->assertEquals('Subject Example', $headers['Subject']); - } + }, )); CRM_Utils_Hook::singleton()->setHook('civicrm_alterMailer', diff --git a/tests/phpunit/CRM/Core/InnoDBIndexerTest.php b/tests/phpunit/CRM/Core/InnoDBIndexerTest.php index 7d744672e7..527064f3d7 100644 --- a/tests/phpunit/CRM/Core/InnoDBIndexerTest.php +++ b/tests/phpunit/CRM/Core/InnoDBIndexerTest.php @@ -20,7 +20,7 @@ class CRM_Core_InnoDBIndexerTest extends CiviUnitTestCase { $idx = new CRM_Core_InnoDBIndexer(TRUE, array( 'civicrm_contact' => array( array('first_name', 'last_name'), - array('foo') + array('foo'), ), 'civicrm_email' => array( array('whiz'), diff --git a/tests/phpunit/CRM/Core/ManagedEntitiesTest.php b/tests/phpunit/CRM/Core/ManagedEntitiesTest.php index 943774fd06..8b6bc83d14 100644 --- a/tests/phpunit/CRM/Core/ManagedEntitiesTest.php +++ b/tests/phpunit/CRM/Core/ManagedEntitiesTest.php @@ -180,7 +180,7 @@ class CRM_Core_ManagedEntitiesTest extends CiviUnitTestCase { // create first managed entity ('foo') $decls[] = array_merge($this->fixtures['com.example.one-foo'], array( - 'cleanup' => 'never' + 'cleanup' => 'never', )); $me = new CRM_Core_ManagedEntities($this->modules, $decls); $me->reconcile(); @@ -209,7 +209,7 @@ class CRM_Core_ManagedEntitiesTest extends CiviUnitTestCase { // create first managed entity ('foo') $decls[] = array_merge($this->fixtures['com.example.one-foo'], array( - 'cleanup' => 'unused' + 'cleanup' => 'unused', )); $me = new CRM_Core_ManagedEntities($this->modules, $decls); $me->reconcile(); @@ -224,7 +224,7 @@ class CRM_Core_ManagedEntitiesTest extends CiviUnitTestCase { 'name' => 'mock', 'type' => 'mock', 'count' => 1, - ) + ), )); }); diff --git a/tests/phpunit/CRM/Core/Page/RedirectTest.php b/tests/phpunit/CRM/Core/Page/RedirectTest.php index e5977e0ae7..daf919797b 100644 --- a/tests/phpunit/CRM/Core/Page/RedirectTest.php +++ b/tests/phpunit/CRM/Core/Page/RedirectTest.php @@ -24,7 +24,7 @@ class CRM_Core_Page_RedirectTest extends CiviUnitTestCase { '', 'gid=2&reset=1', 'url=civicrm/newfoo/%%gid%%?reset=%%reset%%', - '/index.php?q=civicrm/newfoo/2&reset=1' + '/index.php?q=civicrm/newfoo/2&reset=1', ); return $cases; diff --git a/tests/phpunit/CRM/Core/Payment/AuthorizeNetIPNTest.php b/tests/phpunit/CRM/Core/Payment/AuthorizeNetIPNTest.php index b0e8dd15e0..59ad720756 100644 --- a/tests/phpunit/CRM/Core/Payment/AuthorizeNetIPNTest.php +++ b/tests/phpunit/CRM/Core/Payment/AuthorizeNetIPNTest.php @@ -125,7 +125,7 @@ class CRM_Core_Payment_AuthorizeNetIPNTest extends CiviUnitTestCase { 'x_avs_code' => 'Z', 'x_response_reason_text' => 'This transaction has been approved.', 'x_response_reason_code' => '1', - 'x_response_code' => '1' + 'x_response_code' => '1', ); } diff --git a/tests/phpunit/CRM/Core/Payment/BaseIPNTest.php b/tests/phpunit/CRM/Core/Payment/BaseIPNTest.php index c34f9c0c60..fd8f5ba1cb 100644 --- a/tests/phpunit/CRM/Core/Payment/BaseIPNTest.php +++ b/tests/phpunit/CRM/Core/Payment/BaseIPNTest.php @@ -68,7 +68,7 @@ class CRM_Core_Payment_BaseIPNTest extends CiviUnitTestCase { // (as least it will once the pseudoconstant s in the schema) 'payment_processor_type_id' => $this->callAPISuccess('payment_processor_type', 'getvalue', array( 'return' => 'id', - 'name' => 'AuthNet' + 'name' => 'AuthNet', )), ); diff --git a/tests/phpunit/CRM/Core/Payment/PayPalProIPNTest.php b/tests/phpunit/CRM/Core/Payment/PayPalProIPNTest.php index ac33547c83..2b481ce447 100644 --- a/tests/phpunit/CRM/Core/Payment/PayPalProIPNTest.php +++ b/tests/phpunit/CRM/Core/Payment/PayPalProIPNTest.php @@ -269,7 +269,7 @@ class CRM_Core_Payment_PayPalProIPNTest extends CiviUnitTestCase { 'shipping' => '0.00', 'product_type' => '1', 'time_created' => '12:02:25 May 14, 2013 PDT', - 'ipn_track_id' => '912e5010eb5a6' + 'ipn_track_id' => '912e5010eb5a6', ); } /** @@ -322,7 +322,7 @@ class CRM_Core_Payment_PayPalProIPNTest extends CiviUnitTestCase { 'receiver_email' => 'nil@civicrm.org', 'next_payment_date' => '03:00:00 Aug 14, 2013 PDT', 'tax' => '0.00', - 'residence_country' => 'US' + 'residence_country' => 'US', ); } diff --git a/tests/phpunit/CRM/Core/Permission/JoomlaTest.php b/tests/phpunit/CRM/Core/Permission/JoomlaTest.php index a98f46d7ea..17b805ca83 100644 --- a/tests/phpunit/CRM/Core/Permission/JoomlaTest.php +++ b/tests/phpunit/CRM/Core/Permission/JoomlaTest.php @@ -19,7 +19,7 @@ class CRM_Core_Permission_JoomlaTest extends CiviUnitTestCase { $cases[] = array("cms:unknown universal name", CRM_Core_Permission::ALWAYS_DENY_PERMISSION); $cases[] = array( "Joomla:civicrmplusplus.extragood:com_civicrmplusplus", - array("civicrmplusplus.extragood", "com_civicrmplusplus") + array("civicrmplusplus.extragood", "com_civicrmplusplus"), ); $cases[] = array("otherruntime:foo", CRM_Core_Permission::ALWAYS_DENY_PERMISSION); $cases[] = array(CRM_Core_Permission::ALWAYS_DENY_PERMISSION, CRM_Core_Permission::ALWAYS_DENY_PERMISSION); diff --git a/tests/phpunit/CRM/Core/RegionTest.php b/tests/phpunit/CRM/Core/RegionTest.php index 31b08724c8..10e54f9c44 100644 --- a/tests/phpunit/CRM/Core/RegionTest.php +++ b/tests/phpunit/CRM/Core/RegionTest.php @@ -74,11 +74,11 @@ class CRM_Core_RegionTest extends CiviUnitTestCase { )); CRM_Core_Region::instance('testAllTypes')->add(array( // note: returns a value which gets appended to the region - 'callback' => create_function('&$spec, &$html', 'return "callback-return
";') + 'callback' => create_function('&$spec, &$html', 'return "callback-return
";'), )); CRM_Core_Region::instance('testAllTypes')->add(array( // note: returns void; directly modifies region's $html - 'callback' => create_function('&$spec, &$html', '$html = "callback-ref
" . $html;') + 'callback' => create_function('&$spec, &$html', '$html = "callback-ref
" . $html;'), )); CRM_Core_Region::instance('testAllTypes')->add(array( 'scriptUrl' => '/foo%20bar.js', diff --git a/tests/phpunit/CRM/Event/BAO/AdditionalPaymentTest.php b/tests/phpunit/CRM/Event/BAO/AdditionalPaymentTest.php index bc0909915a..ac858e4575 100644 --- a/tests/phpunit/CRM/Event/BAO/AdditionalPaymentTest.php +++ b/tests/phpunit/CRM/Event/BAO/AdditionalPaymentTest.php @@ -140,7 +140,7 @@ class CRM_Event_BAO_AdditionalPaymentTest extends CiviUnitTestCase { 'receive_date' => date('Y-m-d') . " 00:00:00", 'skipLineItem' => 1, 'partial_payment_total' => $feeTotal, - 'partial_amount_pay' => $actualPaidAmt + 'partial_amount_pay' => $actualPaidAmt, ); $contribution = CRM_Contribute_BAO_Contribution::create($contributionParams); diff --git a/tests/phpunit/CRM/Extension/Container/BasicTest.php b/tests/phpunit/CRM/Extension/Container/BasicTest.php index acc7191f67..753a9e5d2d 100644 --- a/tests/phpunit/CRM/Extension/Container/BasicTest.php +++ b/tests/phpunit/CRM/Extension/Container/BasicTest.php @@ -114,7 +114,7 @@ class CRM_Extension_Container_BasicTest extends CiviUnitTestCase { public function testConvertPathsToUrls() { $relPaths = array( 'foo.bar' => 'foo\bar', - 'whiz.bang' => 'tests\extensions\whiz\bang' + 'whiz.bang' => 'tests\extensions\whiz\bang', ); $expectedRelUrls = array( 'foo.bar' => 'foo/bar', diff --git a/tests/phpunit/CRM/Member/Import/Parser/MembershipTest.php b/tests/phpunit/CRM/Member/Import/Parser/MembershipTest.php index b140789e98..b8f1235db0 100644 --- a/tests/phpunit/CRM/Member/Import/Parser/MembershipTest.php +++ b/tests/phpunit/CRM/Member/Import/Parser/MembershipTest.php @@ -72,7 +72,7 @@ class CRM_Member_Import_Parser_MembershipTest extends CiviUnitTestCase { 'visibility' => 'Public', 'is_active' => 1, 'fixed_period_start_day' => 101, - 'fixed_period_rollover_day' => 1231 + 'fixed_period_rollover_day' => 1231, ); $ids = array(); $membershipType = CRM_Member_BAO_MembershipType::add($params, $ids); diff --git a/tests/phpunit/CRM/Report/Form/Contribute/DetailTest.php b/tests/phpunit/CRM/Report/Form/Contribute/DetailTest.php index 3b3ec17752..6a194b8d5f 100644 --- a/tests/phpunit/CRM/Report/Form/Contribute/DetailTest.php +++ b/tests/phpunit/CRM/Report/Form/Contribute/DetailTest.php @@ -63,7 +63,7 @@ class CRM_Report_Form_Contribute_DetailTest extends CiviReportTestCase { ), 'fixtures/dataset-ascii.sql', 'fixtures/report-ascii.csv', - ) + ), ); } diff --git a/tests/phpunit/CRM/Utils/API/MatchOptionTest.php b/tests/phpunit/CRM/Utils/API/MatchOptionTest.php index 1e4cc39a2b..7c5abb0278 100644 --- a/tests/phpunit/CRM/Utils/API/MatchOptionTest.php +++ b/tests/phpunit/CRM/Utils/API/MatchOptionTest.php @@ -39,7 +39,7 @@ class CRM_Utils_API_MatchOptionTest extends CiviUnitTestCase { $this->assertEquals(1, count($value['api.Address.get']['values'])); } CRM_core_DAO::executeQuery('DELETE FROM civicrm_address WHERE contact_id=%1', array( - 1 => array($this->noise['individual'], 'Positive') + 1 => array($this->noise['individual'], 'Positive'), )); $this->callAPISuccess('Contact', 'delete', array( 'id' => $this->noise['individual'], diff --git a/tests/phpunit/CRM/Utils/API/ReloadOptionTest.php b/tests/phpunit/CRM/Utils/API/ReloadOptionTest.php index 5dda910f2f..9a22155784 100644 --- a/tests/phpunit/CRM/Utils/API/ReloadOptionTest.php +++ b/tests/phpunit/CRM/Utils/API/ReloadOptionTest.php @@ -57,7 +57,7 @@ class CRM_Utils_API_ReloadOptionTest extends CiviUnitTestCase { 'last_name' => 'Last', 'nick_name' => 'Firstie', 'options' => array( - 'reload' => 1 + 'reload' => 1, ), )); $this->assertEquals('First', $result['values'][$result['id']]['first_name']); @@ -78,7 +78,7 @@ class CRM_Utils_API_ReloadOptionTest extends CiviUnitTestCase { 'email' => 'test@example.com', ), 'options' => array( - 'reload' => 1 + 'reload' => 1, ), )); $this->assertEquals('First', $result['values'][$result['id']]['first_name']); @@ -99,7 +99,7 @@ class CRM_Utils_API_ReloadOptionTest extends CiviUnitTestCase { CRM_Core_DAO::executeQuery( "UPDATE civicrm_contact SET nick_name = 'munged' WHERE id = %1", array( - 1 => array($objectId, 'Integer') + 1 => array($objectId, 'Integer'), ) ); } diff --git a/tests/phpunit/CRM/Utils/ArrayTest.php b/tests/phpunit/CRM/Utils/ArrayTest.php index fad576b0bc..3a0fce936f 100644 --- a/tests/phpunit/CRM/Utils/ArrayTest.php +++ b/tests/phpunit/CRM/Utils/ArrayTest.php @@ -12,33 +12,33 @@ class CRM_Utils_ArrayTest extends CiviUnitTestCase { 'lang' => 'en', 'msgid' => 'greeting', 'familiar' => FALSE, - 'value' => 'Hello' + 'value' => 'Hello', ); $inputs[] = array( 'lang' => 'en', 'msgid' => 'parting', - 'value' => 'Goodbye' + 'value' => 'Goodbye', ); $inputs[] = array( 'lang' => 'fr', 'msgid' => 'greeting', - 'value' => 'Bon jour' + 'value' => 'Bon jour', ); $inputs[] = array( 'lang' => 'fr', 'msgid' => 'parting', - 'value' => 'Au revoir' + 'value' => 'Au revoir', ); $inputs[] = array( 'lang' => 'en', 'msgid' => 'greeting', 'familiar' => TRUE, - 'value' => 'Hey' + 'value' => 'Hey', ); $inputs[] = array( 'msgid' => 'greeting', 'familiar' => TRUE, - 'value' => 'Universal greeting' + 'value' => 'Universal greeting', ); $byLangMsgid = CRM_Utils_Array::index(array('lang', 'msgid'), $inputs); diff --git a/tests/phpunit/CRM/Utils/Migrate/ImportExportTest.php b/tests/phpunit/CRM/Utils/Migrate/ImportExportTest.php index f409e9fd97..5ef2f47d8c 100644 --- a/tests/phpunit/CRM/Utils/Migrate/ImportExportTest.php +++ b/tests/phpunit/CRM/Utils/Migrate/ImportExportTest.php @@ -160,7 +160,7 @@ class CRM_Utils_Migrate_ImportExportTest extends CiviUnitTestCase { */ public function testBasicXMLExports($customGroupParams, $fieldParams, $expectedXmlFilePath) { $this->assertDBQuery(0, 'SELECT count(*) FROM civicrm_custom_group WHERE title = %1', array( - 1 => array($customGroupParams['title'], 'String') + 1 => array($customGroupParams['title'], 'String'), )); $customGroup = $this->customGroupCreate($customGroupParams); $fieldParams['custom_group_id'] = $customGroup['id']; @@ -185,7 +185,7 @@ class CRM_Utils_Migrate_ImportExportTest extends CiviUnitTestCase { */ public function testBasicXMLImports($expectCustomGroup, $expectCustomField, $inputXmlFilePath) { $this->assertDBQuery(0, 'SELECT count(*) FROM civicrm_custom_group WHERE title = %1', array( - 1 => array($expectCustomGroup['title'], 'String') + 1 => array($expectCustomGroup['title'], 'String'), )); $importer = new CRM_Utils_Migrate_Import(); diff --git a/tests/phpunit/CRM/Utils/SQL/InsertTest.php b/tests/phpunit/CRM/Utils/SQL/InsertTest.php index b82bc0d491..b0135cd0c5 100644 --- a/tests/phpunit/CRM/Utils/SQL/InsertTest.php +++ b/tests/phpunit/CRM/Utils/SQL/InsertTest.php @@ -22,7 +22,7 @@ class CRM_Utils_SQL_InsertTest extends CiviUnitTestCase { ->row(array('first' => '1', 'second' => '2')) ->rows(array( array('second' => '2b', 'first' => '1b'), - array('first' => '1c', 'second' => '2c') + array('first' => '1c', 'second' => '2c'), )) ->row(array('second' => '2d', 'first' => '1d')); $expected = ' diff --git a/tests/phpunit/CRM/Utils/SQL/SelectTest.php b/tests/phpunit/CRM/Utils/SQL/SelectTest.php index 896a8b880a..bee0798fff 100644 --- a/tests/phpunit/CRM/Utils/SQL/SelectTest.php +++ b/tests/phpunit/CRM/Utils/SQL/SelectTest.php @@ -109,7 +109,7 @@ class CRM_Utils_SQL_SelectTest extends CiviUnitTestCase { array( '@escaped' => 'foo"bar', '!unescaped' => 'concat(foo,bar)', - '#validated' => 15.2 + '#validated' => 15.2, ) ); $this->assertLike('"foo\"bar" concat(foo,bar) 15.2', $actual); @@ -121,7 +121,7 @@ class CRM_Utils_SQL_SelectTest extends CiviUnitTestCase { array( '@escaped' => array('foo"bar', "whiz", "null", NULL, "bang"), '!unescaped' => array('foo"bar', 'bar'), - '#validated' => array(1, 10, NULL, 100.1) + '#validated' => array(1, 10, NULL, 100.1), ) ); $this->assertLike('("foo\\"bar", "whiz", "null", NULL, "bang") (foo"bar, bar) (1, 10, NULL, 100.1)', $actual); @@ -130,7 +130,7 @@ class CRM_Utils_SQL_SelectTest extends CiviUnitTestCase { public function testInterpolateBadNumber() { try { $result = CRM_Utils_SQL_Select::from('ignore')->interpolate('#num', array( - '#num' => '5not-a-number5' + '#num' => '5not-a-number5', )); $this->fail('Expected exception; got: ' . var_export($result, TRUE)); } @@ -140,7 +140,7 @@ class CRM_Utils_SQL_SelectTest extends CiviUnitTestCase { try { $result = CRM_Utils_SQL_Select::from('ignore')->interpolate('#num', array( - '#num' => array(1, '5not-a-number5', 2) + '#num' => array(1, '5not-a-number5', 2), )); $this->fail('Expected exception; got: ' . var_export($result, TRUE)); } @@ -152,7 +152,7 @@ class CRM_Utils_SQL_SelectTest extends CiviUnitTestCase { public function testInterpolateBadKey() { try { $result = CRM_Utils_SQL_Select::from('ignore')->interpolate('this is a {var}', array( - '{var}' => 'not a well-formed variable name' + '{var}' => 'not a well-formed variable name', )); $this->fail('Expected exception; got: ' . var_export($result, TRUE)); } diff --git a/tests/phpunit/CRM/Utils/versionCheckTest.php b/tests/phpunit/CRM/Utils/versionCheckTest.php index 3e881d7c9f..428ac318da 100644 --- a/tests/phpunit/CRM/Utils/versionCheckTest.php +++ b/tests/phpunit/CRM/Utils/versionCheckTest.php @@ -43,7 +43,7 @@ class CRM_Utils_versionCheckTest extends CiviUnitTestCase { array('version' => '4.2.16', 'date' => '2014-02-18'), array('version' => '4.2.17', 'date' => '2014-07-01', 'security' => TRUE), array('version' => '4.2.18', 'date' => '2014-08-06'), - array('version' => '4.2.19', 'date' => '2014-09-17', 'security' => TRUE) + array('version' => '4.2.19', 'date' => '2014-09-17', 'security' => TRUE), ), ), '4.3' => array( @@ -58,7 +58,7 @@ class CRM_Utils_versionCheckTest extends CiviUnitTestCase { array('version' => '4.3.6', 'date' => '2013-09-25'), array('version' => '4.3.7', 'date' => '2013-10-02', 'security' => TRUE), array('version' => '4.3.8', 'date' => '2013-11-06', 'security' => TRUE), - array('version' => '4.3.9', 'date' => '2014-09-07', 'security' => TRUE) + array('version' => '4.3.9', 'date' => '2014-09-07', 'security' => TRUE), ), ), '4.4' => array( @@ -75,7 +75,7 @@ class CRM_Utils_versionCheckTest extends CiviUnitTestCase { array('version' => '4.4.8', 'date' => '2014-10-14'), array('version' => '4.4.9', 'date' => '2014-11-05'), array('version' => '4.4.10', 'date' => '2014-11-19'), - array('version' => '4.4.11', 'date' => '2014-12-17', 'security' => TRUE) + array('version' => '4.4.11', 'date' => '2014-12-17', 'security' => TRUE), ), ), '4.5' => array( @@ -87,14 +87,14 @@ class CRM_Utils_versionCheckTest extends CiviUnitTestCase { array('version' => '4.5.3', 'date' => '2014-11-05'), array('version' => '4.5.4', 'date' => '2014-11-19'), array('version' => '4.5.5', 'date' => '2014-12-17', 'security' => TRUE), - ) + ), ), '4.6' => array( 'status' => 'testing', 'releases' => array( array('version' => '4.6.alpha1', 'date' => '2015-02-01'), array('version' => '4.6.beta1', 'date' => '2015-03-01'), - ) + ), ), ); diff --git a/tests/phpunit/Civi/API/Subscriber/DynamicFKAuthorizationTest.php b/tests/phpunit/Civi/API/Subscriber/DynamicFKAuthorizationTest.php index 0a997e18b9..6d13bdf8bd 100644 --- a/tests/phpunit/Civi/API/Subscriber/DynamicFKAuthorizationTest.php +++ b/tests/phpunit/Civi/API/Subscriber/DynamicFKAuthorizationTest.php @@ -114,7 +114,7 @@ class DynamicFKAuthorizationTest extends \CiviUnitTestCase { $cases[] = array( 'FakeFile', 'create', - array('entity_table' => 'fake_widget', 'entity_id' => self::WIDGET_ID) + array('entity_table' => 'fake_widget', 'entity_id' => self::WIDGET_ID), ); $cases[] = array('FakeFile', 'get', array('entity_table' => 'fake_widget')); @@ -137,13 +137,13 @@ class DynamicFKAuthorizationTest extends \CiviUnitTestCase { 'FakeFile', 'create', array('entity_table' => 'fake_forbidden', 'entity_id' => self::FORBIDDEN_ID), - '/Authorization failed/' + '/Authorization failed/', ); $cases[] = array( 'FakeFile', 'get', array('entity_table' => 'fake_forbidden', 'entity_id' => self::FORBIDDEN_ID), - '/Authorization failed/' + '/Authorization failed/', ); $cases[] = array('FakeFile', 'create', array(), "/Mandatory key\\(s\\) missing from params array: 'id' or 'entity_table/"); diff --git a/tests/phpunit/Civi/API/Subscriber/TransactionSubscriberTest.php b/tests/phpunit/Civi/API/Subscriber/TransactionSubscriberTest.php index 1dc87c5969..d4c3a83bf4 100644 --- a/tests/phpunit/Civi/API/Subscriber/TransactionSubscriberTest.php +++ b/tests/phpunit/Civi/API/Subscriber/TransactionSubscriberTest.php @@ -67,7 +67,7 @@ class TransactionSubscriberTest extends \CiviUnitTestCase { 'first_name' => 'Me', 'last_name' => 'Myself', 'options' => array( - 'force_rollback' => TRUE + 'force_rollback' => TRUE, ), )); $this->assertTrue(is_numeric($result['id'])); diff --git a/tests/phpunit/CiviTest/CiviCaseTestCase.php b/tests/phpunit/CiviTest/CiviCaseTestCase.php index 20d02765d9..e7997e6956 100644 --- a/tests/phpunit/CiviTest/CiviCaseTestCase.php +++ b/tests/phpunit/CiviTest/CiviCaseTestCase.php @@ -60,7 +60,7 @@ class CiviCaseTestCase extends CiviUnitTestCase { // state where tests could run afterwards without re-loading. $this->caseStatusGroup = $this->callAPISuccess('option_group', 'get', array( 'name' => 'case_status', - 'format.only_id' => 1 + 'format.only_id' => 1, ) ); $optionValues = array( diff --git a/tests/phpunit/CiviTest/CiviSeleniumTestCase.php b/tests/phpunit/CiviTest/CiviSeleniumTestCase.php index f7b70cb2b3..7bc484bcd4 100644 --- a/tests/phpunit/CiviTest/CiviSeleniumTestCase.php +++ b/tests/phpunit/CiviTest/CiviSeleniumTestCase.php @@ -340,7 +340,7 @@ class CiviSeleniumTestCase extends PHPUnit_Extensions_SeleniumTestCase { $result = $this->webtest_civicrm_api("OptionValue", "getvalue", array( 'option_group_name' => $option_group_name, 'option.limit' => 1, - 'return' => 'value' + 'return' => 'value', )); return $result; } @@ -383,7 +383,7 @@ class CiviSeleniumTestCase extends PHPUnit_Extensions_SeleniumTestCase { $result = $this->webtest_civicrm_api("Domain", "getvalue", array( 'current_domain' => 1, 'option.limit' => 1, - 'return' => 'config_backend' + 'return' => 'config_backend', )); $_config_backend = unserialize($result); } @@ -2219,8 +2219,8 @@ class CiviSeleniumTestCase extends PHPUnit_Extensions_SeleniumTestCase { "{$customSet['entity']}_{$customSet['subEntity']}" => array( 'cgtitle' => $customGroupTitle, 'gid' => $gid, - 'triggerElement' => $customSet['triggerElement'] - ) + 'triggerElement' => $customSet['triggerElement'], + ), ); // Go home for a sec to give time for caches to clear diff --git a/tests/phpunit/CiviTest/CiviUnitTestCase.php b/tests/phpunit/CiviTest/CiviUnitTestCase.php index daa38f550c..895153016a 100755 --- a/tests/phpunit/CiviTest/CiviUnitTestCase.php +++ b/tests/phpunit/CiviTest/CiviUnitTestCase.php @@ -353,7 +353,7 @@ class CiviUnitTestCase extends PHPUnit_Extensions_Database_TestCase { 'CiviMember', 'CiviMail', 'CiviReport', - 'CiviPledge' + 'CiviPledge', )); return TRUE; @@ -1135,7 +1135,7 @@ class CiviUnitTestCase extends PHPUnit_Extensions_Database_TestCase { 'Acme', 'Roberts and Sons', 'Cryo Space Labs', - 'Sharper Pens' + 'Sharper Pens', ), ), 'Household' => array( @@ -1720,7 +1720,7 @@ class CiviUnitTestCase extends PHPUnit_Extensions_Database_TestCase { 'state_province' => 'Michigan', 'supplemental_address_1' => 'Hallmark Ct', 'supplemental_address_2' => 'Jersey Village', - ) + ), ); $params = array( @@ -2020,7 +2020,7 @@ class CiviUnitTestCase extends PHPUnit_Extensions_Database_TestCase { //have a crack @ deleting it first in the hope this will prevent derailing our tests $this->callAPISuccess('custom_group', 'get', array( 'title' => $params['title'], - array('api.custom_group.delete' => 1) + array('api.custom_group.delete' => 1), )); return $this->callAPISuccess('custom_group', 'create', $params); @@ -2065,7 +2065,7 @@ class CiviUnitTestCase extends PHPUnit_Extensions_Database_TestCase { $customField = $this->customFieldCreate(array( 'custom_group_id' => $ids['custom_group_id'], - 'label' => 'field_1' . $ids['custom_group_id'] + 'label' => 'field_1' . $ids['custom_group_id'], )); $ids['custom_field_id'][] = $customField['id']; @@ -2073,14 +2073,14 @@ class CiviUnitTestCase extends PHPUnit_Extensions_Database_TestCase { $customField = $this->customFieldCreate(array( 'custom_group_id' => $ids['custom_group_id'], 'default_value' => '', - 'label' => 'field_2' . $ids['custom_group_id'] + 'label' => 'field_2' . $ids['custom_group_id'], )); $ids['custom_field_id'][] = $customField['id']; $customField = $this->customFieldCreate(array( 'custom_group_id' => $ids['custom_group_id'], 'default_value' => '', - 'label' => 'field_3' . $ids['custom_group_id'] + 'label' => 'field_3' . $ids['custom_group_id'], )); $ids['custom_field_id'][] = $customField['id']; @@ -2787,167 +2787,167 @@ AND ( TABLE_NAME LIKE 'civicrm_value_%' ) $GLOBALS['_HTML_QuickForm_registered_rules'] = array( 'required' => array( 'html_quickform_rule_required', - 'HTML/QuickForm/Rule/Required.php' + 'HTML/QuickForm/Rule/Required.php', ), 'maxlength' => array( 'html_quickform_rule_range', - 'HTML/QuickForm/Rule/Range.php' + 'HTML/QuickForm/Rule/Range.php', ), 'minlength' => array( 'html_quickform_rule_range', - 'HTML/QuickForm/Rule/Range.php' + 'HTML/QuickForm/Rule/Range.php', ), 'rangelength' => array( 'html_quickform_rule_range', - 'HTML/QuickForm/Rule/Range.php' + 'HTML/QuickForm/Rule/Range.php', ), 'email' => array( 'html_quickform_rule_email', - 'HTML/QuickForm/Rule/Email.php' + 'HTML/QuickForm/Rule/Email.php', ), 'regex' => array( 'html_quickform_rule_regex', - 'HTML/QuickForm/Rule/Regex.php' + 'HTML/QuickForm/Rule/Regex.php', ), 'lettersonly' => array( 'html_quickform_rule_regex', - 'HTML/QuickForm/Rule/Regex.php' + 'HTML/QuickForm/Rule/Regex.php', ), 'alphanumeric' => array( 'html_quickform_rule_regex', - 'HTML/QuickForm/Rule/Regex.php' + 'HTML/QuickForm/Rule/Regex.php', ), 'numeric' => array( 'html_quickform_rule_regex', - 'HTML/QuickForm/Rule/Regex.php' + 'HTML/QuickForm/Rule/Regex.php', ), 'nopunctuation' => array( 'html_quickform_rule_regex', - 'HTML/QuickForm/Rule/Regex.php' + 'HTML/QuickForm/Rule/Regex.php', ), 'nonzero' => array( 'html_quickform_rule_regex', - 'HTML/QuickForm/Rule/Regex.php' + 'HTML/QuickForm/Rule/Regex.php', ), 'callback' => array( 'html_quickform_rule_callback', - 'HTML/QuickForm/Rule/Callback.php' + 'HTML/QuickForm/Rule/Callback.php', ), 'compare' => array( 'html_quickform_rule_compare', - 'HTML/QuickForm/Rule/Compare.php' - ) + 'HTML/QuickForm/Rule/Compare.php', + ), ); // FIXME: …ditto for $GLOBALS['HTML_QUICKFORM_ELEMENT_TYPES'] $GLOBALS['HTML_QUICKFORM_ELEMENT_TYPES'] = array( 'group' => array( 'HTML/QuickForm/group.php', - 'HTML_QuickForm_group' + 'HTML_QuickForm_group', ), 'hidden' => array( 'HTML/QuickForm/hidden.php', - 'HTML_QuickForm_hidden' + 'HTML_QuickForm_hidden', ), 'reset' => array( 'HTML/QuickForm/reset.php', - 'HTML_QuickForm_reset' + 'HTML_QuickForm_reset', ), 'checkbox' => array( 'HTML/QuickForm/checkbox.php', - 'HTML_QuickForm_checkbox' + 'HTML_QuickForm_checkbox', ), 'file' => array( 'HTML/QuickForm/file.php', - 'HTML_QuickForm_file' + 'HTML_QuickForm_file', ), 'image' => array( 'HTML/QuickForm/image.php', - 'HTML_QuickForm_image' + 'HTML_QuickForm_image', ), 'password' => array( 'HTML/QuickForm/password.php', - 'HTML_QuickForm_password' + 'HTML_QuickForm_password', ), 'radio' => array( 'HTML/QuickForm/radio.php', - 'HTML_QuickForm_radio' + 'HTML_QuickForm_radio', ), 'button' => array( 'HTML/QuickForm/button.php', - 'HTML_QuickForm_button' + 'HTML_QuickForm_button', ), 'submit' => array( 'HTML/QuickForm/submit.php', - 'HTML_QuickForm_submit' + 'HTML_QuickForm_submit', ), 'select' => array( 'HTML/QuickForm/select.php', - 'HTML_QuickForm_select' + 'HTML_QuickForm_select', ), 'hiddenselect' => array( 'HTML/QuickForm/hiddenselect.php', - 'HTML_QuickForm_hiddenselect' + 'HTML_QuickForm_hiddenselect', ), 'text' => array( 'HTML/QuickForm/text.php', - 'HTML_QuickForm_text' + 'HTML_QuickForm_text', ), 'textarea' => array( 'HTML/QuickForm/textarea.php', - 'HTML_QuickForm_textarea' + 'HTML_QuickForm_textarea', ), 'fckeditor' => array( 'HTML/QuickForm/fckeditor.php', - 'HTML_QuickForm_FCKEditor' + 'HTML_QuickForm_FCKEditor', ), 'tinymce' => array( 'HTML/QuickForm/tinymce.php', - 'HTML_QuickForm_TinyMCE' + 'HTML_QuickForm_TinyMCE', ), 'dojoeditor' => array( 'HTML/QuickForm/dojoeditor.php', - 'HTML_QuickForm_dojoeditor' + 'HTML_QuickForm_dojoeditor', ), 'link' => array( 'HTML/QuickForm/link.php', - 'HTML_QuickForm_link' + 'HTML_QuickForm_link', ), 'advcheckbox' => array( 'HTML/QuickForm/advcheckbox.php', - 'HTML_QuickForm_advcheckbox' + 'HTML_QuickForm_advcheckbox', ), 'date' => array( 'HTML/QuickForm/date.php', - 'HTML_QuickForm_date' + 'HTML_QuickForm_date', ), 'static' => array( 'HTML/QuickForm/static.php', - 'HTML_QuickForm_static' + 'HTML_QuickForm_static', ), 'header' => array( 'HTML/QuickForm/header.php', - 'HTML_QuickForm_header' + 'HTML_QuickForm_header', ), 'html' => array( 'HTML/QuickForm/html.php', - 'HTML_QuickForm_html' + 'HTML_QuickForm_html', ), 'hierselect' => array( 'HTML/QuickForm/hierselect.php', - 'HTML_QuickForm_hierselect' + 'HTML_QuickForm_hierselect', ), 'autocomplete' => array( 'HTML/QuickForm/autocomplete.php', - 'HTML_QuickForm_autocomplete' + 'HTML_QuickForm_autocomplete', ), 'xbutton' => array( 'HTML/QuickForm/xbutton.php', - 'HTML_QuickForm_xbutton' + 'HTML_QuickForm_xbutton', ), 'advmultiselect' => array( 'HTML/QuickForm/advmultiselect.php', - 'HTML_QuickForm_advmultiselect' - ) + 'HTML_QuickForm_advmultiselect', + ), ); } @@ -3024,13 +3024,13 @@ AND ( TABLE_NAME LIKE 'civicrm_value_%' ) $this->callAPISuccess('price_set', 'create', array( 'id' => $contributionPriceSet['id'], 'is_active' => 0, - 'name' => 'old' + 'name' => 'old', )); unset($contributionPriceSet['id']); $newPriceSet = $this->callAPISuccess('price_set', 'create', $contributionPriceSet); $priceField = $this->callAPISuccess('price_field', 'getsingle', array( 'price_set_id' => $firstID, - 'options' => array('limit' => 1) + 'options' => array('limit' => 1), )); unset($priceField['id']); $priceField['price_set_id'] = $newPriceSet['id']; @@ -3038,7 +3038,7 @@ AND ( TABLE_NAME LIKE 'civicrm_value_%' ) $priceFieldValue = $this->callAPISuccess('price_field_value', 'getsingle', array( 'price_set_id' => $firstID, 'sequential' => 1, - 'options' => array('limit' => 1) + 'options' => array('limit' => 1), )); unset($priceFieldValue['id']); @@ -3108,7 +3108,7 @@ AND ( TABLE_NAME LIKE 'civicrm_value_%' ) 'contact_id' => $this->_contactID, 'contribution_page_id' => $this->_contributionPageID, 'payment_processor_id' => $this->_paymentProcessorID, - ) + ), )); $this->_contributionRecurID = $contributionRecur['id']; $this->_contributionID = $contributionRecur['values']['0']['api.contribution.create']['id']; @@ -3143,16 +3143,16 @@ AND ( TABLE_NAME LIKE 'civicrm_value_%' ) 'financial_type_id' => 1, 'price_field_id' => $this->callAPISuccess('price_field', 'getvalue', array( 'return' => 'id', - 'label' => 'Membership Amount' + 'label' => 'Membership Amount', )), 'price_field_value_id' => $this->callAPISuccess('price_field_value', 'getvalue', array( 'return' => 'id', - 'label' => 'General' + 'label' => 'General', )), )); $this->callAPISuccess('membership_payment', 'create', array( 'contribution_id' => $this->_contributionID, - 'membership_id' => $this->ids['membership'] + 'membership_id' => $this->ids['membership'], )); } diff --git a/tests/phpunit/WebTest/Activity/StandaloneAddTest.php b/tests/phpunit/WebTest/Activity/StandaloneAddTest.php index 0e4e4c43d0..bf00e269a7 100644 --- a/tests/phpunit/WebTest/Activity/StandaloneAddTest.php +++ b/tests/phpunit/WebTest/Activity/StandaloneAddTest.php @@ -169,7 +169,7 @@ class WebTest_Activity_StandaloneAddTest extends CiviSeleniumTestCase { $triggerElement = array('name' => 'activity_type_id', 'type' => 'select'); $customSets = array( array('entity' => 'Activity', 'subEntity' => 'Interview', 'triggerElement' => $triggerElement), - array('entity' => 'Activity', 'subEntity' => 'Meeting', 'triggerElement' => $triggerElement) + array('entity' => 'Activity', 'subEntity' => 'Meeting', 'triggerElement' => $triggerElement), ); $pageUrl = array('url' => 'activity', 'args' => 'reset=1&action=add&context=standalone'); diff --git a/tests/phpunit/WebTest/Campaign/CampaignDescriptionTest.php b/tests/phpunit/WebTest/Campaign/CampaignDescriptionTest.php index e72db674d7..95846f7802 100644 --- a/tests/phpunit/WebTest/Campaign/CampaignDescriptionTest.php +++ b/tests/phpunit/WebTest/Campaign/CampaignDescriptionTest.php @@ -88,7 +88,7 @@ class WebTest_Campaign_CampaignDescriptionTest extends CiviSeleniumTestCase { $triggerElement = array('name' => 'campaign_type_id', 'type' => 'select'); $customSets = array( array('entity' => 'Campaign', 'subEntity' => 'Referral Program', 'triggerElement' => $triggerElement), - array('entity' => 'Campaign', 'subEntity' => 'Constituent Engagement', 'triggerElement' => $triggerElement) + array('entity' => 'Campaign', 'subEntity' => 'Constituent Engagement', 'triggerElement' => $triggerElement), ); $pageUrl = array('url' => 'campaign/add', 'args' => 'reset=1'); diff --git a/tests/phpunit/WebTest/Contact/AddressParsingTest.php b/tests/phpunit/WebTest/Contact/AddressParsingTest.php index 26ff03e10e..26b59d4d1d 100644 --- a/tests/phpunit/WebTest/Contact/AddressParsingTest.php +++ b/tests/phpunit/WebTest/Contact/AddressParsingTest.php @@ -147,7 +147,7 @@ class WebTest_Contact_AddressParsingTest extends CiviSeleniumTestCase { 'street_number' => '121', 'street_name' => 'SW Sherman Way', 'street_unit' => 'Suite 15', - ) + ), ); foreach ($verifyData as $loc => $values) { $num = $address[$loc]; diff --git a/tests/phpunit/WebTest/Contact/MergeContactsTest.php b/tests/phpunit/WebTest/Contact/MergeContactsTest.php index 8387fd3e80..d66cb46c94 100644 --- a/tests/phpunit/WebTest/Contact/MergeContactsTest.php +++ b/tests/phpunit/WebTest/Contact/MergeContactsTest.php @@ -621,7 +621,7 @@ class WebTest_Contact_MergeContactsTest extends CiviSeleniumTestCase { $contactEmails = array( 1 => "{$firstName}.{$lastName}@example.com", 2 => "{$firstName2}.{$lastName2}@example.com", - 3 => "{$firstName3}.{$lastName3}@example.com" + 3 => "{$firstName3}.{$lastName3}@example.com", ); foreach ($contactEmails as $key => $value) { @@ -721,7 +721,7 @@ class WebTest_Contact_MergeContactsTest extends CiviSeleniumTestCase { return array( 'mainId' => $mainId, - 'duplicateId' => $duplicateId + 'duplicateId' => $duplicateId, ); } } diff --git a/tests/phpunit/WebTest/Contact/RelationshipAddTest.php b/tests/phpunit/WebTest/Contact/RelationshipAddTest.php index 767e6e8b1e..d40a74e595 100644 --- a/tests/phpunit/WebTest/Contact/RelationshipAddTest.php +++ b/tests/phpunit/WebTest/Contact/RelationshipAddTest.php @@ -360,7 +360,7 @@ class WebTest_Contact_RelationshipAddTest extends CiviSeleniumTestCase { $triggerElement = array('name' => 'relationship_type_id', 'type' => 'select'); $customSets = array( array('entity' => 'Relationship', 'subEntity' => 'Partner of', 'triggerElement' => $triggerElement), - array('entity' => 'Relationship', 'subEntity' => 'Spouse of', 'triggerElement' => $triggerElement) + array('entity' => 'Relationship', 'subEntity' => 'Spouse of', 'triggerElement' => $triggerElement), ); $pageUrl = array('url' => 'contact/view/rel', 'args' => "cid={$contactId[1]}&action=add&reset=1"); diff --git a/tests/phpunit/WebTest/Contact/SearchBuilderTest.php b/tests/phpunit/WebTest/Contact/SearchBuilderTest.php index b9f7c237fb..9ae0031e80 100644 --- a/tests/phpunit/WebTest/Contact/SearchBuilderTest.php +++ b/tests/phpunit/WebTest/Contact/SearchBuilderTest.php @@ -420,7 +420,7 @@ class WebTest_Contact_SearchBuilderTest extends CiviSeleniumTestCase { $this->click("xpath=//div[@class='crm-accordion-header crm-master-accordion-header']"); $this->enterValues(1, 1, 'Contribution', 'Financial Type', NULL, 'IN', array( $financialTypeName1, - $financialTypeName2 + $financialTypeName2, )); $this->clickLink('_qf_Builder_refresh'); diff --git a/tests/phpunit/WebTest/Contribute/AddBatchesTest.php b/tests/phpunit/WebTest/Contribute/AddBatchesTest.php index 738245953b..1e4ebb9a2b 100644 --- a/tests/phpunit/WebTest/Contribute/AddBatchesTest.php +++ b/tests/phpunit/WebTest/Contribute/AddBatchesTest.php @@ -297,7 +297,7 @@ class WebTest_Contribute_AddBatchesTest extends CiviSeleniumTestCase { $this->waitForElementPresent("_qf_MembershipView_cancel-bottom"); $expected = array( 2 => 'General', - 4 => 'New' + 4 => 'New', ); foreach ($expected as $label => $value) { $this->verifyText("xpath=id('MembershipView')/div[2]/div/table[1]/tbody/tr[$label]/td[2]", preg_quote($value)); diff --git a/tests/phpunit/WebTest/Contribute/OfflineContributionTest.php b/tests/phpunit/WebTest/Contribute/OfflineContributionTest.php index f551e02ac4..7d0ce9e8a7 100644 --- a/tests/phpunit/WebTest/Contribute/OfflineContributionTest.php +++ b/tests/phpunit/WebTest/Contribute/OfflineContributionTest.php @@ -197,7 +197,7 @@ class WebTest_Contribute_OfflineContributionTest extends CiviSeleniumTestCase { 4 => 'Donation', 2 => '50.00', 6 => 'Completed', - 1 => "{$firstName} {$lastName}" + 1 => "{$firstName} {$lastName}", ); foreach ($expected as $value => $label) { $this->verifyText("xpath=//div[@class='view-content']//table[@class='selector row-highlight']//tbody/tr[2]/td[$value]", preg_quote($label)); @@ -429,7 +429,7 @@ class WebTest_Contribute_OfflineContributionTest extends CiviSeleniumTestCase { 'Financial Type' => 'Donation', 'Total Amount' => '0.00', 'Contribution Status' => 'Completed', - 'Paid By' => 'Credit Card' + 'Paid By' => 'Credit Card', ); $this->webtestVerifyTabularData($expected); } diff --git a/tests/phpunit/WebTest/Contribute/OnlineContributionTest.php b/tests/phpunit/WebTest/Contribute/OnlineContributionTest.php index 093d9e6675..4f0eb82276 100644 --- a/tests/phpunit/WebTest/Contribute/OnlineContributionTest.php +++ b/tests/phpunit/WebTest/Contribute/OnlineContributionTest.php @@ -310,7 +310,7 @@ class WebTest_Contribute_OnlineContributionTest extends CiviSeleniumTestCase { 'From' => "{$firstName} {$lastName}", 'Financial Type' => 'Donation', $amountLabel => $amountValue, - 'Contribution Status' => 'Completed' + 'Contribution Status' => 'Completed', ); $this->webtestVerifyTabularData($expected); } diff --git a/tests/phpunit/WebTest/Contribute/StandaloneAddTest.php b/tests/phpunit/WebTest/Contribute/StandaloneAddTest.php index 071c3f815c..ac60d23349 100644 --- a/tests/phpunit/WebTest/Contribute/StandaloneAddTest.php +++ b/tests/phpunit/WebTest/Contribute/StandaloneAddTest.php @@ -281,7 +281,7 @@ class WebTest_Contribute_StandaloneAddTest extends CiviSeleniumTestCase { $triggerElement = array('name' => 'financial_type_id', 'type' => 'select'); $customSets = array( array('entity' => 'Contribution', 'subEntity' => 'Donation', 'triggerElement' => $triggerElement), - array('entity' => 'Contribution', 'subEntity' => 'Member Dues', 'triggerElement' => $triggerElement) + array('entity' => 'Contribution', 'subEntity' => 'Member Dues', 'triggerElement' => $triggerElement), ); $pageUrl = array('url' => 'contribute/add', 'args' => 'reset=1&action=add&context=standalone'); diff --git a/tests/phpunit/WebTest/Event/AddParticipationTest.php b/tests/phpunit/WebTest/Event/AddParticipationTest.php index 0a52cfa2d8..4267e0e37d 100644 --- a/tests/phpunit/WebTest/Event/AddParticipationTest.php +++ b/tests/phpunit/WebTest/Event/AddParticipationTest.php @@ -360,7 +360,7 @@ class WebTest_Event_AddParticipationTest extends CiviSeleniumTestCase { 'entity' => 'ParticipantEventName', 'subEntity' => 'Fall Fundraiser Dinner', 'triggerElement' => array('name' => "event_id", 'type' => "select2")), - array('entity' => 'ParticipantRole', 'subEntity' => 'Attendee', 'triggerElement' => array('name' => 'role_id', 'type' => "select")) + array('entity' => 'ParticipantRole', 'subEntity' => 'Attendee', 'triggerElement' => array('name' => 'role_id', 'type' => "select")), ); $pageUrl = array('url' => "participant/add", 'args' => "reset=1&action=add&context=standalone"); $this->customFieldSetLoadOnTheFlyCheck($customSets, $pageUrl, TRUE); @@ -387,7 +387,7 @@ class WebTest_Event_AddParticipationTest extends CiviSeleniumTestCase { 'subEntity' => 'Rain-forest Cup Youth Soccer Tournament', 'triggerElement' => array('name' => "event_id", 'type' => "select")), array('entity' => 'ParticipantRole', 'subEntity' => '- Any -', 'triggerElement' => array('type' => "checkbox")), - array('entity' => 'ParticipantRole', 'subEntity' => 'Volunteer', 'triggerElement' => array('type' => "checkbox")) + array('entity' => 'ParticipantRole', 'subEntity' => 'Volunteer', 'triggerElement' => array('type' => "checkbox")), ); $return = $this->addCustomGroupField($customSets); diff --git a/tests/phpunit/WebTest/Event/AddPricesetTest.php b/tests/phpunit/WebTest/Event/AddPricesetTest.php index 3dcdda4e5e..63d963d781 100644 --- a/tests/phpunit/WebTest/Event/AddPricesetTest.php +++ b/tests/phpunit/WebTest/Event/AddPricesetTest.php @@ -121,12 +121,12 @@ class WebTest_Event_AddPricesetTest extends CiviSeleniumTestCase { 1 => array( 'label' => 'Chicken', 'amount' => '30.00', - 'financial_type_id' => 'Donation' + 'financial_type_id' => 'Donation', ), 2 => array( 'label' => 'Vegetarian', 'amount' => '25.00', - 'financial_type_id' => 'Donation' + 'financial_type_id' => 'Donation', ), ); $this->addMultipleChoiceOptions($options, $validateStrings); @@ -140,13 +140,13 @@ class WebTest_Event_AddPricesetTest extends CiviSeleniumTestCase { 1 => array( 'label' => 'Yes', 'amount' => '50.00', - 'financial_type_id' => 'Donation' + 'financial_type_id' => 'Donation', ), 2 => array( 'label' => 'No', 'amount' => '0', - 'financial_type_id' => 'Donation' + 'financial_type_id' => 'Donation', ), ); $this->addMultipleChoiceOptions($options, $validateStrings); @@ -161,12 +161,12 @@ class WebTest_Event_AddPricesetTest extends CiviSeleniumTestCase { 1 => array( 'label' => 'First Night', 'amount' => '15.00', - 'financial_type_id' => 'Donation' + 'financial_type_id' => 'Donation', ), 2 => array( 'label' => 'Second Night', 'amount' => '15.00', - 'financial_type_id' => 'Donation' + 'financial_type_id' => 'Donation', ), ); $this->addMultipleChoiceOptions($options, $validateStrings); diff --git a/tests/phpunit/WebTest/Export/ContactTest.php b/tests/phpunit/WebTest/Export/ContactTest.php index a22e6e6b20..fe7f0c7116 100644 --- a/tests/phpunit/WebTest/Export/ContactTest.php +++ b/tests/phpunit/WebTest/Export/ContactTest.php @@ -436,7 +436,7 @@ class WebTest_Export_ContactTest extends ExportCiviSeleniumTestCase { $genderLabelArray = array( 1 => 'Female', 2 => 'Male', - 3 => 'Transgender' + 3 => 'Transgender', ); $prefix = rand(1, 4); $suffix = rand(1, 8); @@ -468,7 +468,7 @@ class WebTest_Export_ContactTest extends ExportCiviSeleniumTestCase { 'sequential' => 1, 'option_group_name' => $optionGroupName, 'value' => $optionValue, - 'return' => 'label' + 'return' => 'label', ); $optionLabel = $this->webtest_civicrm_api("OptionValue", "getvalue", $params); return $optionLabel; diff --git a/tests/phpunit/WebTest/Financial/FinancialAccountTest.php b/tests/phpunit/WebTest/Financial/FinancialAccountTest.php index 1f5a94bdf1..b9eb423494 100644 --- a/tests/phpunit/WebTest/Financial/FinancialAccountTest.php +++ b/tests/phpunit/WebTest/Financial/FinancialAccountTest.php @@ -79,7 +79,7 @@ class WebTest_Financial_FinancialAccountTest extends CiviSeleniumTestCase { 'tax_rate' => $taxRate, 'is_tax' => 'on', 'is_deductible' => 'off', - 'is_default' => 'off' + 'is_default' => 'off', ); $this->assertEquals($orgName, $this->getText("xpath=//*[@id='s2id_contact_id']/a/span[1]")); diff --git a/tests/phpunit/WebTest/Financial/FinancialBatchExport.php b/tests/phpunit/WebTest/Financial/FinancialBatchExport.php index 7a4f5f7bd3..0035fe383b 100644 --- a/tests/phpunit/WebTest/Financial/FinancialBatchExport.php +++ b/tests/phpunit/WebTest/Financial/FinancialBatchExport.php @@ -134,7 +134,7 @@ class WebTest_Financial_FinancialBatchExport extends CiviSeleniumTestCase { $this->clickLink("xpath=//div[@id='recently-viewed']/ul/li[1]/a", "_qf_Activity_cancel-bottom"); $this->webtestVerifyTabularData( array( - 'Current Attachment(s)' => 'Financial_Transactions_' + 'Current Attachment(s)' => 'Financial_Transactions_', ) ); } diff --git a/tests/phpunit/WebTest/Grant/CustomFieldsetTest.php b/tests/phpunit/WebTest/Grant/CustomFieldsetTest.php index d981e5375a..18bdc7a9cb 100644 --- a/tests/phpunit/WebTest/Grant/CustomFieldsetTest.php +++ b/tests/phpunit/WebTest/Grant/CustomFieldsetTest.php @@ -115,7 +115,7 @@ class WebTest_Grant_CustomFieldsetTest extends CiviSeleniumTestCase { $triggerElement = array('name' => 'grant_type_id', 'type' => 'select'); $customSets = array( array('entity' => 'Grant', 'subEntity' => 'Emergency', 'triggerElement' => $triggerElement), - array('entity' => 'Grant', 'subEntity' => 'Family Support', 'triggerElement' => $triggerElement) + array('entity' => 'Grant', 'subEntity' => 'Family Support', 'triggerElement' => $triggerElement), ); $pageUrl = array('url' => 'grant/add', 'args' => 'reset=1&action=add&context=standalone'); diff --git a/tests/phpunit/WebTest/Mailing/MailingTest.php b/tests/phpunit/WebTest/Mailing/MailingTest.php index 1666b967a3..f70eeabb02 100644 --- a/tests/phpunit/WebTest/Mailing/MailingTest.php +++ b/tests/phpunit/WebTest/Mailing/MailingTest.php @@ -440,7 +440,7 @@ class WebTest_Mailing_MailingTest extends CiviSeleniumTestCase { 'Intended Recipients' => array( 'report' => array('report_name' => 'Mailing Details', 'Mailing' => "Mailing $mailingName Webtest"), - 'search' => array('Mailing Name IN' => "\"Mailing {$mailingName} Webtest") + 'search' => array('Mailing Name IN' => "\"Mailing {$mailingName} Webtest"), ), 'Successful Deliveries' => array( @@ -448,17 +448,17 @@ class WebTest_Mailing_MailingTest extends CiviSeleniumTestCase { 'report_name' => 'Mailing Details', 'Mailing' => "Mailing $mailingName Webtest", "Delivery Status" => " Successful"), - 'search' => array('Mailing Name IN' => "\"Mailing {$mailingName} Webtest", 'Mailing Delivery -' => "Successful") + 'search' => array('Mailing Name IN' => "\"Mailing {$mailingName} Webtest", 'Mailing Delivery -' => "Successful"), ), 'Tracked Opens' => array( 'report' => array('report_name' => 'Mail Opened', 'Mailing' => "Mailing $mailingName Webtest"), - 'search' => array('Mailing Name IN' => "\"Mailing {$mailingName} Webtest", 'Mailing: Trackable Opens -' => "Opened") + 'search' => array('Mailing Name IN' => "\"Mailing {$mailingName} Webtest", 'Mailing: Trackable Opens -' => "Opened"), ), 'Click-throughs' => array( 'report' => array('report_name' => 'Mail Clickthroughs', 'Mailing' => "Mailing $mailingName Webtest"), - 'search' => array('Mailing Name IN' => "\"Mailing {$mailingName} Webtest", 'Mailing: Trackable URL Clicks -' => "Clicked") + 'search' => array('Mailing Name IN' => "\"Mailing {$mailingName} Webtest", 'Mailing: Trackable URL Clicks -' => "Clicked"), ), 'Forwards' => array( @@ -466,7 +466,7 @@ class WebTest_Mailing_MailingTest extends CiviSeleniumTestCase { 'report_name' => 'Mailing Details', 'Mailing' => "Mailing $mailingName Webtest", 'Forwarded' => 'Is equal to Yes'), - 'search' => array('Mailing Name IN' => "\"Mailing {$mailingName} Webtest", 'Mailing: -' => "Forwards") + 'search' => array('Mailing Name IN' => "\"Mailing {$mailingName} Webtest", 'Mailing: -' => "Forwards"), ), 'Replies' => array( @@ -474,12 +474,12 @@ class WebTest_Mailing_MailingTest extends CiviSeleniumTestCase { 'report_name' => 'Mailing Details', 'Mailing' => "Mailing $mailingName Webtest", 'Replied' => 'Is equal to Yes'), - 'search' => array('Mailing Name IN' => "\"Mailing {$mailingName} Webtest", 'Mailing: Trackable Replies -' => "Replied") + 'search' => array('Mailing Name IN' => "\"Mailing {$mailingName} Webtest", 'Mailing: Trackable Replies -' => "Replied"), ), 'Bounces' => array( 'report' => array('report_name' => 'Mail Bounces', 'Mailing' => "Mailing $mailingName Webtest"), - 'search' => array('Mailing Name IN' => "\"Mailing {$mailingName} Webtest", 'Mailing Delivery -' => "Bounced") + 'search' => array('Mailing Name IN' => "\"Mailing {$mailingName} Webtest", 'Mailing Delivery -' => "Bounced"), ), 'Unsubscribe Requests' => array( @@ -487,7 +487,7 @@ class WebTest_Mailing_MailingTest extends CiviSeleniumTestCase { 'report_name' => 'Mailing Details', 'Mailing' => "Mailing $mailingName Webtest", 'Unsubscribed' => 'Is equal to Yes'), - 'search' => array('Mailing Name IN' => "\"Mailing {$mailingName} Webtest", 'Mailing: -' => "Unsubscribe Requests") + 'search' => array('Mailing Name IN' => "\"Mailing {$mailingName} Webtest", 'Mailing: -' => "Unsubscribe Requests"), ), 'Opt-out Requests' => array( @@ -495,7 +495,7 @@ class WebTest_Mailing_MailingTest extends CiviSeleniumTestCase { 'report_name' => 'Mailing Details', 'Mailing' => "Mailing $mailingName Webtest", 'Opted-out' => 'Is equal to Yes'), - 'search' => array('Mailing Name IN' => "\"Mailing {$mailingName} Webtest", 'Mailing: -' => "Opt-out Requests") + 'search' => array('Mailing Name IN' => "\"Mailing {$mailingName} Webtest", 'Mailing: -' => "Opt-out Requests"), ), ); $this->criteriaCheck($criteriaCheck, $mailingReportUrl); diff --git a/tests/phpunit/WebTest/Member/InheritedMembershipTest.php b/tests/phpunit/WebTest/Member/InheritedMembershipTest.php index 06f387ecbb..a898a998b7 100644 --- a/tests/phpunit/WebTest/Member/InheritedMembershipTest.php +++ b/tests/phpunit/WebTest/Member/InheritedMembershipTest.php @@ -128,7 +128,7 @@ class WebTest_Member_InheritedMembershipTest extends CiviSeleniumTestCase { 'Member Since' => $joinDate, 'Start date' => $startDate, 'End date' => $endDate, - 'Max related' => "5" + 'Max related' => "5", ) ); diff --git a/tests/phpunit/WebTest/Member/StandaloneAddTest.php b/tests/phpunit/WebTest/Member/StandaloneAddTest.php index 5928e09522..1453d603d2 100644 --- a/tests/phpunit/WebTest/Member/StandaloneAddTest.php +++ b/tests/phpunit/WebTest/Member/StandaloneAddTest.php @@ -240,7 +240,7 @@ class WebTest_Member_StandaloneAddTest extends CiviSeleniumTestCase { $triggerElement = array('name' => 'membership_type_id_1', 'type' => 'select'); $customSets = array( array('entity' => 'Membership', 'subEntity' => 'General', 'triggerElement' => $triggerElement), - array('entity' => 'Membership', 'subEntity' => 'Student', 'triggerElement' => $triggerElement) + array('entity' => 'Membership', 'subEntity' => 'Student', 'triggerElement' => $triggerElement), ); $pageUrl = array('url' => 'member/add', 'args' => 'reset=1&action=add&context=standalone'); diff --git a/tests/phpunit/WebTest/Profile/BatchUpdateTest.php b/tests/phpunit/WebTest/Profile/BatchUpdateTest.php index de76fd93ce..073888bc22 100644 --- a/tests/phpunit/WebTest/Profile/BatchUpdateTest.php +++ b/tests/phpunit/WebTest/Profile/BatchUpdateTest.php @@ -62,8 +62,8 @@ class WebTest_Profile_BatchUpdateTest extends CiviSeleniumTestCase { array( 'type' => 'Individual', 'name' => 'Last Name', - 'label' => 'Last Name' - ) + 'label' => 'Last Name', + ), ); $this->addProfile($profileTitle, $profileFields); $this->openCiviPage('contact/search', 'reset=1', '_qf_Basic_refresh'); diff --git a/tests/phpunit/WebTest/Profile/MultiRecordProfileAddTest.php b/tests/phpunit/WebTest/Profile/MultiRecordProfileAddTest.php index c281f74490..bfd18cf83a 100644 --- a/tests/phpunit/WebTest/Profile/MultiRecordProfileAddTest.php +++ b/tests/phpunit/WebTest/Profile/MultiRecordProfileAddTest.php @@ -45,7 +45,7 @@ class WebTest_Profile_MultiRecordProfileAddTest extends CiviSeleniumTestCase { $permissions = array( 'edit-2-profile-listings-and-forms', 'edit-2-access-all-custom-data', - 'edit-2-access-civicrm' + 'edit-2-access-civicrm', ); $this->changePermissions($permissions); list($id, $profileTitle) = $this->_addNewProfile(TRUE, FALSE, TRUE); diff --git a/tests/phpunit/WebTest/Profile/ProfileAddTest.php b/tests/phpunit/WebTest/Profile/ProfileAddTest.php index 6bb8682c5d..eb0b80754f 100644 --- a/tests/phpunit/WebTest/Profile/ProfileAddTest.php +++ b/tests/phpunit/WebTest/Profile/ProfileAddTest.php @@ -157,7 +157,7 @@ class WebTest_Profile_ProfileAddTest extends CiviSeleniumTestCase { $fields = array( 'first_name' => 'Individual', 'last_name' => 'Individual', - 'email' => 'Contact' + 'email' => 'Contact', ); $this->waitForElementPresent("field_name_0"); foreach ($fields as $field => $type) { @@ -199,7 +199,7 @@ class WebTest_Profile_ProfileAddTest extends CiviSeleniumTestCase { $this->clickLink("xpath=//table[@class='crm-group-selector no-footer dataTable']/tbody/tr/td[1]/span[text() = '$groupName']/parent::td/following-sibling::td[@class=' crm-group-group_links']/span/a"); $contactEmails = array( 1 => "$lastName1, $firstName1", - 2 => "$lastName2, $firstName2" + 2 => "$lastName2, $firstName2", ); foreach ($contactEmails as $row => $name) { $this->assertTrue($this->isElementPresent("xpath=//div[@class='crm-search-results']/table/tbody/tr[$row]/td[4]/a[contains(text(), '$name')]")); diff --git a/tests/phpunit/WebTest/Report/LoggingReportTest.php b/tests/phpunit/WebTest/Report/LoggingReportTest.php index 66d974adfe..a8355a3b49 100644 --- a/tests/phpunit/WebTest/Report/LoggingReportTest.php +++ b/tests/phpunit/WebTest/Report/LoggingReportTest.php @@ -223,7 +223,7 @@ class WebTest_Report_LoggingReportTest extends CiviSeleniumTestCase { $relationshipInfo = array(); $relationshipInfo['data'] = array( - array('field' => 'Relationship Is Active', 'changed_from' => 'true', 'changed_to' => 'false') + array('field' => 'Relationship Is Active', 'changed_from' => 'true', 'changed_to' => 'false'), ); $relationshipInfo = array_merge($relationshipInfo, $data[2]); diff --git a/tests/phpunit/WebTest/Report/RolePermissionReportTest.php b/tests/phpunit/WebTest/Report/RolePermissionReportTest.php index 45885ba9a4..0e928b8ce7 100644 --- a/tests/phpunit/WebTest/Report/RolePermissionReportTest.php +++ b/tests/phpunit/WebTest/Report/RolePermissionReportTest.php @@ -125,7 +125,7 @@ class WebTest_Report_RolePermissionReportTest extends CiviSeleniumTestCase { "edit-{$roleId}-access-civireport", "edit-{$roleId}-view-all-contacts", "edit-{$roleId}-administer-reports", - "edit-{$roleId}-access-civicrm" + "edit-{$roleId}-access-civicrm", ); $this->changePermissions($permissions); @@ -141,7 +141,7 @@ class WebTest_Report_RolePermissionReportTest extends CiviSeleniumTestCase { "edit-{$roleId}-view-all-contacts", "edit-{$roleId}-administer-reports", "edit-{$roleId}-access-civicrm", - "edit-{$roleId}-administer-reserved-reports" + "edit-{$roleId}-administer-reserved-reports", ); $this->changePermissions($permissions); diff --git a/tests/phpunit/WebTest/Utils/RestTest.php b/tests/phpunit/WebTest/Utils/RestTest.php index 672d5a40e9..7de715130a 100644 --- a/tests/phpunit/WebTest/Utils/RestTest.php +++ b/tests/phpunit/WebTest/Utils/RestTest.php @@ -66,7 +66,7 @@ class WebTest_Utils_RestTest extends CiviSeleniumTestCase { if (isset($this->nocms_contact_id)) { $deleteParams = array( "id" => $this->nocms_contact_id, - "skip_undelete" => 1 + "skip_undelete" => 1, ); $res = $this->webtest_civicrm_api("Contact", "delete", $deleteParams); unset($this->nocms_contact_id); @@ -214,7 +214,7 @@ class WebTest_Utils_RestTest extends CiviSeleniumTestCase { $contactParams = array( "api_key" => $test_key, "contact_type" => "Individual", - "first_name" => "RestTester1" + "first_name" => "RestTester1", ); $contact = $this->webtest_civicrm_api("Contact", "create", $contactParams); $this->nocms_contact_id = $contact["id"]; @@ -225,7 +225,7 @@ class WebTest_Utils_RestTest extends CiviSeleniumTestCase { "action" => "get", "key" => $this->settings->siteKey, "json" => "1", - "api_key" => $test_key + "api_key" => $test_key, ); list($status, $data) = $client->post($this->url, $params); $this->assertEquals(CRM_Utils_HttpClient::STATUS_OK, $status); @@ -246,7 +246,7 @@ class WebTest_Utils_RestTest extends CiviSeleniumTestCase { $contactParams = array( "api_key" => $test_key, "contact_type" => "Individual", - "first_name" => "RestTester1" + "first_name" => "RestTester1", ); $contact = $this->webtest_civicrm_api("Contact", "create", $contactParams); $this->nocms_contact_id = $contact["id"]; @@ -256,7 +256,7 @@ class WebTest_Utils_RestTest extends CiviSeleniumTestCase { "q" => "civicrm/contact/get", "key" => $this->settings->siteKey, "json" => "1", - "api_key" => $test_key + "api_key" => $test_key, ); list($status, $data) = $client->post($this->url, $params); $this->assertEquals(CRM_Utils_HttpClient::STATUS_OK, $status); diff --git a/tests/phpunit/api/v3/ACLPermissionTest.php b/tests/phpunit/api/v3/ACLPermissionTest.php index efebb37bcf..a9c5f57488 100644 --- a/tests/phpunit/api/v3/ACLPermissionTest.php +++ b/tests/phpunit/api/v3/ACLPermissionTest.php @@ -167,7 +167,7 @@ class api_v3_ACLPermissionTest extends CiviUnitTestCase { 'phone_type_id', 'phone', 'worldregion_id', - 'world_region' + 'world_region', ); $expectedReturnElements = array_diff(array_keys($fullresult['values'][0]), $elementsReturnDoesntSupport); $result = $this->callAPISuccess('contact', 'get', array( @@ -235,12 +235,12 @@ class api_v3_ACLPermissionTest extends CiviUnitTestCase { $this->_permissionedDisabledGroup = $this->groupCreate(array( 'title' => 'pick-me-disabled', 'is_active' => 0, - 'name' => 'pick-me-disabled' + 'name' => 'pick-me-disabled', )); $this->_permissionedGroup = $this->groupCreate(array( 'title' => 'pick-me-active', 'is_active' => 1, - 'name' => 'pick-me-active' + 'name' => 'pick-me-active', )); $this->setupACL(); } diff --git a/tests/phpunit/api/v3/ActionScheduleTest.php b/tests/phpunit/api/v3/ActionScheduleTest.php index ee2a248da8..21efe922a9 100644 --- a/tests/phpunit/api/v3/ActionScheduleTest.php +++ b/tests/phpunit/api/v3/ActionScheduleTest.php @@ -120,7 +120,7 @@ class api_v3_ActionScheduleTest extends CiviUnitTestCase { 'end_action' => 'before', 'end_date' => 'activity_date_time', 'body_html' => 'Test description', - 'subject' => 'Test subject' + 'subject' => 'Test subject', ); $actionSchedule = $this->callAPISuccess('action_schedule', 'create', $params); $this->assertTrue(is_numeric($actionSchedule['id']), "In line " . __LINE__); diff --git a/tests/phpunit/api/v3/ActivityTest.php b/tests/phpunit/api/v3/ActivityTest.php index 340ab6e9e8..dc1b8de9ec 100644 --- a/tests/phpunit/api/v3/ActivityTest.php +++ b/tests/phpunit/api/v3/ActivityTest.php @@ -65,7 +65,7 @@ class api_v3_ActivityTest extends CiviUnitTestCase { 'option_group_id' => 2, 'name' => 'Test activity type', 'label' => 'Test activity type', - 'sequential' => 1 + 'sequential' => 1, )); $this->test_activity_type_value = $activityTypes['values'][0]['value']; $this->test_activity_type_id = $activityTypes['id']; @@ -982,7 +982,7 @@ class api_v3_ActivityTest extends CiviUnitTestCase { 'return.assignee_contact_id' => 1, 'return.target_contact_id' => 1, 'return.source_contact_id' => 1, - 'id' => $result['id'] + 'id' => $result['id'], ) ); diff --git a/tests/phpunit/api/v3/AddressTest.php b/tests/phpunit/api/v3/AddressTest.php index 1b52ce81c5..8f4f80060a 100644 --- a/tests/phpunit/api/v3/AddressTest.php +++ b/tests/phpunit/api/v3/AddressTest.php @@ -129,7 +129,7 @@ class api_v3_AddressTest extends CiviUnitTestCase { $this->callAPISuccess('address', 'create', array_merge($this->_params, $individualParams)); $this->callAPISuccess('relationship', 'getcount', array( 'contact_id_a' => $individualID, - 'contact_id_b' => $this->_contactID + 'contact_id_b' => $this->_contactID, )); } @@ -146,7 +146,7 @@ class api_v3_AddressTest extends CiviUnitTestCase { $this->callAPISuccess('address', 'create', array_merge($this->_params, $individualParams)); $this->callAPISuccess('relationship', 'getcount', array( 'contact_id_a' => $individualID, - 'contact_id_b' => $this->_contactID + 'contact_id_b' => $this->_contactID, )); } @@ -172,7 +172,7 @@ class api_v3_AddressTest extends CiviUnitTestCase { $this->callAPISuccessGetCount('relationship', array( 'contact_id_a' => $individualID, 'is_active' => TRUE, - 'contact_id_b' => $organisation2ID + 'contact_id_b' => $organisation2ID, ), 1); } diff --git a/tests/phpunit/api/v3/AttachmentTest.php b/tests/phpunit/api/v3/AttachmentTest.php index 719da086c6..0a7d84d6bc 100644 --- a/tests/phpunit/api/v3/AttachmentTest.php +++ b/tests/phpunit/api/v3/AttachmentTest.php @@ -95,7 +95,7 @@ class api_v3_AttachmentTest extends CiviUnitTestCase { 'description' => 'My test description', 'options' => array( 'move-file' => $this->tmpFile('mytest.txt'), - ) + ), ), 'This comes from a file', ); @@ -134,7 +134,7 @@ class api_v3_AttachmentTest extends CiviUnitTestCase { 'description' => 'My test description', 'content' => 'too much content', 'options' => array( - 'move-file' => $this->tmpFile('too-much.txt') + 'move-file' => $this->tmpFile('too-much.txt'), ), ), "/'content' and 'options.move-file' are mutually exclusive/", @@ -185,7 +185,7 @@ class api_v3_AttachmentTest extends CiviUnitTestCase { 'check_permissions' => 1, $readOnlyField => $newValue, ), - "/Cannot modify $readOnlyField/" + "/Cannot modify $readOnlyField/", ); } @@ -539,10 +539,10 @@ class api_v3_AttachmentTest extends CiviUnitTestCase { $this->assertTrue(is_numeric($fileId)); $this->assertEquals($exists, file_exists($apiResult['values'][$fileId]['path'])); $this->assertDBQuery($exists ? 1 : 0, 'SELECT count(*) FROM civicrm_file WHERE id = %1', array( - 1 => array($fileId, 'Int') + 1 => array($fileId, 'Int'), )); $this->assertDBQuery($exists ? 1 : 0, 'SELECT count(*) FROM civicrm_entity_file WHERE id = %1', array( - 1 => array($fileId, 'Int') + 1 => array($fileId, 'Int'), )); } diff --git a/tests/phpunit/api/v3/CRM11793Test.php b/tests/phpunit/api/v3/CRM11793Test.php index 2fecf4f014..10153c3cd0 100644 --- a/tests/phpunit/api/v3/CRM11793Test.php +++ b/tests/phpunit/api/v3/CRM11793Test.php @@ -59,7 +59,7 @@ class api_v3_CRM11793Test extends CiviUnitTestCase { 'contact', 'get', array( - 'contact_type' => $contactType + 'contact_type' => $contactType, ) ); diff --git a/tests/phpunit/api/v3/CaseTypeTest.php b/tests/phpunit/api/v3/CaseTypeTest.php index 764dacff12..da563fdda4 100644 --- a/tests/phpunit/api/v3/CaseTypeTest.php +++ b/tests/phpunit/api/v3/CaseTypeTest.php @@ -58,7 +58,7 @@ class api_v3_CaseTypeTest extends CiviCaseTestCase { 'caseRoles' => array( array('name' => 'First role', 'creator' => 1, 'manager' => 1), ), - ) + ), ); } diff --git a/tests/phpunit/api/v3/ContactTest.php b/tests/phpunit/api/v3/ContactTest.php index 325fcdb49f..760ae1adc7 100644 --- a/tests/phpunit/api/v3/ContactTest.php +++ b/tests/phpunit/api/v3/ContactTest.php @@ -328,7 +328,7 @@ class api_v3_ContactTest extends CiviUnitTestCase { $check = $this->callAPISuccess($this->_entity, 'get', array( 'return.custom_' . $ids['custom_field_id'] => 1, - 'id' => $result['id'] + 'id' => $result['id'], )); $this->assertEquals("custom string", $check['values'][$check['id']]['custom_' . $ids['custom_field_id']]); @@ -357,7 +357,7 @@ class api_v3_ContactTest extends CiviUnitTestCase { //here we will just do the get for set-up purposes $count = $this->callAPISuccess('contact', 'getcount', array( 'organization_name' => 'new employer org', - 'contact_type' => 'Organization' + 'contact_type' => 'Organization', )); $this->assertEquals(0, $count); $employerResult = $this->callAPISuccess('contact', 'create', array_merge($this->_params, array( @@ -367,13 +367,13 @@ class api_v3_ContactTest extends CiviUnitTestCase { // do it again as an update to check it doesn't cause an error $employerResult = $this->callAPISuccess('contact', 'create', array_merge($this->_params, array( 'current_employer' => 'new employer org', - 'id' => $employerResult['id'] + 'id' => $employerResult['id'], ) )); $expectedCount = 1; $this->callAPISuccess('contact', 'getcount', array( 'organization_name' => 'new employer org', - 'contact_type' => 'Organization' + 'contact_type' => 'Organization', ), $expectedCount); @@ -403,13 +403,13 @@ class api_v3_ContactTest extends CiviUnitTestCase { $this->callAPISuccess('relationship', 'create', array('id' => $relationship['id'], 'is_active' => 0)); $this->callAPISuccess('relationship', 'getvalue', array( 'id' => $relationship['id'], - 'return' => 'is_active' + 'return' => 'is_active', ), 0); //re-set the current employer - thus enabling the relationshp $this->callAPISuccess('contact', 'create', array_merge($this->_params, array( 'current_employer' => 'new employer org', - 'id' => $employerResult['id'] + 'id' => $employerResult['id'], ) )); //check is_active is now 1 @@ -429,7 +429,7 @@ class api_v3_ContactTest extends CiviUnitTestCase { 'first_name' => 'bb', 'last_name' => 'ccc', 'contact_type' => 'Individual', - 'is_deceased' => 1 + 'is_deceased' => 1, )); $result = $this->callAPISuccess($this->_entity, 'get', array('is_deceased' => 0)); $this->assertFalse(array_key_exists($c2['id'], $result['values'])); @@ -443,7 +443,7 @@ class api_v3_ContactTest extends CiviUnitTestCase { $c2 = $this->callAPISuccess($this->_entity, 'create', array( 'first_name' => 'bb', 'last_name' => 'ccc', - 'contact_type' => 'Individual' + 'contact_type' => 'Individual', )); $result = $this->callAPISuccess($this->_entity, 'get', array( 'sort' => 'first_name ASC', @@ -474,12 +474,12 @@ class api_v3_ContactTest extends CiviUnitTestCase { $c2 = $this->callAPISuccess($this->_entity, 'create', array( 'first_name' => 'bb', 'last_name' => 'ccc', - 'contact_type' => 'Individual' + 'contact_type' => 'Individual', )); $c3 = $this->callAPISuccess($this->_entity, 'create', array( 'first_name' => 'hh', 'last_name' => 'll', - 'contact_type' => 'Individual' + 'contact_type' => 'Individual', )); $result = $this->callAPISuccess($this->_entity, 'get', array('id' => array('IN' => array($c1['id'], $c3['id'])))); $this->assertEquals(2, $result['count']); @@ -526,7 +526,7 @@ class api_v3_ContactTest extends CiviUnitTestCase { $c2 = $this->callAPISuccess($this->_entity, 'create', array( 'first_name' => 'bb', 'last_name' => 'ccc', - 'contact_type' => 'Individual' + 'contact_type' => 'Individual', )); $result = $this->callAPISuccess($this->_entity, 'getvalue', array( 'return' => 'first_name', @@ -580,7 +580,7 @@ class api_v3_ContactTest extends CiviUnitTestCase { $check = $this->callAPIAndDocument($this->_entity, 'get', array( 'return.custom_' . $ids['custom_field_id'] => 1, - 'id' => $result['id'] + 'id' => $result['id'], ), __FUNCTION__, __FILE__, $description, $subfile); $this->assertEquals("custom string", $check['values'][$check['id']]['custom_' . $ids['custom_field_id']]); @@ -621,11 +621,11 @@ class api_v3_ContactTest extends CiviUnitTestCase { 'contact_id' => $contactID, 'address_name' => 'My house', 'location_type_id' => 'Home', - 'street_address' => '1 my road' + 'street_address' => '1 my road', )); $result = $this->callAPISuccessGetSingle('contact', array( 'return' => 'address_name, street_address', - 'id' => $contactID + 'id' => $contactID, )); $this->assertEquals('1 my road', $result['street_address']); $this->assertEquals('My house', $result['address_name']); @@ -1258,13 +1258,13 @@ class api_v3_ContactTest extends CiviUnitTestCase { $this->assertEquals(date('Y-m-d', strtotime('first day of next month -20 years')), $result['values'][$contact3['id']]['birth_date']); $result = $this->callAPISuccess('contact', 'get', array( 'birth_date_low' => date('Y-m-d', strtotime('-6 years')), - 'birth_date_high' => date('Y-m-d', strtotime('- 3 years')) + 'birth_date_high' => date('Y-m-d', strtotime('- 3 years')), )); $this->assertEquals(1, $result['count']); $this->assertEquals(date('Y-m-d', strtotime('first day of next month -5 years')), $result['values'][$contact2['id']]['birth_date']); $result = $this->callAPISuccess('contact', 'get', array( 'birth_date_low' => '-6 years', - 'birth_date_high' => '- 3 years' + 'birth_date_high' => '- 3 years', )); $this->assertEquals(1, $result['count']); $this->assertEquals(date('Y-m-d', strtotime('first day of next month -5 years')), $result['values'][$contact2['id']]['birth_date']); @@ -1289,7 +1289,7 @@ class api_v3_ContactTest extends CiviUnitTestCase { $this->assertEquals(date('Y-m-d', strtotime('first day of next month -20 years')), $result['values'][$contact3['id']]['deceased_date']); $result = $this->callAPISuccess('contact', 'get', array( 'deceased_date_low' => '-6 years', - 'deceased_date_high' => date('Y-m-d', strtotime('- 3 years')) + 'deceased_date_high' => date('Y-m-d', strtotime('- 3 years')), )); $this->assertEquals(1, $result['count']); $this->assertEquals(date('Y-m-d', strtotime('first day of next month -5 years')), $result['values'][$contact2['id']]['deceased_date']); @@ -1345,7 +1345,7 @@ class api_v3_ContactTest extends CiviUnitTestCase { //now we check they are still returned with 'return' key $result = $this->callAPISuccess('contact', 'getsingle', array( 'id' => $contactID, - 'return' => array_keys($extraParams) + 'return' => array_keys($extraParams), )); foreach ($extraParams as $key => $value) { $this->assertEquals($result[$key], $value); @@ -1369,8 +1369,8 @@ class api_v3_ContactTest extends CiviUnitTestCase { 'phone' => '222-222-2222', 'location_type_id' => 1, 'phone_type_id' => 2, - ) - ) + ), + ), ); $this->callAPISuccess('contact', 'create', $params); $this->callAPISuccessGetCount('phone', array('contact_id' => $contactID), 2); @@ -1532,7 +1532,7 @@ class api_v3_ContactTest extends CiviUnitTestCase { $moreids = $this->CustomGroupMultipleCreateWithFields(); $andmoreids = $this->CustomGroupMultipleCreateWithFields(array( 'title' => "another group", - 'name' => 'another name' + 'name' => 'another name', )); $description = "/*this demonstrates the usage of chained api functions. A variety of techniques are used"; $subfile = "APIChainedArrayMultipleCustom"; @@ -1739,7 +1739,7 @@ class api_v3_ContactTest extends CiviUnitTestCase { 'contact_type' => 'Individual', 'first_name' => 'Foo', 'last_name' => 'Bear', - 'check_permissions' => TRUE + 'check_permissions' => TRUE, ); $result = $this->callAPISuccess('contact', 'create', $params); $config = CRM_Core_Config::singleton(); @@ -1747,7 +1747,7 @@ class api_v3_ContactTest extends CiviUnitTestCase { 'id' => $result['id'], 'contact_type' => 'Individual', 'last_name' => 'Bar', - 'check_permissions' => TRUE + 'check_permissions' => TRUE, ); $config->userPermissionClass->permissions = array('access CiviCRM'); @@ -1759,7 +1759,7 @@ class api_v3_ContactTest extends CiviUnitTestCase { 'add contacts', 'view all contacts', 'edit all contacts', - 'import contacts' + 'import contacts', ); $this->callAPISuccess('contact', 'update', $params, NULL, 'overfluous permissions should be enough to update a contact'); } @@ -1837,7 +1837,7 @@ class api_v3_ContactTest extends CiviUnitTestCase { 'email' => 'spam@dev.null', 'is_primary' => 0, 'location_type_id' => 1, - ) + ), ), ), 'api.Phone.replace' => array( @@ -1865,7 +1865,7 @@ class api_v3_ContactTest extends CiviUnitTestCase { //$refCountsIdx = CRM_Utils_Array::index(array('name'), $refCounts); $refCounts = $this->callAPISuccess('Contact', 'getrefcount', array( - 'id' => $result['id'] + 'id' => $result['id'], )); $refCountsIdx = CRM_Utils_Array::index(array('name'), $refCounts['values']); @@ -1935,7 +1935,7 @@ class api_v3_ContactTest extends CiviUnitTestCase { $this->callAPISuccess('address', 'create', array( 'contact_id' => $contactID, 'city' => 'Cool City', - 'location_type_id' => 1 + 'location_type_id' => 1, )); $result = $this->callAPISuccess('contact', 'get', array('city' => 'Cool City', 'return' => 'contact_type')); $this->assertEquals(1, $result['count']); @@ -1955,7 +1955,7 @@ class api_v3_ContactTest extends CiviUnitTestCase { // Force-exclude the deceased contact $result = $this->callAPISuccess('contact', 'getlist', array( 'input' => $name, - 'params' => array('is_deceased' => 0) + 'params' => array('is_deceased' => 0), )); $this->assertEquals(1, $result['count'], 'In line ' . __LINE__); $this->assertEquals($contact, $result['values'][0]['id'], 'In line ' . __LINE__); diff --git a/tests/phpunit/api/v3/ContributionPageTest.php b/tests/phpunit/api/v3/ContributionPageTest.php index 36d833ecc2..b0ded9fb30 100644 --- a/tests/phpunit/api/v3/ContributionPageTest.php +++ b/tests/phpunit/api/v3/ContributionPageTest.php @@ -77,7 +77,7 @@ class api_v3_ContributionPageTest extends CiviUnitTestCase { 'is_quick_config' => 1, 'extends' => 'CiviContribute', 'financial_type_id' => 'Donation', - 'title' => 'my Page' + 'title' => 'my Page', ); } @@ -142,7 +142,7 @@ class api_v3_ContributionPageTest extends CiviUnitTestCase { $submitParams = array( 'price_' . $priceFieldID => $priceFieldValueID, 'id' => (int) $this->_ids['contribution_page'], - 'amount' => 10 + 'amount' => 10, ); $this->callAPISuccess('contribution_page', 'submit', $submitParams); @@ -246,7 +246,7 @@ class api_v3_ContributionPageTest extends CiviUnitTestCase { $this->callAPIAndDocument('contribution_page', 'submit', $submitParams, __FUNCTION__, __FILE__, 'submit contribution page', NULL, 'Submit'); $contributions = $this->callAPISuccess('contribution', 'get', array( 'contribution_page_id' => $this->_ids['contribution_page'], - 'contribution_status_id' => 1 + 'contribution_status_id' => 1, )); $this->assertCount(2, $contributions['values']); $membershipPayment = $this->callAPISuccess('membership_payment', 'getsingle', array()); @@ -292,7 +292,7 @@ class api_v3_ContributionPageTest extends CiviUnitTestCase { $this->callAPIAndDocument('contribution_page', 'submit', $submitParams, __FUNCTION__, __FILE__, 'submit contribution page', NULL, 'Submit'); $contribution = $this->callAPISuccess('contribution', 'getsingle', array( 'contribution_page_id' => $this->_ids['contribution_page'], - 'contribution_status_id' => 1 + 'contribution_status_id' => 1, )); $membershipPayment = $this->callAPISuccess('membership_payment', 'getsingle', array()); $this->assertEquals($membershipPayment['contribution_id'], $contribution['id']); @@ -309,7 +309,7 @@ class api_v3_ContributionPageTest extends CiviUnitTestCase { $this->callAPISuccess('contribution', 'getsingle', array( 'id' => array('NOT IN' => array($contribution['id'])), 'contribution_page_id' => $this->_ids['contribution_page'], - 'contribution_status_id' => 1 + 'contribution_status_id' => 1, )); $renewedMembership = $this->callAPISuccessGetSingle('membership', array('id' => $membershipPayment['membership_id'])); $this->assertEquals(date('Y-m-d', strtotime('+ 1 year', strtotime($membership['end_date']))), $renewedMembership['end_date']); @@ -354,7 +354,7 @@ class api_v3_ContributionPageTest extends CiviUnitTestCase { $this->callAPIAndDocument('contribution_page', 'submit', $submitParams, __FUNCTION__, __FILE__, 'submit contribution page', NULL, 'Submit'); $contribution = $this->callAPISuccess('contribution', 'getsingle', array( 'contribution_page_id' => $this->_ids['contribution_page'], - 'contribution_status_id' => 2 + 'contribution_status_id' => 2, )); $membershipPayment = $this->callAPISuccess('membership_payment', 'getsingle', array()); $this->assertEquals($membershipPayment['contribution_id'], $contribution['id']); @@ -365,7 +365,7 @@ class api_v3_ContributionPageTest extends CiviUnitTestCase { //$this->callAPISuccess('line_item', 'getsingle', array('contribution_id' => $contribution['id'], 'entity_id' => $membership['id'])); $this->callAPISuccess('contribution', 'completetransaction', array( 'id' => $contribution['id'], - 'trxn_id' => 'ipn_called' + 'trxn_id' => 'ipn_called', )); $membership = $this->callAPISuccessGetSingle('membership', array('id' => $membershipPayment['membership_id'])); //renew it with processor setting completed - should extend membership @@ -380,10 +380,10 @@ class api_v3_ContributionPageTest extends CiviUnitTestCase { $this->callAPISuccess('contribution_page', 'submit', $submitParams); $newContribution = $this->callAPISuccess('contribution', 'getsingle', array( 'id' => array( - 'NOT IN' => array($contribution['id']) + 'NOT IN' => array($contribution['id']), ), 'contribution_page_id' => $this->_ids['contribution_page'], - 'contribution_status_id' => 2 + 'contribution_status_id' => 2, ) ); @@ -425,7 +425,7 @@ class api_v3_ContributionPageTest extends CiviUnitTestCase { public function setUpMembershipBlockPriceSet() { $this->_ids['price_set'][] = $this->callAPISuccess('price_set', 'getvalue', array( 'name' => 'default_membership_type_amount', - 'return' => 'id' + 'return' => 'id', )); if (empty($this->_ids['membership_type'])) { $this->_ids['membership_type'] = array($this->membershipTypeCreate(array('minimum_fee' => 2))); diff --git a/tests/phpunit/api/v3/ContributionTest.php b/tests/phpunit/api/v3/ContributionTest.php index 7325571d49..530033d401 100644 --- a/tests/phpunit/api/v3/ContributionTest.php +++ b/tests/phpunit/api/v3/ContributionTest.php @@ -436,18 +436,18 @@ class api_v3_ContributionTest extends CiviUnitTestCase { $contribution = $this->callAPISuccess('contribution', 'create', $params); $contribution = $this->callAPISuccess('contribution', 'get', array( 'sequential' => 1, - 'id' => $contribution['id'] + 'id' => $contribution['id'], )); $this->assertArrayHasKey('payment_instrument', $contribution['values'][0]); $this->assertEquals('EFT', $contribution['values'][0]['payment_instrument']); $this->callAPISuccess('contribution', 'create', array( 'id' => $contribution['id'], - 'payment_instrument' => 'Credit Card' + 'payment_instrument' => 'Credit Card', )); $contribution = $this->callAPISuccess('contribution', 'get', array( 'sequential' => 1, - 'id' => $contribution['id'] + 'id' => $contribution['id'], )); $this->assertArrayHasKey('payment_instrument', $contribution['values'][0]); $this->assertEquals('Credit Card', $contribution['values'][0]['payment_instrument']); @@ -460,35 +460,35 @@ class api_v3_ContributionTest extends CiviUnitTestCase { $this->callAPISuccess('contribution', 'create', $params2); $contribution = $this->callAPISuccess('contribution', 'get', array( 'sequential' => 1, - 'contribution_payment_instrument_id' => 'Cash' + 'contribution_payment_instrument_id' => 'Cash', )); $this->assertArrayHasKey('payment_instrument', $contribution['values'][0]); $this->assertEquals('Cash', $contribution['values'][0]['payment_instrument']); $this->assertEquals(1, $contribution['count']); $contribution = $this->callAPISuccess('contribution', 'get', array( 'sequential' => 1, - 'payment_instrument_id' => 'EFT' + 'payment_instrument_id' => 'EFT', )); $this->assertArrayHasKey('payment_instrument', $contribution['values'][0]); $this->assertEquals('EFT', $contribution['values'][0]['payment_instrument']); $this->assertEquals(1, $contribution['count']); $contribution = $this->callAPISuccess('contribution', 'get', array( 'sequential' => 1, - 'payment_instrument_id' => 5 + 'payment_instrument_id' => 5, )); $this->assertArrayHasKey('payment_instrument', $contribution['values'][0]); $this->assertEquals('EFT', $contribution['values'][0]['payment_instrument']); $this->assertEquals(1, $contribution['count']); $contribution = $this->callAPISuccess('contribution', 'get', array( 'sequential' => 1, - 'payment_instrument' => 'EFT' + 'payment_instrument' => 'EFT', )); $this->assertArrayHasKey('payment_instrument', $contribution['values'][0]); $this->assertEquals('EFT', $contribution['values'][0]['payment_instrument']); $this->assertEquals(1, $contribution['count']); $contribution = $this->callAPISuccess('contribution', 'create', array( 'id' => $contribution['id'], - 'payment_instrument' => 'Credit Card' + 'payment_instrument' => 'Credit Card', )); $contribution = $this->callAPISuccess('contribution', 'get', array('sequential' => 1, 'id' => $contribution['id'])); $this->assertArrayHasKey('payment_instrument', $contribution['values'][0]); @@ -603,7 +603,7 @@ class api_v3_ContributionTest extends CiviUnitTestCase { $result = $this->callAPISuccess('note', 'get', array( 'entity_table' => 'civicrm_contribution', 'entity_id' => $contribution['id'], - 'sequential' => 1 + 'sequential' => 1, )); $this->assertEquals('my contribution note', $result['values'][0]['note']); $this->callAPISuccess('contribution', 'delete', array('id' => $contribution['id'])); @@ -630,7 +630,7 @@ class api_v3_ContributionTest extends CiviUnitTestCase { $result = $this->callAPISuccess('note', 'get', array( 'entity_table' => 'civicrm_contribution', 'entity_id' => $contribution['id'], - 'sequential' => 1 + 'sequential' => 1, )); $this->assertEquals('my contribution note', $result['values'][0]['note']); $this->callAPISuccess('contribution', 'delete', array('id' => $contribution['id'])); @@ -645,12 +645,12 @@ class api_v3_ContributionTest extends CiviUnitTestCase { $subfile = "ContributionCreateWithSoftCredit"; $contact2 = $this->callAPISuccess('Contact', 'create', array( 'display_name' => 'superman', - 'contact_type' => 'Individual' + 'contact_type' => 'Individual', )); $softparams = array( 'contact_id' => $contact2['id'], 'amount' => 50, - 'soft_credit_type_id' => 3 + 'soft_credit_type_id' => 3, ); $params = $this->_params + array('soft_credit' => array(1 => $softparams)); @@ -670,7 +670,7 @@ class api_v3_ContributionTest extends CiviUnitTestCase { $subfile = "ContributionCreateWithSoftCreditDefaults"; $contact2 = $this->callAPISuccess('Contact', 'create', array( 'display_name' => 'superman', - 'contact_type' => 'Individual' + 'contact_type' => 'Individual', )); $params = $this->_params + array( 'soft_credit_to' => $contact2['id'], @@ -692,7 +692,7 @@ class api_v3_ContributionTest extends CiviUnitTestCase { $subfile = "ContributionCreateWithHonoreeContact"; $contact2 = $this->callAPISuccess('Contact', 'create', array( 'display_name' => 'superman', - 'contact_type' => 'Individual' + 'contact_type' => 'Individual', )); $params = $this->_params + array( 'honor_contact_id' => $contact2['id'], @@ -899,7 +899,7 @@ class api_v3_ContributionTest extends CiviUnitTestCase { $contribution = $this->callAPISuccess('contribution', 'create', $this->_params); $contribution = $this->callAPISuccess('contribution', 'getsingle', array( 'id' => $contribution['id'], - 'api.contribution.delete' => 1 + 'api.contribution.delete' => 1, )); $this->assertEquals(1, $contribution['contribution_status_id']); $this->assertEquals('Check', $contribution['payment_instrument']); @@ -924,7 +924,7 @@ class api_v3_ContributionTest extends CiviUnitTestCase { $newParams = array( 'id' => $contribution['id'], - 'total_amount' => '125' + 'total_amount' => '125', ); $contribution = $this->callAPISuccess('contribution', 'create', $newParams); @@ -1101,7 +1101,7 @@ class api_v3_ContributionTest extends CiviUnitTestCase { $this->callAPISuccess('contribution', 'create', array('id' => $contribution['id'], 'source' => 'new source')); $contribution = $this->callAPISuccess('contribution', 'getsingle', array( 'id' => $contribution['id'], - 'api.contribution.delete' => 1 + 'api.contribution.delete' => 1, )); $this->assertEquals(2, $contribution['contribution_status_id']); } @@ -1358,7 +1358,7 @@ class api_v3_ContributionTest extends CiviUnitTestCase { ); $participantStatus = $this->callAPISuccessGetValue('participant', array( 'id' => $this->_ids['participant'], - 'return' => 'participant_status_id' + 'return' => 'participant_status_id', )); $this->assertEquals(1, $participantStatus); $mut->checkMailLog(array( @@ -1421,7 +1421,7 @@ class api_v3_ContributionTest extends CiviUnitTestCase { 'is_quick_config' => 0, 'extends' => 'CiviMember', 'financial_type_id' => 1, - 'title' => 'my Page' + 'title' => 'my Page', )); $priceSetID = $priceSet['id']; @@ -1518,7 +1518,7 @@ class api_v3_ContributionTest extends CiviUnitTestCase { 'Contribution Information', 'Please print this confirmation for your records', ), array( - 'Event' + 'Event', ) ); $mut->stop(); @@ -1603,7 +1603,7 @@ class api_v3_ContributionTest extends CiviUnitTestCase { $contribution = $this->callAPISuccess('contribution', 'create', $params); $this->callAPISuccess('participant_payment', 'create', array( 'contribution_id' => $contribution['id'], - 'participant_id' => $participantID + 'participant_id' => $participantID, )); $this->callAPISuccess('line_item', 'get', array( 'entity_id' => $contribution['id'], diff --git a/tests/phpunit/api/v3/DashboardContactTest.php b/tests/phpunit/api/v3/DashboardContactTest.php index 5db408c5c0..9dddfb00bc 100644 --- a/tests/phpunit/api/v3/DashboardContactTest.php +++ b/tests/phpunit/api/v3/DashboardContactTest.php @@ -62,7 +62,7 @@ class api_v3_DashboardContactTest extends CiviUnitTestCase { 'first_name' => 'abc1', 'contact_type' => 'Individual', 'last_name' => 'xyz1', - 'email' => 'abc@abc.com' + 'email' => 'abc@abc.com', ) ); $oldCount = CRM_Core_DAO::singleValueQuery("select count(*) from civicrm_dashboard_contact where contact_id = {$contact['id']} AND is_active = 1 AND dashboard_id = {$dashresult['id']}"); diff --git a/tests/phpunit/api/v3/DomainTest.php b/tests/phpunit/api/v3/DomainTest.php index 874fea3a41..d9fea6e95e 100644 --- a/tests/phpunit/api/v3/DomainTest.php +++ b/tests/phpunit/api/v3/DomainTest.php @@ -74,7 +74,7 @@ class api_v3_DomainTest extends CiviUnitTestCase { 'api.email.create' => array( 'location_type_id' => $defaultLocationType->id, 'email' => 'my@email.com', - ) + ), ) ); diff --git a/tests/phpunit/api/v3/JobTest.php b/tests/phpunit/api/v3/JobTest.php index 3cda472aaf..dd9ad92e7e 100644 --- a/tests/phpunit/api/v3/JobTest.php +++ b/tests/phpunit/api/v3/JobTest.php @@ -170,7 +170,7 @@ class api_v3_JobTest extends CiviUnitTestCase { public function testCallUpdateGreetingSuccess() { $result = $this->callAPISuccess($this->_entity, 'update_greeting', array( 'gt' => 'postal_greeting', - 'ct' => 'Individual' + 'ct' => 'Individual', )); } @@ -211,7 +211,7 @@ class api_v3_JobTest extends CiviUnitTestCase { $this->callAPISuccess('group_contact', 'create', array( 'contact_id' => $contactID, 'status' => 'Added', - 'group_id' => $groupID + 'group_id' => $groupID, )); } $result = $this->callAPISuccess('job', 'send_reminder', array()); @@ -238,7 +238,7 @@ class api_v3_JobTest extends CiviUnitTestCase { $this->callAPISuccess('group_contact', 'create', array( 'contact_id' => $contactID, 'status' => 'Added', - 'group_id' => $groupID + 'group_id' => $groupID, )); } if ($i > 1) { @@ -275,7 +275,7 @@ class api_v3_JobTest extends CiviUnitTestCase { CRM_Utils_Hook_UnitTests::singleton()->setHook('civicrm_pre', array($this, 'hookPreRelationship')); $relationshipTypeID = $this->callAPISuccess('relationship_type', 'getvalue', array( 'return' => 'id', - 'name_a_b' => 'Employee of' + 'name_a_b' => 'Employee of', )); $result = $this->callAPISuccess('relationship', 'create', array( 'relationship_type_id' => $relationshipTypeID, diff --git a/tests/phpunit/api/v3/MailingABTest.php b/tests/phpunit/api/v3/MailingABTest.php index d50453ae40..43bf621741 100755 --- a/tests/phpunit/api/v3/MailingABTest.php +++ b/tests/phpunit/api/v3/MailingABTest.php @@ -171,20 +171,20 @@ class api_v3_MailingABTest extends CiviUnitTestCase { $this->assertDBQuery($expectedA, 'SELECT count(*) FROM civicrm_mailing_job WHERE mailing_id = %1', array( 1 => array( $this->_mailingID_A, - 'Integer' - ) + 'Integer', + ), )); $this->assertDBQuery($expectedB, 'SELECT count(*) FROM civicrm_mailing_job WHERE mailing_id = %1', array( 1 => array( $this->_mailingID_B, - 'Integer' - ) + 'Integer', + ), )); $this->assertDBQuery($expectedC, 'SELECT count(*) FROM civicrm_mailing_job WHERE mailing_id = %1', array( 1 => array( $this->_mailingID_C, - 'Integer' - ) + 'Integer', + ), )); } } diff --git a/tests/phpunit/api/v3/MailingTest.php b/tests/phpunit/api/v3/MailingTest.php index a07977a6d5..c185da7571 100755 --- a/tests/phpunit/api/v3/MailingTest.php +++ b/tests/phpunit/api/v3/MailingTest.php @@ -302,7 +302,7 @@ class api_v3_MailingTest extends CiviUnitTestCase { $this->assertEquals($params['scheduled_date'], $submitResult['values'][$id]['scheduled_date']); } $this->assertDBQuery($expectedJobCount, 'SELECT count(*) FROM civicrm_mailing_job WHERE mailing_id = %1', array( - 1 => array($id, 'Integer') + 1 => array($id, 'Integer'), )); } @@ -350,7 +350,7 @@ SELECT event_queue_id, time_stamp FROM mail_{$type}_temp"; 'Bounces' => 20, 'Opened' => 20, 'Unique Clicks' => 0, - 'Unsubscribers' => 20 + 'Unsubscribers' => 20, ); $this->checkArrayEquals($expectedResult, $result['values'][$mail['id']]); } @@ -461,7 +461,7 @@ SELECT event_queue_id, time_stamp FROM mail_{$type}_temp"; $createResult = $this->callAPISuccess('mailing', 'create', $createParams, __FUNCTION__, __FILE__); $this->assertTrue(is_numeric($createResult['id'])); $this->assertDBQuery(0, 'SELECT count(*) FROM civicrm_mailing_job WHERE mailing_id = %1', array( - 1 => array($createResult['id'], 'Integer') + 1 => array($createResult['id'], 'Integer'), )); return $createResult['id']; } diff --git a/tests/phpunit/api/v3/MembershipTest.php b/tests/phpunit/api/v3/MembershipTest.php index 113154c2e6..0a1089266f 100644 --- a/tests/phpunit/api/v3/MembershipTest.php +++ b/tests/phpunit/api/v3/MembershipTest.php @@ -60,7 +60,7 @@ class api_v3_MembershipTest extends CiviUnitTestCase { $this->_membershipTypeID2 = $this->membershipTypeCreate(array( 'period_type' => 'fixed', 'fixed_period_start_day' => '301', - 'fixed_period_rollover_day' => '1111' + 'fixed_period_rollover_day' => '1111', )); $this->_membershipStatusID = $this->membershipStatusCreate('test status'); @@ -103,7 +103,7 @@ class api_v3_MembershipTest extends CiviUnitTestCase { $membershipID = $this->contactMembershipCreate($this->_params); $this->assertDBRowExist('CRM_Member_DAO_Membership', $membershipID); $params = array( - 'id' => $membershipID + 'id' => $membershipID, ); $this->callAPIAndDocument('membership', 'delete', $params, __FUNCTION__, __FILE__); $this->assertDBRowNotExist('CRM_Member_DAO_Membership', $membershipID); @@ -678,7 +678,7 @@ class api_v3_MembershipTest extends CiviUnitTestCase { $result = $this->callAPIAndDocument($this->_entity, 'create', $params, __FUNCTION__, __FILE__); $check = $this->callAPISuccess($this->_entity, 'get', array( 'id' => $result['id'], - 'contact_id' => $this->_contactID + 'contact_id' => $this->_contactID, )); $this->assertEquals("custom string", $check['values'][$result['id']]['custom_' . $ids['custom_field_id']], ' in line ' . __LINE__); } @@ -814,11 +814,11 @@ class api_v3_MembershipTest extends CiviUnitTestCase { $result = $this->callAPIAndDocument($this->_entity, 'create', $params, __FUNCTION__, __FILE__); $result = $this->callAPISuccess($this->_entity, 'create', array( 'id' => $result['id'], - 'custom_' . $ids['custom_field_id'] => "new custom" + 'custom_' . $ids['custom_field_id'] => "new custom", )); $check = $this->callAPISuccess($this->_entity, 'get', array( 'id' => $result['id'], - 'contact_id' => $this->_contactID + 'contact_id' => $this->_contactID, )); $this->assertEquals("new custom", $check['values'][$result['id']]['custom_' . $ids['custom_field_id']], ' in line ' . __LINE__); diff --git a/tests/phpunit/api/v3/MessageTemplateTest.php b/tests/phpunit/api/v3/MessageTemplateTest.php index 0371baee23..d67d68d5c4 100644 --- a/tests/phpunit/api/v3/MessageTemplateTest.php +++ b/tests/phpunit/api/v3/MessageTemplateTest.php @@ -83,7 +83,7 @@ class api_v3_MessageTemplateTest extends CiviUnitTestCase { $entity = $this->createTestEntity(); $result = $this->callAPIAndDocument('MessageTemplate', 'delete', array('id' => $entity['id']), __FUNCTION__, __FILE__); $checkDeleted = $this->callAPISuccess($this->entity, 'get', array( - 'id' => $entity['id'] + 'id' => $entity['id'], )); $this->assertEquals(0, $checkDeleted['count'], 'In line ' . __LINE__); } diff --git a/tests/phpunit/api/v3/OptionValueTest.php b/tests/phpunit/api/v3/OptionValueTest.php index 71c42ce2a0..99b42b6f7b 100644 --- a/tests/phpunit/api/v3/OptionValueTest.php +++ b/tests/phpunit/api/v3/OptionValueTest.php @@ -198,7 +198,7 @@ class api_v3_OptionValueTest extends CiviUnitTestCase { 'sequential' => 1, 'api.option_value.create' => array( 'component_id' => 'CiviContribute', - 'name' => 'my@y.com' + 'name' => 'my@y.com', ), )); @@ -220,7 +220,7 @@ class api_v3_OptionValueTest extends CiviUnitTestCase { 'sequential' => 1, 'api.option_value.create' => array( 'component_id' => 'CiviContribute', - 'name' => 'my@y.com' + 'name' => 'my@y.com', ), )); @@ -329,7 +329,7 @@ class api_v3_OptionValueTest extends CiviUnitTestCase { // create a option group $og = $this->callAPISuccess('option_group', 'create', array( 'name' => 'our test Option Group for with group id', - 'is_active' => 1 + 'is_active' => 1, )); // create a option value $ov = $this->callAPISuccess('option_value', 'create', @@ -339,7 +339,7 @@ class api_v3_OptionValueTest extends CiviUnitTestCase { $this->callAPISuccess('option_value', 'create', array( 'id' => $ov['id'], 'option_group_id' => $og['id'], - 'is_active' => 0 + 'is_active' => 0, )); $val = $this->callAPISuccess('option_value', 'getvalue', array( 'id' => $ov['id'], diff --git a/tests/phpunit/api/v3/ParticipantTest.php b/tests/phpunit/api/v3/ParticipantTest.php index 763cee2fe3..bbac928a8e 100644 --- a/tests/phpunit/api/v3/ParticipantTest.php +++ b/tests/phpunit/api/v3/ParticipantTest.php @@ -80,7 +80,7 @@ class api_v3_ParticipantTest extends CiviUnitTestCase { public function tearDown() { $this->eventDelete($this->_eventID); $tablesToTruncate = array( - 'civicrm_custom_group', 'civicrm_custom_field', 'civicrm_contact', 'civicrm_participant' + 'civicrm_custom_group', 'civicrm_custom_field', 'civicrm_contact', 'civicrm_participant', ); // true tells quickCleanup to drop any tables that might have been created in the test $this->quickCleanup($tablesToTruncate, TRUE); @@ -138,7 +138,7 @@ class api_v3_ParticipantTest extends CiviUnitTestCase { 'event_id', 'participant_register_date', 'participant_source', - ) + ), ); $result = $this->callAPISuccess('participant', 'get', $params); $this->assertAPISuccess($result, " in line " . __LINE__); @@ -199,7 +199,7 @@ class api_v3_ParticipantTest extends CiviUnitTestCase { 'contact_id' => $this->_contactID, 'return.status_id' => 1, 'return.participant_status_id' => 1, - 'options' => array('limit' => 1) + 'options' => array('limit' => 1), ); $result = $this->callAPISuccess('participant', 'get', $params); $this->assertArrayHasKey('participant_status_id', $result['values'][$result['id']]); @@ -513,7 +513,7 @@ class api_v3_ParticipantTest extends CiviUnitTestCase { public function testUpdate() { $participantId = $this->participantCreate(array( 'contactID' => $this->_individualId, - 'eventID' => $this->_eventID + 'eventID' => $this->_eventID, )); $params = array( 'id' => $participantId, diff --git a/tests/phpunit/api/v3/PledgeTest.php b/tests/phpunit/api/v3/PledgeTest.php index 52fba65141..8247b5735c 100644 --- a/tests/phpunit/api/v3/PledgeTest.php +++ b/tests/phpunit/api/v3/PledgeTest.php @@ -317,7 +317,7 @@ class api_v3_PledgeTest extends CiviUnitTestCase { //ensure that correct number of payments created & last payment has the right date $payments = $this->callAPISuccess('PledgePayment', 'Get', array( 'pledge_id' => $pledge['id'], - 'sequential' => 1 + 'sequential' => 1, )); $this->assertEquals(1, $payments['count'], 'In line ' . __LINE__); $this->assertEquals(2, $payments['values'][0]['status_id'], 'In line ' . __LINE__); diff --git a/tests/phpunit/api/v3/PriceFieldValueTest.php b/tests/phpunit/api/v3/PriceFieldValueTest.php index fdb2f19306..00ea139c18 100644 --- a/tests/phpunit/api/v3/PriceFieldValueTest.php +++ b/tests/phpunit/api/v3/PriceFieldValueTest.php @@ -73,7 +73,7 @@ class api_v3_PriceFieldValueTest extends CiviUnitTestCase { 'price_field_id' => $this->priceFieldID, 'name' => 'ryegrass', 'label' => 'juicy and healthy', - 'amount' => 1 + 'amount' => 1, ); $membershipOrgId = $this->organizationCreate(NULL); diff --git a/tests/phpunit/api/v3/ProfileTest.php b/tests/phpunit/api/v3/ProfileTest.php index 89f49bc1e9..4a52af2554 100644 --- a/tests/phpunit/api/v3/ProfileTest.php +++ b/tests/phpunit/api/v3/ProfileTest.php @@ -859,7 +859,7 @@ class api_v3_ProfileTest extends CiviUnitTestCase { 'field_type' => 'Contact', 'location_type_id' => 1, 'phone_type_id' => 1, - 'label' => 'Phone' + 'label' => 'Phone', ), array( 'field_name' => 'country', @@ -867,7 +867,7 @@ class api_v3_ProfileTest extends CiviUnitTestCase { 'visibility' => 'Public Pages and Listings', 'field_type' => 'Contact', 'location_type_id' => 1, - 'label' => 'Country' + 'label' => 'Country', ), array( 'field_name' => 'state_province', @@ -875,14 +875,14 @@ class api_v3_ProfileTest extends CiviUnitTestCase { 'visibility' => 'Public Pages and Listings', 'field_type' => 'Contact', 'location_type_id' => 1, - 'label' => 'State Province' + 'label' => 'State Province', ), array( 'field_name' => 'postal_code', 'is_required' => 0, 'field_type' => 'Contact', 'location_type_id' => 1, - 'label' => 'State Province' + 'label' => 'State Province', ), ), ); diff --git a/tests/phpunit/api/v3/RelationshipTest.php b/tests/phpunit/api/v3/RelationshipTest.php index dc7c1e85b2..fe4c6d56c8 100644 --- a/tests/phpunit/api/v3/RelationshipTest.php +++ b/tests/phpunit/api/v3/RelationshipTest.php @@ -55,7 +55,7 @@ class api_v3_RelationshipTest extends CiviUnitTestCase { $this->_cId_a_2 = $this->individualCreate(array( 'last_name' => 'c2', 'email' => 'c@w.com', - 'contact_type' => 'Individual' + 'contact_type' => 'Individual', )); $this->_cId_b = $this->organizationCreate(); $this->_cId_b2 = $this->organizationCreate(array('organization_name' => ' Org 2')); @@ -693,7 +693,7 @@ class api_v3_RelationshipTest extends CiviUnitTestCase { $rel1 = $this->callAPISuccess('relationship', 'create', $this->_params); $getParams = array( - 'filters' => array('is_current' => 1) + 'filters' => array('is_current' => 1), ); $description = "demonstrates is_current filter"; $subfile = 'filterIsCurrent'; @@ -762,7 +762,7 @@ class api_v3_RelationshipTest extends CiviUnitTestCase { array('relationship_type_id' => $relationType4))); $getParams = array( - 'relationship_type_id' => array('IN' => array($relationType2, $relationType3)) + 'relationship_type_id' => array('IN' => array($relationType2, $relationType3)), ); $description = "demonstrates use of IN filter"; @@ -775,7 +775,7 @@ class api_v3_RelationshipTest extends CiviUnitTestCase { $description = "demonstrates use of NOT IN filter"; $subfile = 'NotInRelationshipType'; $getParams = array( - 'relationship_type_id' => array('NOT IN' => array($relationType2, $relationType3)) + 'relationship_type_id' => array('NOT IN' => array($relationType2, $relationType3)), ); $result = $this->callAPIAndDocument('relationship', 'get', $getParams, __FUNCTION__, __FILE__, $description, $subfile); $this->assertEquals($result['count'], 2); @@ -784,7 +784,7 @@ class api_v3_RelationshipTest extends CiviUnitTestCase { $description = "demonstrates use of BETWEEN filter"; $subfile = 'BetweenRelationshipType'; $getParams = array( - 'relationship_type_id' => array('BETWEEN' => array($relationType2, $relationType4)) + 'relationship_type_id' => array('BETWEEN' => array($relationType2, $relationType4)), ); $result = $this->callAPIAndDocument('relationship', 'get', $getParams, __FUNCTION__, __FILE__, $description, $subfile); $this->assertEquals($result['count'], 3); @@ -793,7 +793,7 @@ class api_v3_RelationshipTest extends CiviUnitTestCase { $description = "demonstrates use of Not BETWEEN filter"; $subfile = 'NotBetweenRelationshipType'; $getParams = array( - 'relationship_type_id' => array('NOT BETWEEN' => array($relationType2, $relationType4)) + 'relationship_type_id' => array('NOT BETWEEN' => array($relationType2, $relationType4)), ); $result = $this->callAPIAndDocument('relationship', 'get', $getParams, __FUNCTION__, __FILE__, $description, $subfile); $this->assertEquals($result['count'], 1); @@ -936,7 +936,7 @@ class api_v3_RelationshipTest extends CiviUnitTestCase { $this->callAPISuccess($this->_entity, 'create', array_merge($this->_params, array( 'relationship_type_id' => $relType2, - 'contact_id_b' => $this->_cId_b2 + 'contact_id_b' => $this->_cId_b2, )) ); @@ -944,7 +944,7 @@ class api_v3_RelationshipTest extends CiviUnitTestCase { $this->callAPISuccess($this->_entity, 'create', array_merge($this->_params, array( 'relationship_type_id' => $relType3, - 'contact_id_b' => $org3 + 'contact_id_b' => $org3, )) ); @@ -976,7 +976,7 @@ class api_v3_RelationshipTest extends CiviUnitTestCase { $this->callAPISuccess($this->_entity, 'create', array_merge($this->_params, array( 'relationship_type_id' => $relType2, - 'contact_id_b' => $this->_cId_b2 + 'contact_id_b' => $this->_cId_b2, )) ); @@ -984,7 +984,7 @@ class api_v3_RelationshipTest extends CiviUnitTestCase { $this->callAPISuccess($this->_entity, 'create', array_merge($this->_params, array( 'relationship_type_id' => $relType3, - 'contact_id_b' => $org3 + 'contact_id_b' => $org3, )) ); @@ -1022,7 +1022,7 @@ class api_v3_RelationshipTest extends CiviUnitTestCase { $this->callAPISuccess($this->_entity, 'create', array_merge($this->_params, array( 'relationship_type_id' => $relType2, - 'contact_id_b' => $this->_cId_b2 + 'contact_id_b' => $this->_cId_b2, )) ); @@ -1030,7 +1030,7 @@ class api_v3_RelationshipTest extends CiviUnitTestCase { $this->callAPISuccess($this->_entity, 'create', array_merge($this->_params, array( 'relationship_type_id' => $relType3, - 'contact_id_b' => $org3 + 'contact_id_b' => $org3, )) ); @@ -1039,7 +1039,7 @@ class api_v3_RelationshipTest extends CiviUnitTestCase { array_merge($this->_params, array( 'relationship_type_id' => $relType1, 'contact_id_a' => $this->_cId_a, - 'contact_id_b' => $this->_cId_a_2 + 'contact_id_b' => $this->_cId_a_2, )) ); @@ -1077,7 +1077,7 @@ class api_v3_RelationshipTest extends CiviUnitTestCase { $this->callAPISuccess($this->_entity, 'create', array_merge($this->_params, array( 'relationship_type_id' => $relType2, - 'contact_id_b' => $this->_cId_b2 + 'contact_id_b' => $this->_cId_b2, )) ); @@ -1085,7 +1085,7 @@ class api_v3_RelationshipTest extends CiviUnitTestCase { $this->callAPISuccess($this->_entity, 'create', array_merge($this->_params, array( 'relationship_type_id' => $relType3, - 'contact_id_b' => $org3 + 'contact_id_b' => $org3, )) ); @@ -1094,7 +1094,7 @@ class api_v3_RelationshipTest extends CiviUnitTestCase { array_merge($this->_params, array( 'relationship_type_id' => $relType1, 'contact_id_a' => $this->_cId_a, - 'contact_id_b' => $this->_cId_a_2 + 'contact_id_b' => $this->_cId_a_2, )) ); diff --git a/tests/phpunit/api/v3/ReportTemplateTest.php b/tests/phpunit/api/v3/ReportTemplateTest.php index dcd5246d4c..659bff5df1 100644 --- a/tests/phpunit/api/v3/ReportTemplateTest.php +++ b/tests/phpunit/api/v3/ReportTemplateTest.php @@ -118,7 +118,7 @@ class api_v3_ReportTemplateTest extends CiviUnitTestCase { $description = "Retrieve rows from a report template (optionally providing the instance_id)"; $result = $this->callAPIAndDocument('report_template', 'getrows', array( 'report_id' => 'contact/summary', - 'options' => array('metadata' => array('labels', 'title')) + 'options' => array('metadata' => array('labels', 'title')), ), __FUNCTION__, __FILE__, $description, 'Getrows', 'getrows'); $this->assertEquals('Contact Name', $result['metadata']['labels']['civicrm_contact_sort_name']); diff --git a/tests/phpunit/api/v3/SettingTest.php b/tests/phpunit/api/v3/SettingTest.php index 5978b26f94..addf0f1452 100644 --- a/tests/phpunit/api/v3/SettingTest.php +++ b/tests/phpunit/api/v3/SettingTest.php @@ -169,7 +169,7 @@ class api_v3_SettingTest extends CiviUnitTestCase { 'description' => NULL, 'help_text' => NULL, 'on_change' => array(// list of callbacks - array(__CLASS__, '_testOnChange_onChangeExample') + array(__CLASS__, '_testOnChange_onChangeExample'), ), ), )); @@ -308,7 +308,7 @@ class api_v3_SettingTest extends CiviUnitTestCase { $params = array( 'domain_id' => 'all', - 'return' => 'uniq_email_per_site' + 'return' => 'uniq_email_per_site', ); // we'll check it with a 'get' $description = "shows getting a variable for all domains"; @@ -411,12 +411,12 @@ class api_v3_SettingTest extends CiviUnitTestCase { public function testGetSetConfigSettingMultipleDomains() { $settings = $this->callAPISuccess('setting', 'create', array( 'defaultCurrency' => 'USD', - 'domain_id' => $this->_currentDomain + 'domain_id' => $this->_currentDomain, ) ); $settings = $this->callAPISuccess('setting', 'create', array( 'defaultCurrency' => 'CAD', - 'domain_id' => $this->_domainID2 + 'domain_id' => $this->_domainID2, ) ); $settings = $this->callAPISuccess('setting', 'get', array( @@ -445,7 +445,7 @@ class api_v3_SettingTest extends CiviUnitTestCase { public function testGetValue() { $params = array( 'name' => 'petition_contacts', - 'group' => 'Campaign Preferences' + 'group' => 'Campaign Preferences', ); $description = "Demonstrates getvalue action - intended for runtime use as better caching than get"; @@ -478,7 +478,7 @@ class api_v3_SettingTest extends CiviUnitTestCase { $result = $this->callAPISuccess('setting', 'create', $params); $this->assertAPISuccess($result, "in line " . __LINE__); $revertParams = array( - 'name' => 'address_format' + 'name' => 'address_format', ); $result = $this->callAPISuccess('setting', 'get', $params); //make sure it's set diff --git a/tests/phpunit/api/v3/SurveyRespondantTest.php b/tests/phpunit/api/v3/SurveyRespondantTest.php index 128e02fa49..61693de8f0 100644 --- a/tests/phpunit/api/v3/SurveyRespondantTest.php +++ b/tests/phpunit/api/v3/SurveyRespondantTest.php @@ -49,7 +49,7 @@ class api_v3_SurveyRespondantTest extends CiviUnitTestCase { $surveyID = $survey['id']; $this->params = array( 'sequential' => '1', - 'survey_id' => $surveyID + 'survey_id' => $surveyID, ); } diff --git a/tests/phpunit/api/v3/SyntaxConformanceTest.php b/tests/phpunit/api/v3/SyntaxConformanceTest.php index c476b2b1fd..791b8d2940 100644 --- a/tests/phpunit/api/v3/SyntaxConformanceTest.php +++ b/tests/phpunit/api/v3/SyntaxConformanceTest.php @@ -106,7 +106,7 @@ class api_v3_SyntaxConformanceTest extends CiviUnitTestCase { $tmp = civicrm_api('Entity', 'Get', array('version' => 3)); if (getenv('SYNTAX_CONFORMANCE_ENTITIES')) { $tmp = array( - 'values' => explode(' ', getenv('SYNTAX_CONFORMANCE_ENTITIES')) + 'values' => explode(' ', getenv('SYNTAX_CONFORMANCE_ENTITIES')), ); } @@ -351,7 +351,7 @@ class api_v3_SyntaxConformanceTest extends CiviUnitTestCase { 'PaymentProcessor', 'Setting', 'MailingContact', - 'SystemLog' //skip this because it doesn't make sense to update logs + 'SystemLog' //skip this because it doesn't make sense to update logs, ); if ($sequential === TRUE) { return $entitiesWithout; @@ -420,7 +420,7 @@ class api_v3_SyntaxConformanceTest extends CiviUnitTestCase { 'state_province_id', //issues with country id - need to ensure same country 'master_id', //creates relationship ), - 'cant_return' => array() + 'cant_return' => array(), ), 'Batch' => array( 'cant_update' => array( @@ -428,19 +428,19 @@ class api_v3_SyntaxConformanceTest extends CiviUnitTestCase { ), 'cant_return' => array( 'entity_table', - ) + ), ), 'CaseType' => array( 'cant_update' => array( 'definition', - ) + ), ), 'MembershipBlock' => array( 'cant_update' => array( // The fake/auto-generated values leave us unable to properly cleanup fake data 'entity_type', 'entity_id', - ) + ), ), 'Pledge' => array( 'cant_update' => array( @@ -448,7 +448,7 @@ class api_v3_SyntaxConformanceTest extends CiviUnitTestCase { 'installments', 'original_installment_amount', 'next_pay_date', - 'amount' // can't be changed through API + 'amount' // can't be changed through API, ), 'break_return' => array(// if these are passed in they are retrieved from the wrong table 'honor_contact_id', @@ -456,7 +456,7 @@ class api_v3_SyntaxConformanceTest extends CiviUnitTestCase { 'contribution_page_id', 'financial_account_id', 'financial_type_id', - 'currency' + 'currency', ), 'cant_return' => array(// can't be retrieved from api 'honor_type_id', //due to uniquename missing @@ -474,7 +474,7 @@ class api_v3_SyntaxConformanceTest extends CiviUnitTestCase { 'pledge_status_id', 'pledge_campaign_id', 'pledge_financial_type_id', - ) + ), ), 'PaymentProcessorType' => array( 'cant_update' => array( @@ -1370,10 +1370,10 @@ class api_v3_SyntaxConformanceTest extends CiviUnitTestCase { $this->assertAPISuccess($createResult); $eventId = $createResult['id']; $this->assertDBQuery('createNew: CiviCRM <> TheRest', 'SELECT title FROM civicrm_event WHERE id = %1', array( - 1 => array($eventId, 'Integer') + 1 => array($eventId, 'Integer'), )); $this->assertDBQuery('createNew: TheRest <> CiviCRM', 'SELECT description FROM civicrm_event WHERE id = %1', array( - 1 => array($eventId, 'Integer') + 1 => array($eventId, 'Integer'), )); // Verify that "create" handles encoding for updates @@ -1385,10 +1385,10 @@ class api_v3_SyntaxConformanceTest extends CiviUnitTestCase { )); $this->assertAPISuccess($createWithIdResult); $this->assertDBQuery('createWithId: CiviCRM <> TheRest', 'SELECT title FROM civicrm_event WHERE id = %1', array( - 1 => array($eventId, 'Integer') + 1 => array($eventId, 'Integer'), )); $this->assertDBQuery('createWithId: TheRest <> CiviCRM', 'SELECT description FROM civicrm_event WHERE id = %1', array( - 1 => array($eventId, 'Integer') + 1 => array($eventId, 'Integer'), )); // Verify that "setvalue" handles encoding for updates @@ -1400,7 +1400,7 @@ class api_v3_SyntaxConformanceTest extends CiviUnitTestCase { )); $this->assertAPISuccess($setValueTitleResult); $this->assertDBQuery('setValueTitle: CiviCRM <> TheRest', 'SELECT title FROM civicrm_event WHERE id = %1', array( - 1 => array($eventId, 'Integer') + 1 => array($eventId, 'Integer'), )); $setValueDescriptionResult = civicrm_api('Event', 'setvalue', array( 'version' => 3, @@ -1411,7 +1411,7 @@ class api_v3_SyntaxConformanceTest extends CiviUnitTestCase { //$this->assertTrue((bool)$setValueDescriptionResult['is_error']); // not supported by setValue $this->assertAPISuccess($setValueDescriptionResult); $this->assertDBQuery('setValueDescription: TheRest <> CiviCRM', 'SELECT description FROM civicrm_event WHERE id = %1', array( - 1 => array($eventId, 'Integer') + 1 => array($eventId, 'Integer'), )); } } diff --git a/tests/phpunit/api/v3/SystemTest.php b/tests/phpunit/api/v3/SystemTest.php index ba084d1743..ec6e258f14 100644 --- a/tests/phpunit/api/v3/SystemTest.php +++ b/tests/phpunit/api/v3/SystemTest.php @@ -77,7 +77,7 @@ class api_v3_SystemTest extends CiviUnitTestCase { $this->callAPISuccess('system', 'log', array('level' => 'info', 'message' => 'We wish you a merry Christmas')); $result = $this->callAPISuccess('SystemLog', 'getsingle', array( 'sequential' => 1, - 'message' => array('LIKE' => '%Chris%') + 'message' => array('LIKE' => '%Chris%'), )); $this->assertEquals($result['message'], 'We wish you a merry Christmas'); $this->assertEquals($result['level'], 'info'); @@ -90,7 +90,7 @@ class api_v3_SystemTest extends CiviUnitTestCase { $this->callAPISuccess('system', 'log', array('message' => 'We wish you a merry Christmas', 'level' => 'alert')); $result = $this->callAPISuccess('SystemLog', 'getsingle', array( 'sequential' => 1, - 'message' => array('LIKE' => '%Chris%') + 'message' => array('LIKE' => '%Chris%'), )); $this->assertEquals($result['message'], 'We wish you a merry Christmas'); $this->assertEquals($result['level'], 'alert'); diff --git a/tests/phpunit/api/v3/TagTest.php b/tests/phpunit/api/v3/TagTest.php index 58fd439b83..b78b445ae2 100644 --- a/tests/phpunit/api/v3/TagTest.php +++ b/tests/phpunit/api/v3/TagTest.php @@ -193,7 +193,7 @@ class api_v3_TagTest extends CiviUnitTestCase { $description = "Demonstrates use of api.getlist for autocomplete and quicksearch applications"; $params = array( 'input' => $this->tag['name'], - 'extra' => array('used_for') + 'extra' => array('used_for'), ); $result = $this->callAPIAndDocument('tag', 'getlist', $params, __FUNCTION__, __FILE__, $description); $this->assertEquals($this->tag['id'], $result['values'][0]['id'], 'In line ' . __LINE__); diff --git a/tests/phpunit/api/v3/TaxContributionPageTest.php b/tests/phpunit/api/v3/TaxContributionPageTest.php index c8737c11c0..8752a257ba 100644 --- a/tests/phpunit/api/v3/TaxContributionPageTest.php +++ b/tests/phpunit/api/v3/TaxContributionPageTest.php @@ -67,7 +67,7 @@ class api_v3_TaxContributionPageTest extends CiviUnitTestCase { 'pay_later_text' => 'I will pay later', 'pay_later_receipt' => "I will pay later", 'is_monetary' => TRUE, - 'is_billing_required' => TRUE + 'is_billing_required' => TRUE, ); $this->_priceSetParams = array( @@ -79,7 +79,7 @@ class api_v3_TaxContributionPageTest extends CiviUnitTestCase { 'extends' => 2, 'financial_type_id' => 3, 'is_quick_config' => 0, - 'is_reserved' => 0 + 'is_reserved' => 0, ); // Financial Account with 20% tax rate $financialAccountSetparams = array( @@ -109,7 +109,7 @@ class api_v3_TaxContributionPageTest extends CiviUnitTestCase { 'entity_table' => 'civicrm_financial_type', 'entity_id' => $this->financialtypeID, 'account_relationship' => 10, - 'financial_account_id' => $this->financialAccountId + 'financial_account_id' => $this->financialAccountId, ); $financialRelation = CRM_Financial_BAO_FinancialTypeAccount::add($financialRelationParams); @@ -122,7 +122,7 @@ class api_v3_TaxContributionPageTest extends CiviUnitTestCase { 'tax_rate' => 5.00, 'is_reserved' => 0, 'is_active' => 1, - 'is_default' => 0 + 'is_default' => 0, ); $halfFinancialAccount = CRM_Financial_BAO_FinancialAccount::add($financialAccHalftax); $this->halfFinancialAccId = $halfFinancialAccount->id; @@ -138,7 +138,7 @@ class api_v3_TaxContributionPageTest extends CiviUnitTestCase { 'entity_table' => 'civicrm_financial_type', 'entity_id' => $this->halfFinancialTypeId, 'account_relationship' => 10, - 'financial_account_id' => $this->halfFinancialAccId + 'financial_account_id' => $this->halfFinancialAccId, ); $halfFinancialRelation = CRM_Financial_BAO_FinancialTypeAccount::add($financialRelationHalftax); @@ -172,7 +172,7 @@ class api_v3_TaxContributionPageTest extends CiviUnitTestCase { 'class_name' => 'Payment_Dummy', 'billing_mode' => 1, 'is_recur' => 1, - 'payment_type' => 1 + 'payment_type' => 1, ); $result = $this->callAPISuccess('payment_processor', 'create', $paymentProceParams); $this->_ids['paymentProcessID'] = $result['id']; @@ -195,7 +195,7 @@ class api_v3_TaxContributionPageTest extends CiviUnitTestCase { 'civicrm_contact', 'civicrm_membership', 'civicrm_membership_payment', - 'civicrm_payment_processor' + 'civicrm_payment_processor', )); CRM_Core_PseudoConstant::flush('taxRates'); } @@ -223,14 +223,14 @@ class api_v3_TaxContributionPageTest extends CiviUnitTestCase { 'price_field_id' => $priceField['id'], 'label' => 'Long Haired Goat', 'amount' => 100, - 'financial_type_id' => $this->financialtypeID + 'financial_type_id' => $this->financialtypeID, )); $priceFieldValue = $this->callAPISuccess('price_field_value', 'create', array( 'price_set_id' => $priceSetID, 'price_field_id' => $priceField['id'], 'label' => 'Shoe-eating Goat', 'amount' => 300, - 'financial_type_id' => $this->halfFinancialTypeId + 'financial_type_id' => $this->halfFinancialTypeId, )); $this->_ids['price_field_value'] = array($priceFieldValue['id']); } @@ -252,7 +252,7 @@ class api_v3_TaxContributionPageTest extends CiviUnitTestCase { 'trxn_id' => 12345, 'invoice_id' => 67890, 'source' => 'SSF', - 'contribution_status_id' => 1 + 'contribution_status_id' => 1, ); $contribution = $this->callAPIAndDocument('contribution', 'create', $params, __FUNCTION__, __FILE__); @@ -389,7 +389,7 @@ class api_v3_TaxContributionPageTest extends CiviUnitTestCase { $newParams = array( 'id' => $contribution['id'], 'financial_type_id' => 1, // without tax rate i.e Donation - 'total_amount' => '300' + 'total_amount' => '300', ); $contribution = $this->callAPISuccess('contribution', 'update', $newParams); diff --git a/tests/phpunit/api/v3/UFGroupTest.php b/tests/phpunit/api/v3/UFGroupTest.php index 13f876f907..a611172006 100644 --- a/tests/phpunit/api/v3/UFGroupTest.php +++ b/tests/phpunit/api/v3/UFGroupTest.php @@ -104,7 +104,7 @@ class api_v3_UFGroupTest extends CiviUnitTestCase { 'title' => 'Edited Test Profile', 'help_post' => 'Profile Pro help text.', 'is_active' => 1, - 'id' => $this->_ufGroupId + 'id' => $this->_ufGroupId, ); $result = $this->callAPISuccess('uf_group', 'create', $params); diff --git a/tests/phpunit/api/v3/UtilsTest.php b/tests/phpunit/api/v3/UtilsTest.php index 48ce8686fa..a4fa635039 100644 --- a/tests/phpunit/api/v3/UtilsTest.php +++ b/tests/phpunit/api/v3/UtilsTest.php @@ -140,7 +140,7 @@ class api_v3_UtilsTest extends CiviUnitTestCase { 'contact_id' => $this->_contactID, 'modified_date' => '2011-01-31', 'subject' => NULL, - 'version' => $this->_apiversion + 'version' => $this->_apiversion, ); try { $result = civicrm_api3_verify_mandatory($params, 'CRM_Core_BAO_Note', array('note', 'subject')); diff --git a/tests/phpunit/api/v3/WebsiteTest.php b/tests/phpunit/api/v3/WebsiteTest.php index 9c96449dd6..765decd696 100644 --- a/tests/phpunit/api/v3/WebsiteTest.php +++ b/tests/phpunit/api/v3/WebsiteTest.php @@ -91,7 +91,7 @@ class api_v3_WebsiteTest extends CiviUnitTestCase { public function testGetMetadata() { $result = $this->callAPIAndDocument($this->_entity, 'get', array( 'options' => array( - 'metadata' => array('fields') + 'metadata' => array('fields'), )), __FUNCTION__, __FILE__, 'Demonostrates returning field metadata', 'GetWithMetadata'); $this->assertEquals('Website', $result['metadata']['fields']['url']['title']); } diff --git a/tests/qunit/crm-translate/test.php b/tests/qunit/crm-translate/test.php index db27384f1f..d176059369 100644 --- a/tests/qunit/crm-translate/test.php +++ b/tests/qunit/crm-translate/test.php @@ -1,6 +1,6 @@ addSetting(array( - 'strings' => array('One, two, three' => 'Un, deux, trois') + 'strings' => array('One, two, three' => 'Un, deux, trois'), ) ); // CRM_Core_Resources::singleton()->addScriptFile(...);