AND {$t['GroupContact']}.status = 'Added')";
/* Query for permissions granted through an ACL group to a Contact
- * group */
+ * group */
$query[] = "SELECT {$t['ACL']}.*, 0 as override
FROM {$t['ACL']}
while ($dao->fetch()) {
/* Instant bypass for the following cases:
- * 1) the rule governs all tables
- * 2) the rule governs all objects in the table in question
- * 3) the rule governs the specific object we want
- */
+ * 1) the rule governs all tables
+ * 2) the rule governs all objects in the table in question
+ * 3) the rule governs the specific object we want
+ */
if (empty($dao->object_table) ||
($dao->object_table == $object_table
);
/* If the clause returned is null, then the rule is a blanket
- * (id is null) on a table other than the one we're interested
- * in. So skip it. */
+ * (id is null) on a table other than the one we're interested
+ * in. So skip it. */
if (empty($clause)) {
continue;
}
/* Now we figure out if this is an allow or deny rule, and possibly
- * a contact-level override */
+ * a contact-level override */
if ($dao->deny) {
$deny[] = $clause;
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
// Activity date time assumes midnight at the beginning of the date
// This sets it to almost midnight at the end of the date
/* if ($dateHigh <= 99999999) {
- $dateHigh = 1000000 * $dateHigh + 235959;
+ $dateHigh = 1000000 * $dateHigh + 235959;
} */
$dateHigh = date('m/d/Y', strtotime($dateHigh));
$this->_formValues['activity_date_relative'] = 0;
if ($returnCode & self::DUPLICATE) {
if ($returnCode & self::MULTIPLE_DUPE) {
/* TODO: multi-dupes should be counted apart from singles
- * on non-skip action */
+ * on non-skip action */
}
$this->_duplicateCount++;
$recordNumber = $this->_lineCount;
// currently we support only mailing label creation, hence comment below code
/*
$options = array(
- 'label_format' => ts('Mailing Label'),
- 'name_badge' => ts('Name Badge'),
+ 'label_format' => ts('Mailing Label'),
+ 'name_badge' => ts('Name Badge'),
);
$labelType = $this->addRadio('label_type', ts('Used For'), $options, null, ' ');
if ($this->_action != CRM_Core_Action::ADD) {
- $labelType->freeze();
+ $labelType->freeze();
}
- */
+ */
$this->add('select', 'paper_size', ts('Sheet Size'),
array(
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
class CRM_Campaign_Form_Survey_Main extends CRM_Campaign_Form_Survey {
/* values
- *
- * @var array
- */
+ *
+ * @var array
+ */
public $_values;
protected $_reportTitle;
/* values
- *
- * @var array
- */
+ *
+ * @var array
+ */
public $_values;
const NUM_OPTION = 11;
// send thank you or email verification emails
/*
- * sendEmailMode
- * 1 = connected user via login/pwd - thank you
- * or dedupe contact matched who doesn't have a tag CIVICRM_TAG_UNCONFIRMED - thank you
- * login using fb connect - thank you + click to add msg to fb wall
- * 2 = send a confirmation request email
- */
+ * sendEmailMode
+ * 1 = connected user via login/pwd - thank you
+ * or dedupe contact matched who doesn't have a tag CIVICRM_TAG_UNCONFIRMED - thank you
+ * login using fb connect - thank you + click to add msg to fb wall
+ * 2 = send a confirmation request email
+ */
return parent::run();
}
$fh = fopen('C:/temp/audit2.xml', 'w');
fwrite($fh, $xmlString);
fclose($fh);
- */
+ */
$audit = new CRM_Case_Audit_Audit($xmlString, 'audit.conf.xml');
$activities = $audit->getActivities($printReport);
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing
+--------------------------------------------------------------------+
-*/
+ */
/**
*
$this->defaults = array();
/*
- * we allow the controller to set force/reset externally, useful when we are being
- * driven by the wizard framework
- */
+ * we allow the controller to set force/reset externally, useful when we are being
+ * driven by the wizard framework
+ */
$this->_reset = CRM_Utils_Request::retrieve('reset', 'Boolean', CRM_Core_DAO::$_nullObject);
$this->_force = CRM_Utils_Request::retrieve('force', 'Boolean', $this, FALSE);
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
}
else {
/* if we get here, it could be because we're out of siblings
- * (in which case we return null) or because we're at the
- * top level groups which do not have parents but may still
- * have siblings, so check for that first.
- */
+ * (in which case we return null) or because we're at the
+ * top level groups which do not have parents but may still
+ * have siblings, so check for that first.
+ */
$nextGroup = $this->_getNextParentlessGroup($group);
if ($nextGroup) {
$parentGroupId = $dao->parent_group_id;
if ($parentGroupId == $checkGroupId) {
/* print "One of these: <pre>";
- print_r($groupIds);
- print "</pre> has groupId $checkGroupId as an ancestor.<br/>"; */
+ print_r($groupIds);
+ print "</pre> has groupId $checkGroupId as an ancestor.<br/>"; */
return TRUE;
}
$childGroupId = $dao->child_group_id;
if ($childGroupId == $checkGroupId) {
/* print "One of these: <pre>";
- print_r($groupIds);
- print "</pre> has groupId $checkGroupId as a descendent.<br/><br/>"; */
+ print_r($groupIds);
+ print "</pre> has groupId $checkGroupId as a descendent.<br/><br/>"; */
return TRUE;
}
$parentGroupId = $dao->parent_group_id;
if ($parentGroupId == $checkGroupId) {
/* print "One of these: <pre>";
- print_r($groupIds);
- print "</pre> has groupId $checkGroupId as an ancestor.<br/>"; */
+ print_r($groupIds);
+ print "</pre> has groupId $checkGroupId as an ancestor.<br/>"; */
return TRUE;
}
$childGroupId = $dao->child_group_id;
if ($childGroupId == $checkGroupId) {
/* print "One of these: <pre>";
- print_r($groupIds);
- print "</pre> has groupId $checkGroupId as a descendent.<br/><br/>"; */
+ print_r($groupIds);
+ print "</pre> has groupId $checkGroupId as a descendent.<br/><br/>"; */
return TRUE;
}
WHERE relationship_type_id = " . CRM_Utils_Type::escape($type, 'Integer');
/*
- * CRM-11792 - date fields from API are in ISO format, but this function
- * supports date arrays BAO has increasingly standardised to ISO format
- * so I believe this function should support ISO rather than make API
- * format it - however, need to support array format for now to avoid breakage
- * @ time of writing this function is called from Relationship::createMultiple (twice)
- * CRM_BAO_Contact_Utils::clearCurrentEmployer (seemingly without dates)
- * CRM_Contact_Form_Task_AddToOrganization::postProcess &
- * CRM_Contact_Form_Task_AddToHousehold::postProcess
- * (I don't think the last 2 support dates but not sure
- */
+ * CRM-11792 - date fields from API are in ISO format, but this function
+ * supports date arrays BAO has increasingly standardised to ISO format
+ * so I believe this function should support ISO rather than make API
+ * format it - however, need to support array format for now to avoid breakage
+ * @ time of writing this function is called from Relationship::createMultiple (twice)
+ * CRM_BAO_Contact_Utils::clearCurrentEmployer (seemingly without dates)
+ * CRM_Contact_Form_Task_AddToOrganization::postProcess &
+ * CRM_Contact_Form_Task_AddToHousehold::postProcess
+ * (I don't think the last 2 support dates but not sure
+ */
$dateFields = array('end_date', 'start_date');
foreach ($dateFields as $dateField) {
public function __destruct() {
/*
- if ( $this->_eventID ) {
- $sql = "DROP TEMPORARY TABLE {$this->_tableName}";
- CRM_Core_DAO::executeQuery( $sql );
- }
- */
+ if ( $this->_eventID ) {
+ $sql = "DROP TEMPORARY TABLE {$this->_tableName}";
+ CRM_Core_DAO::executeQuery( $sql );
+ }
+ */
}
public function buildTempTable() {
}
/*
- * WHERE clause is an array built from any required JOINS plus conditional filters based on search criteria field values
- *
- */
+ * WHERE clause is an array built from any required JOINS plus conditional filters based on search criteria field values
+ *
+ */
/**
* @param bool $includeContactIDs
*
*/
private function _prepareImportTable($db, $importTableName) {
/* TODO: Add a check for an existing _status field;
- * if it exists, create __status instead and return that
- */
+ * if it exists, create __status instead and return that
+ */
$statusFieldName = '_status';
$primaryKeyName = '_id';
$this->set('statusFieldName', $statusFieldName);
/* Make sure the PK is always last! We rely on this later.
- * Should probably stop doing that at some point, but it
- * would require moving to associative arrays rather than
- * relying on numerical order of the fields. This could in
- * turn complicate matters for some DataSources, which
- * would also not be good. Decisions, decisions...
- */
+ * Should probably stop doing that at some point, but it
+ * would require moving to associative arrays rather than
+ * relying on numerical order of the fields. This could in
+ * turn complicate matters for some DataSources, which
+ * would also not be good. Decisions, decisions...
+ */
$alterQuery = "ALTER TABLE $importTableName
ADD COLUMN $statusFieldName VARCHAR(32)
if ($returnCode & self::DUPLICATE) {
if ($returnCode & self::MULTIPLE_DUPE) {
/* TODO: multi-dupes should be counted apart from singles
- * on non-skip action */
+ * on non-skip action */
}
$this->_duplicateCount++;
array_unshift($values, $this->_rowCount);
// see if we've hit our timeout yet
/* if ( $the_thing_with_the_stuff ) {
- do_something( );
- } */
+ do_something( );
+ } */
}
if ($mode == self::MODE_PREVIEW || $mode == self::MODE_IMPORT) {
$action = array_sum(array_keys($this->links()));
$links = self::links();
/* if ($dao->is_default) {
- unset($links[CRM_Core_Action::MAP]);
- unset($links[CRM_Core_Action::DELETE]);
- }*/
+ unset($links[CRM_Core_Action::MAP]);
+ unset($links[CRM_Core_Action::DELETE]);
+ }*/
if ($dao->is_reserved) {
unset($links[CRM_Core_Action::DELETE]);
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
$retValue = $value;
break;
}
- // note that if its not text / textarea, the code falls thru and executes
- // the below case also
+ // note that if its not text / textarea, the code falls thru and executes
+ // the below case also
case 'StateProvince':
case 'Country':
$options = array();
$email->email = $strtolower($email->email);
/*
- * since we're setting bulkmail for 1 of this contact's emails, first reset all their other emails to is_bulkmail false
- * We shouldn't not set the current email to false even though we
- * are about to reset it to avoid contaminating the changelog if logging is enabled
- * (only 1 email address can have is_bulkmail = true)
- */
+ * since we're setting bulkmail for 1 of this contact's emails, first reset all their other emails to is_bulkmail false
+ * We shouldn't not set the current email to false even though we
+ * are about to reset it to avoid contaminating the changelog if logging is enabled
+ * (only 1 email address can have is_bulkmail = true)
+ */
if ($email->is_bulkmail != 'null' && $params['contact_id'] && !self::isMultipleBulkMail()) {
$sql = "
UPDATE civicrm_email
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
CRM_Core_Transaction::addCallback(
CRM_Core_Transaction::PHASE_POST_COMMIT,
function () {
- CRM_Core_ManagedEntities::singleton(TRUE)->reconcile();
+ CRM_Core_ManagedEntities::singleton(TRUE)->reconcile();
},
array(),
'ManagedEntities::reconcile'
$fieldValues = array('option_group_id' => $optionGroupID);
// use the next available value
/* CONVERT(value, DECIMAL) is used to convert varchar
- field 'value' to decimal->integer */
+ field 'value' to decimal->integer */
$params['value'] = (int) CRM_Utils_Weight::getDefaultWeight('CRM_Core_DAO_OptionValue',
$fieldValues,
| |
| Written & Contributed by Eileen McNaughton - Nov March 2008 |
+----------------------------------------------------------------------------+
-*/
+ */
/**
* -----------------------------------------------------------------------------------------------
| |
| |
+--------------------------------------------------------------------+
-*/
+ */
/**
* Note that in order to use FirstData / LinkPoint you need a certificate (.pem) file issued by them
*/
public function mapProcessorFieldstoParams($params) {
/*concatenate full customer name first - code from EWAY gateway
- */
+ */
$credit_card_name = $params['first_name'] . " ";
if (strlen($params['middle_name']) > 0) {
$requestxml = lphp::buildXML($requestFields);
/*----------------------------------------------------------------------------------------------------
- // Send to the payment information using cURL
- /----------------------------------------------------------------------------------------------------
- */
+ // Send to the payment information using cURL
+ /----------------------------------------------------------------------------------------------------
+ */
$ch = curl_init($host);
if (!$ch) {
}
else {
/* Since trxn_id hasn't got any use here,
- * lets make use of it by passing the eventID/membershipTypeID to next level.
- * And change trxn_id to google-order-number before finishing db update */
+ * lets make use of it by passing the eventID/membershipTypeID to next level.
+ * And change trxn_id to google-order-number before finishing db update */
if (!empty($ids['event'])) {
$contribution->trxn_id = $ids['event'] . CRM_Core_DAO::VALUE_SEPARATOR . $ids['participant'];
return self::error('Invalid currency selection, must be $CAD');
}
/* unused params: cvv not yet implemented, payment action ingored (should test for 'Sale' value?)
- [cvv2] => 000
- [ip_address] => 192.168.0.103
- [payment_action] => Sale
- [contact_type] => Individual
- [geo_coord_id] => 1 */
+ [cvv2] => 000
+ [ip_address] => 192.168.0.103
+ [payment_action] => Sale
+ [contact_type] => Individual
+ [geo_coord_id] => 1 */
//this code based on Moneris example code #
//create an mpgCustInfo object
$subscriptionPaymentStatus = NULL;
//List of Transaction Type
/*
- recurring_payment_profile_created RP Profile Created
- recurring_payment RP Sucessful Payment
- recurring_payment_failed RP Failed Payment
- recurring_payment_profile_cancel RP Profile Cancelled
- recurring_payment_expired RP Profile Expired
- recurring_payment_skipped RP Profile Skipped
- recurring_payment_outstanding_payment RP Sucessful Outstanding Payment
- recurring_payment_outstanding_payment_failed RP Failed Outstanding Payment
- recurring_payment_suspended RP Profile Suspended
- recurring_payment_suspended_due_to_max_failed_payment RP Profile Suspended due to Max Failed Payment
- */
+ recurring_payment_profile_created RP Profile Created
+ recurring_payment RP Sucessful Payment
+ recurring_payment_failed RP Failed Payment
+ recurring_payment_profile_cancel RP Profile Cancelled
+ recurring_payment_expired RP Profile Expired
+ recurring_payment_skipped RP Profile Skipped
+ recurring_payment_outstanding_payment RP Sucessful Outstanding Payment
+ recurring_payment_outstanding_payment_failed RP Failed Outstanding Payment
+ recurring_payment_suspended RP Profile Suspended
+ recurring_payment_suspended_due_to_max_failed_payment RP Profile Suspended due to Max Failed Payment
+ */
//set transaction type
$txnType = $this->retrieve('txn_type', 'String');
// get the result code to validate.
$result_code = $nvpArray['RESULT'];
/*debug
- echo "<p>Params array</p><br>";
- print_r($params);
- echo "<p></p><br>";
- echo "<p>Values to Payment Processor</p><br>";
- print_r($payflow_query_array);
- echo "<p></p><br>";
- echo "<p>Results from Payment Processor</p><br>";
- print_r($nvpArray);
- echo "<p></p><br>";
- */
+ echo "<p>Params array</p><br>";
+ print_r($params);
+ echo "<p></p><br>";
+ echo "<p>Values to Payment Processor</p><br>";
+ print_r($payflow_query_array);
+ echo "<p></p><br>";
+ echo "<p>Results from Payment Processor</p><br>";
+ print_r($nvpArray);
+ echo "<p></p><br>";
+ */
switch ($result_code) {
case 0:
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/*
}
else {
/* Since trxn_id hasn't got any use here,
- * lets make use of it by passing the eventID/membershipTypeID to next level.
- * And change trxn_id to the payment processor reference before finishing db update */
+ * lets make use of it by passing the eventID/membershipTypeID to next level.
+ * And change trxn_id to the payment processor reference before finishing db update */
if ($ids['event']) {
$contribution->trxn_id = $ids['event'] . CRM_Core_DAO::VALUE_SEPARATOR . $ids['participant'];
| different CustomerID is used per currency. |
| |
+--------------------------------------------------------------------+
-*/
+ */
/**
* -----------------------------------------------------------------------------------------------
}
/*
- //-------------------------------------------------------------
- // NOTE: eWAY Doesn't use the following at the moment:
- //-------------------------------------------------------------
- $creditCardType = $params['credit_card_type'];
- $currentcyID = $params['currencyID'];
- $country = $params['country'];
- */
+ //-------------------------------------------------------------
+ // NOTE: eWAY Doesn't use the following at the moment:
+ //-------------------------------------------------------------
+ $creditCardType = $params['credit_card_type'];
+ $currentcyID = $params['currencyID'];
+ $country = $params['country'];
+ */
//-------------------------------------------------------------
// Prepare some composite data from _paymentProcessor fields
}
/*
- //----------------------------------------------------------------------------------------------------
- // Test mode always returns trxn_id = 0 - so we fix that here
- //
- // NOTE: This code was taken from the AuthorizeNet payment processor, however it now appears
- // unecessary for the eWAY gateway - Left here in case it proves useful
- //----------------------------------------------------------------------------------------------------
- if ( $this->_mode == 'test' ) {
- $query = "SELECT MAX(trxn_id) FROM civicrm_contribution WHERE trxn_id LIKE 'test%'";
- $p = array( );
- $trxn_id = strval( CRM_Core_Dao::singleValueQuery( $query, $p ) );
- $trxn_id = str_replace( 'test', '', $trxn_id );
- $trxn_id = intval($trxn_id) + 1;
- $params['trxn_id'] = sprintf('test%08d', $trxn_id);
- }
- else {
- $params['trxn_id'] = $eWAYResponse->TransactionNumber();
- }
- */
+ //----------------------------------------------------------------------------------------------------
+ // Test mode always returns trxn_id = 0 - so we fix that here
+ //
+ // NOTE: This code was taken from the AuthorizeNet payment processor, however it now appears
+ // unecessary for the eWAY gateway - Left here in case it proves useful
+ //----------------------------------------------------------------------------------------------------
+ if ( $this->_mode == 'test' ) {
+ $query = "SELECT MAX(trxn_id) FROM civicrm_contribution WHERE trxn_id LIKE 'test%'";
+ $p = array( );
+ $trxn_id = strval( CRM_Core_Dao::singleValueQuery( $query, $p ) );
+ $trxn_id = str_replace( 'test', '', $trxn_id );
+ $trxn_id = intval($trxn_id) + 1;
+ $params['trxn_id'] = sprintf('test%08d', $trxn_id);
+ }
+ else {
+ $params['trxn_id'] = $eWAYResponse->TransactionNumber();
+ }
+ */
//=============
// Success !
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
* This class facilitates the loading of resources
);
/*
- Year greater than 2000 get wrong result for following format
- echo date( 'Y-m-d', strtotime( '7 Nov, 2001') );
- echo date( 'Y-m-d', strtotime( '7 November, 2001') );
- Return current year
- expected :: 2001-11-07
- output :: 2009-11-07
- However
- echo date( 'Y-m-d', strtotime( 'Nov 7, 2001') );
- echo date( 'Y-m-d', strtotime( 'November 7, 2001') );
- gives proper result
+ Year greater than 2000 get wrong result for following format
+ echo date( 'Y-m-d', strtotime( '7 Nov, 2001') );
+ echo date( 'Y-m-d', strtotime( '7 November, 2001') );
+ Return current year
+ expected :: 2001-11-07
+ output :: 2009-11-07
+ However
+ echo date( 'Y-m-d', strtotime( 'Nov 7, 2001') );
+ echo date( 'Y-m-d', strtotime( 'November 7, 2001') );
+ gives proper result
*/
return $dateInputFormats;
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
if ($returnCode & self::DUPLICATE) {
if ($returnCode & self::MULTIPLE_DUPE) {
/* TODO: multi-dupes should be counted apart from singles
- * on non-skip action */
+ * on non-skip action */
}
$this->_duplicateCount++;
$recordNumber = $this->_lineCount;
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
* Class CRM_Dedupe_BAO_QueryBuilder_IndividualUnsupervised
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
'type' => CRM_Utils_Type::T_STRING,
));
- $participantStatus = array(
+ $participantStatus = array(
'participant_status' => array(
'title' => 'Participant Status',
'name' => 'participant_status',
'type' => CRM_Utils_Type::T_STRING,
));
- $participantRole = array(
+ $participantRole = array(
'participant_role' => array(
'title' => 'Participant Role',
'name' => 'participant_role',
'type' => CRM_Utils_Type::T_STRING,
));
- $discountFields = CRM_Core_DAO_Discount::export();
+ $discountFields = CRM_Core_DAO_Discount::export();
- $fields = array_merge($participantFields, $participantStatus, $participantRole, $eventFields, $noteField, $discountFields);
+ $fields = array_merge($participantFields, $participantStatus, $participantRole, $eventFields, $noteField, $discountFields);
- // add custom data
- $fields = array_merge($fields, CRM_Core_BAO_CustomField::getFieldsForImport('Participant'));
- self::$_exportableFields = $fields;
+ // add custom data
+ $fields = array_merge($fields, CRM_Core_BAO_CustomField::getFieldsForImport('Participant'));
+ self::$_exportableFields = $fields;
}
return self::$_exportableFields;
*/
/*
-* Copyright (C) 2010 Tech To The People
-* Licensed to CiviCRM under the Academic Free License version 3.0.
-*
-*/
+ * Copyright (C) 2010 Tech To The People
+ * Licensed to CiviCRM under the Academic Free License version 3.0.
+ *
+ */
/**
*
/*
-* Copyright (C) 2010 Tech To The People
-* Licensed to CiviCRM under the Academic Free License version 3.0.
-*
-*/
+ * Copyright (C) 2010 Tech To The People
+ * Licensed to CiviCRM under the Academic Free License version 3.0.
+ *
+ */
/**
*
/*
-* Copyright (C) 2010 Tech To The People
-* Licensed to CiviCRM under the Academic Free License version 3.0.
-*
-*/
+ * Copyright (C) 2010 Tech To The People
+ * Licensed to CiviCRM under the Academic Free License version 3.0.
+ *
+ */
/**
*
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
* Class CRM_Event_Cart_BAO_MerParticipant
public $_pcpId;
/* Is event already full.
- *
- * @var boolean
- */
+ *
+ * @var boolean
+ */
public $_isEventFull;
case 'register_date':
return CRM_Utils_Rule::date($this->_value);
- /*
+ /* @codingStandardsIgnoreStart
case 'event_id':
static $events = null;
if (!$events) {
return false;
}
break;
- */
+ @codingStandardsIgnoreEnd */
default:
break;
if ($returnCode & self::DUPLICATE) {
if ($returnCode & self::MULTIPLE_DUPE) {
/* TODO: multi-dupes should be counted apart from singles
- * on non-skip action */
+ * on non-skip action */
}
$this->_duplicateCount++;
$recordNumber = $this->_lineCount;
$pathElm = explode(DIRECTORY_SEPARATOR, $path);
array_pop($pathElm);
return implode(DIRECTORY_SEPARATOR, $pathElm) . DIRECTORY_SEPARATOR . self::EXT_TEMPLATES_DIRNAME;
- */
+ */
}
/**
$search = new CRM_Mailing_BAO_TrackableURL();
/* To find the url, we also join on the queue and job tables. This
- * prevents foreign key violations. */
+ * prevents foreign key violations. */
$job = CRM_Mailing_BAO_MailingJob::getTableName();
$eq = CRM_Mailing_Event_BAO_Queue::getTableName();
);
/* Make a list of groups and a list of prior mailings that received
- * this mailing */
+ * this mailing */
$groups = array();
$base_groups = array();
}
/* As long as we have prior mailings, find their groups and add to the
- * list */
+ * list */
while (!empty($mailings)) {
$do->query("
CRM_Utils_Hook::unsubscribeGroups('unsubscribe', $mailing_id, $contact_id, $group_ids, $base_group_ids);
/* Now we have a complete list of recipient groups. Filter out all
- * those except smart groups, those that the contact belongs to and
- * base groups from search based mailings */
+ * those except smart groups, those that the contact belongs to and
+ * base groups from search based mailings */
$baseGroupClause = '';
if (!empty($base_group_ids)) {
}
/* Show the subject instead of the name here, since it's being
- * displayed to external contacts/users */
+ * displayed to external contacts/users */
CRM_Utils_System::setTitle(ts('Forward Mailing: %1', array(1 => $mailing->subject)));
}
/* Do a full token replacement on a dummy verp, the current
- * contact and domain, and the first organization. */
+ * contact and domain, and the first organization. */
// here we make a dummy mailing object so that we
// can retrieve the tokens that we need to replace
if ($returnCode & self::DUPLICATE) {
if ($returnCode & self::MULTIPLE_DUPE) {
/* TODO: multi-dupes should be counted apart from singles
- * on non-skip action */
+ * on non-skip action */
}
$this->_duplicateCount++;
$recordNumber = $this->_lineCount;
$status = CRM_Member_BAO_MembershipStatus::getMembershipStatusCurrent();
$status = implode(',', $status);
- /* Disabled for lack of appropriate search
+ /*@codingStandardsIgnoreStart
+ Disabled for lack of appropriate search
The Membership search isn't able to properly filter by join or renewal events.
Until that works properly, the subtotals shouldn't get links.
}
}
}
- */
+ @codingStandardsIgnoreEnd */
// Temporary replacement for current totals column
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing
+--------------------------------------------------------------------+
-*/
+ */
/**
*
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
//CRM_Core_DAO::getFieldValue( 'CRM_Price_DAO_PriceField', $this->_fid, 'weight', 'id' );
// FIX ME: duplicate rule?
/*
- $this->addRule( 'label',
- ts('Duplicate option label.'),
- 'optionExists',
- array( 'CRM_Core_DAO_OptionValue', $this->_oid, $this->_ogId, 'label' ) );
- */
+ $this->addRule( 'label',
+ ts('Duplicate option label.'),
+ 'optionExists',
+ array( 'CRM_Core_DAO_OptionValue', $this->_oid, $this->_ogId, 'label' ) );
+ */
// value
$this->add('text', 'amount', ts('Option Amount'), NULL, TRUE);
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
'force',
'Boolean',
CRM_Core_DAO::$_nullObject
- );
+ );
$this->_dashBoardRowCount
= CRM_Utils_Request::retrieve(
'rowCount',
'Integer',
CRM_Core_DAO::$_nullObject
- );
+ );
$this->_section = CRM_Utils_Request::retrieve('section', 'Integer', CRM_Core_DAO::$_nullObject);
'operatorType' => CRM_Report_Form::OP_MULTISELECT,
'options' => CRM_Core_PseudoConstant::stateProvince( ), ),
),
- */
+ */
),
'civicrm_phone' => array(
'dao' => 'CRM_Core_DAO_Phone',
}
/* Group (un-limited) report by all aliases and get counts. This might
- * be done more efficiently when the contents of $sql are known, ie. by
- * overriding this method in the report class.
- */
+ * be done more efficiently when the contents of $sql are known, ie. by
+ * overriding this method in the report class.
+ */
$addtotals = '';
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
$dataErrors = array();
/* Do a full token replacement on a dummy verp, the current
- * contact and domain, and the first organization. */
+ * contact and domain, and the first organization. */
// here we make a dummy mailing object so that we
// can retrieve the tokens that we need to replace
// sample test list
/* $revList = array(
- '2.1.0', '2.2.beta2', '2.2.beta1', '2.2.alpha1', */
+ '2.1.0', '2.2.beta2', '2.2.beta1', '2.2.alpha1', */
/* '2.2.alpha3', '2.2.0', '2.2.2', '2.1.alpha1', '2.1.3'); */
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
* Class CRM_Utils_Cache_SerializeCache
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
// 'm/d/Y' format. So that submitted value is alwats mm/dd/YY format
// note that for date display we dynamically create text field
/*
- if ( !$format ) {
- $format = $config->dateInputFormat;
- }
+ if ( !$format ) {
+ $format = $config->dateInputFormat;
+ }
- // get actual format
- $actualPHPFormats = CRM_Core_SelectValues::datePluginToPHPFormats( );
- $dateFormat = CRM_Utils_Array::value( $format, $actualPHPFormats );
- */
+ // get actual format
+ $actualPHPFormats = CRM_Core_SelectValues::datePluginToPHPFormats( );
+ $dateFormat = CRM_Utils_Array::value( $format, $actualPHPFormats );
+ */
$dateFormat = 'm/d/Y';
$date = date($dateFormat, strtotime($mysqlDate));
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/*
* These functions have been deprecated out of API v3 Utils folder as they are not part of the
*/
function _civicrm_api3_deprecated_add_formatted_param(&$values, &$params) {
/* Crawl through the possible classes:
- * Contact
- * Individual
- * Household
- * Organization
- * Location
- * Address
- * Email
- * Phone
- * IM
- * Note
- * Custom
- */
+ * Contact
+ * Individual
+ * Household
+ * Organization
+ * Location
+ * Address
+ * Email
+ * Phone
+ * IM
+ * Note
+ * Custom
+ */
/* Cache the various object fields */
static $fields = NULL;
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
$values['postal_code'] = $ret['postal'];
/* the following logic to split the string was borrowed from
- CRM/Core/BAO/Address.php -- CRM_Core_BAO_Address::fixAddress.
- This is actually the function that calls the geocoding
- script to begin with, but the postal code business takes
- place before geocoding gets called.
- */
+ CRM/Core/BAO/Address.php -- CRM_Core_BAO_Address::fixAddress.
+ This is actually the function that calls the geocoding
+ script to begin with, but the postal code business takes
+ place before geocoding gets called.
+ */
if (preg_match('/^(\d{4,5})[+-](\d{4})$/',
$ret['postal'],
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
* Parse Javascript content and extract translatable strings.
'currency', array(
'keyColumn' => 'name',
'labelColumn' => 'symbol',
- ));
+ )
+ );
$value = str_replace($currencySymbols, '', $value);
if ($config->monetaryThousandSeparator) {
$str = preg_replace('/\s+/', '', $str);
/* pattern stolen from the php.net function documentation for
- * utf8decode();
- * comment by JF Sebastian, 30-Mar-2005
- */
+ * utf8decode();
+ * comment by JF Sebastian, 30-Mar-2005
+ */
return preg_match('/^([\x00-\x7f]|[\xc2-\xdf][\x80-\xbf]|\xe0[\xa0-\xbf][\x80-\xbf]|[\xe1-\xec][\x80-\xbf]{2}|\xed[\x80-\x9f][\x80-\xbf]|[\xee-\xef][\x80-\xbf]{2}|f0[\x90-\xbf][\x80-\xbf]{2}|[\xf1-\xf3][\x80-\xbf]{3}|\xf4[\x80-\x8f][\x80-\xbf]{2})*$/', $str);
// ||
$form_state['method'] = 'post';
$form_state['build_info']['args'] = array();
/*
- * if we want to submit this form more than once in a process (e.g. create more than one user)
- * we must force it to validate each time for this form. Otherwise it will not validate
- * subsequent submissions and the manner in which the password is passed in will be invalid
- */
+ * if we want to submit this form more than once in a process (e.g. create more than one user)
+ * we must force it to validate each time for this form. Otherwise it will not validate
+ * subsequent submissions and the manner in which the password is passed in will be invalid
+ */
$form_state['must_validate'] = TRUE;
$config = CRM_Core_Config::singleton();
$perms = $perms + drupal_map_assoc($newPerms);
$permList = implode(', ', $perms);
db_query('UPDATE {permission} SET perm = "%s" WHERE rid = %d', $permList, $rid);
- /*
+ /* @codingStandardsIgnoreStart
if ( ! empty( $roles ) ) {
$rids = implode(',', array_keys($roles));
db_query( 'UPDATE {permission} SET perm = CONCAT( perm, \', edit all events\') WHERE rid IN (' . implode(',', array_keys($roles)) . ')' );
db_query( "UPDATE {permission} SET perm = REPLACE( perm, '%s', '%s' ) WHERE rid IN ($rids)",
- $oldPerm, implode(', ', $newPerms) );*/
+ $oldPerm, implode(', ', $newPerms) );
+ @codingStandardsIgnoreEnd */
}
}
$escapeSmarty = FALSE
) {
/* If the token is an email action, use it. Otherwise, find the
- * appropriate URL */
+ * appropriate URL */
if (!in_array($token, self::$_tokens['action'])) {
$value = "{action.$token}";
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
* Class CRM_Utils_Weight
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
* File for the CiviCRM APIv3 Case functions
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
* File for the CiviCRM APIv3 Case functions
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
* new version of civicrm apis. See blog post at
CRM_Utils_Array::value(
'phone_type_id',
$values['location']['phone'][1]
- )
+ )
),
'phone' => CRM_Utils_Array::value(
'phone',
- $values['location']['phone'][1]
+ $values['location']['phone'][1]
),
);
}
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
* @param array $apiRequest
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
* Generic api wrapper used for quicksearch and autocomplete
*
/* $params['entity_id']['api.required'] = 1;
$params['entity_table']['api.default'] = "civicrm_contribution_recur";
$params['type']['api.default'] = "R";
- */
+ */
}
/**
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
* File for the CiviCRM APIv3 activity profile functions
);
}
-/*
+/* @codingStandardsIgnoreStart
function civicrm_api3_report_template_getfields($params) {
return civicrm_api3_create_success(array(
'id' => array(
'default' => 'UL',
),
));
-}*/
+}
+@codingStandardsIgnoreEnd */
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
* File for CiviCRM APIv3 utilitity functions
'contact_type' => 'Individual',
'contact_id' => $contactId,
);
- $contact = CRM_Contact_BAO_Contact::add($params);
- $test->assertInstanceOf('CRM_Contact_DAO_Contact', $contact, 'Check for created object');
+ $contact = CRM_Contact_BAO_Contact::add($params);
+ $test->assertInstanceOf('CRM_Contact_DAO_Contact', $contact, 'Check for created object');
},
));
}
* 2) for current domain setting max_attachments is set to the value that $config->maxAttachments
* had (6)
* 3) for other domain (2) max_attachments is set to the configured default (3)
- *
- *
- **/
+ */
public function testConvertAndFillSettings() {
$settings = array('maxAttachments' => 6);
CRM_Core_BAO_ConfigSetting::add($settings);
$this->assertEmpty($maxAttachments);
}
- /*
+ /* @codingStandardsIgnoreStart
* Check that setting is converted without config value being removed
*
- public function testConvertConfigToSettingPrefetch() {
+ public function testConvertConfigToSettingPrefetch() {
$settings = array('debug' => 1);
CRM_Core_BAO_ConfigSetting::add($settings);
$config = CRM_Core_Config::singleton(true, true);
$config = CRM_Core_Config::singleton(true, true);
$this->assertEmpty($config->debug);
}
- */
+ @codingStandardsIgnoreEnd */
/**
* Ensure that on_change callbacks fire.
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviUnitTestCase.php';
/**
$this->assertFalse(is_array($result));
}
- /*
+ /* @codingStandardsIgnoreStart
* Test calls main functions in sequence per 'main' - I had hoped to test the functions more
* fully but the calls to the POST happen in more than one function
* keeping this as good example of data to bring back to life later
return $this->IPN->recur( $input, $ids, $objects, $first );
}
}
+ @codingStandardsIgnoreEnd */
/**
* Prepare for contribution Test - involving only contribution objects
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license UAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviUnitTestCase.php';
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviUnitTestCase.php';
/**
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviUnitTestCase.php';
/**
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviUnitTestCase.php';
/**
public function _createContainer(CRM_Utils_Cache_Interface $cache = NULL, $cacheKey = NULL, $appendPathGarbage = '') {
/*
$container = new CRM_Extension_Container_Static(array(
- 'test.foo.bar' => array(
- 'path' => '/path/to/test.foo.bar',
- 'resUrl' => 'http://resources/test.foo.bar',
- ),
+ 'test.foo.bar' => array(
+ 'path' => '/path/to/test.foo.bar',
+ 'resUrl' => 'http://resources/test.foo.bar',
+ ),
));
- */
+ */
$basedir = rtrim($this->createTempDir('ext-'), '/');
mkdir("$basedir/weird");
mkdir("$basedir/weird/foobar");
/*
$params = array(
- 'contact_id' => $contactId,
- 'membership_type_id' => $this->_membershipTypeID,
- 'join_date' => '2006-01-21',
- 'start_date' => '2006-01-21',
- 'end_date' => '2006-12-21',
- 'source' => 'Payment',
- 'is_override' => 1,
- 'status_id' => $this->_mebershipStatusID,
+ 'contact_id' => $contactId,
+ 'membership_type_id' => $this->_membershipTypeID,
+ 'join_date' => '2006-01-21',
+ 'start_date' => '2006-01-21',
+ 'end_date' => '2006-12-21',
+ 'source' => 'Payment',
+ 'is_override' => 1,
+ 'status_id' => $this->_mebershipStatusID,
);
- */
+ */
$importObject = new CRM_Member_Import_Parser_Membership($fieldMapper);
$importObject->init();
$importObject->_contactType = 'Individual';
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviUnitTestCase.php';
__DIR__ . '/fixtures/Contact-text.xml',
);
- /*
+ /* @codingStandardsIgnoreStart
$cases[] = array(
// CustomGroup params
array(
// expectedXmlFilePath
__DIR__ . '/fixtures/Contact-select.xml',
);
- */
+ @codingStandardsIgnoreEnd */
$cases[] = array(
// CustomGroup params
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviUnitTestCase.php';
/**
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviUnitTestCase.php';
/**
/*
require $GLOBALS['base_dir'] . DIRECTORY_SEPARATOR .
- 'packages' . DIRECTORY_SEPARATOR .
- 'PHPUnit' . DIRECTORY_SEPARATOR .
- 'Autoload.php';
-*/
+'packages' . DIRECTORY_SEPARATOR .
+'PHPUnit' . DIRECTORY_SEPARATOR .
+'Autoload.php';
+ */
$this->assertTrue(
(bool) preg_match("/^This will run the batch merge process on the listed duplicates. The operation will run in safe mode - only records with no direct data conflicts will be merged. Click OK to proceed if you are sure you wish to run this operation./",
$this->getConfirmation()
- ));
+ )
+ );
$this->chooseOkOnNextConfirmation();
$this->waitForPageToLoad($this->getTimeoutMsec());
$this->waitForElementPresent('civicrm-footer');
// todo: write code to check other payment processors
/*$this->_tryPaymentProcessor($this->names['Google_Checkout']);
- $this->_tryPaymentProcessor($this->names['PayPal']);
- $this->_tryPaymentProcessor($this->names['PayPal_Standard']);*/
+ $this->_tryPaymentProcessor($this->names['PayPal']);
+ $this->_tryPaymentProcessor($this->names['PayPal_Standard']);*/
}
public function _initialize() {
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviSeleniumTestCase.php';
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'WebTest/Import/ImportCiviSeleniumTestCase.php';
$test = $this;
$this->customFieldSetLoadOnTheFlyCheck($customSets, $pageUrl,
function () use ($test) {
- $test->select('membership_type_id_0', 'value=1');
+ $test->select('membership_type_id_0', 'value=1');
}
);
}
* the $params passed in is not an array.
*/
public function testParamsNotArray() {
- /*I have commented this out as the check for is_array has been moved to civicrm_api. But keeping in place as
- * this test, in contrast to the standards test, tests all existing API rather than just CRUD ones
- * so want to keep code for re-use
+ /* @codingStandardsIgnoreStart
+ * I have commented this out as the check for is_array has been moved to civicrm_api. But keeping in place as
+ * this test, in contrast to the standards test, tests all existing API rather than just CRUD ones
+ * so want to keep code for re-use
$files = $this->getAllFilesinAPIDir();
$this->assertGreaterThan(1, count($files),"something has gone wrong listing the files in line " . __LINE__);
$this->requireOnceFilesArray($files);
continue;
}
- }*/
+ }
+ @codingStandardsIgnoreEnd */
}
/**
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviUnitTestCase.php';
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
* Include class definitions
}
}
/*
- * Can't figure out the point of this?
- */
+ * Can't figure out the point of this?
+ */
/**
* @param array $params
*/
public function _buildParams($gid, $htype, $dtype) {
$params = $this->_buildBasicParams($gid, $htype, $dtype);
/* //Not Working for any type. Maybe redundant with testCustomFieldCreateWithOptionValues()
- if ($htype == 'Multi-Select')
- $params = array_merge($params, array(
- 'option_label' => array( 'Label1','Label2'),
- 'option_value' => array( 'val1', 'val2' ),
- 'option_weight' => array( 1, 2),
- 'option_status' => array( 1, 1),
- ));
- */
+ if ($htype == 'Multi-Select')
+ $params = array_merge($params, array(
+ 'option_label' => array( 'Label1','Label2'),
+ 'option_value' => array( 'val1', 'val2' ),
+ 'option_weight' => array( 1, 2),
+ 'option_status' => array( 1, 1),
+ ));
+ */
return $params;
}
* Test using example code
*/
/*function testCustomFieldCreateExample( )
- {
+ {
- $customGroup = $this->customGroupCreate('Individual','date_test_group',3);
- require_once 'api/v3/examples/CustomField/Create.php';
- $result = custom_field_create_example();
- $expectedResult = custom_field_create_expectedresult();
- $this->assertEquals($result,$expectedResult);
- }*/
+ $customGroup = $this->customGroupCreate('Individual','date_test_group',3);
+ require_once 'api/v3/examples/CustomField/Create.php';
+ $result = custom_field_create_example();
+ $expectedResult = custom_field_create_expectedresult();
+ $this->assertEquals($result,$expectedResult);
+ }*/
/**
* Check with data type - Options with option_values
class api_v3_DomainTest extends CiviUnitTestCase {
/* This test case doesn't require DB reset - apart from
- where cleanDB() is called. */
+ where cleanDB() is called. */
public $DBResetRequired = FALSE;
///////////////// civicrm_domain_create methods
/*
- * This test checks for a memory leak observed when doing 2 gets on current domain
- */
+ * This test checks for a memory leak observed when doing 2 gets on current domain
+ */
public function testGetCurrentDomainTwice() {
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviUnitTestCase.php';
/*
public function testGetIdOfEventByEventTitle() {
- $params = array( 'title' => 'Annual CiviCRM meet',
- 'return' => 'id'
- );
+ $params = array( 'title' => 'Annual CiviCRM meet',
+ 'return' => 'id'
+ );
- $result = $this->callAPISuccess('Event', 'Get', $params);
+ $result = $this->callAPISuccess('Event', 'Get', $params);
}
- */
+ */
/**
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviUnitTestCase.php';
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviUnitTestCase.php';
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviUnitTestCase.php';
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviUnitTestCase.php';
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviUnitTestCase.php';
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviUnitTestCase.php';
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviUnitTestCase.php';
'option_group', 'get', array(
'name' => 'gender',
'sequential' => 1,
- ));
+ )
+ );
$this->assertAPISuccess($optionGroup);
$params = array(
'option_group_id' => $optionGroup['id'],
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviUnitTestCase.php';
$this->callAPISuccess('PriceFieldValue', 'delete', array('id' => $pfv2['id']));
$this->callAPISuccess('PriceField', 'delete', array('id' => $pricefield['id']));
$this->callAPISuccess('PriceSet', 'delete', array('id' => $priceset['id']));
- */
+ */
}
/**
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviUnitTestCase.php';
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviUnitTestCase.php';
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviUnitTestCase.php';
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
* Include class definitions
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/*
+--------------------------------------------------------------------+
$this->assertEquals('Default Organization', $result[0]['civicrm_contact_sort_name']);
$this->assertEquals('Second Domain', $result[1]['civicrm_contact_sort_name']);
$this->assertEquals('15 Main St', $result[1]['civicrm_address_street_address']);
- */
+ */
}
/**
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviUnitTestCase.php';
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
require_once 'CiviTest/CiviUnitTestCase.php';