'type' => 'upload',
'name' => ts('Save'),
'isDefault' => TRUE,
- 'submitOnce' => TRUE,
],
[
'type' => 'cancel',
public function buildQuickForm() {
CRM_Utils_System::setTitle(ts('Settings - Cleanup Caches and Update Paths'));
- $this->addElement(
- 'submit', $this->getButtonName('next', 'cleanup'), 'Cleanup Caches',
- ['class' => 'crm-form-submit', 'id' => 'cleanup-cache']
- );
-
- $this->addElement(
- 'submit', $this->getButtonName('next', 'resetpaths'), 'Reset Paths',
- ['class' => 'crm-form-submit', 'id' => 'resetpaths']
- );
-
- //parent::buildQuickForm();
+ $this->addButtons([
+ [
+ 'type' => 'next',
+ 'name' => ts('Cleanup Caches'),
+ 'subName' => 'cleanup',
+ 'icon' => 'fa-undo',
+
+ ],
+ [
+ 'type' => 'next',
+ 'name' => ts('Reset Paths'),
+ 'subName' => 'resetpaths',
+ 'icon' => 'fa-terminal',
+ ],
+ ]);
}
public function postProcess() {
- if (!empty($_POST['_qf_UpdateConfigBackend_next_cleanup'])) {
-
+ if (isset($_REQUEST['_qf_UpdateConfigBackend_next_cleanup'])) {
$config = CRM_Core_Config::singleton();
// cleanup templates_c directory
CRM_Core_Session::setStatus(ts('Cache has been cleared and menu has been rebuilt successfully.'), ts("Success"), "success");
}
-
- if (!empty($_POST['_qf_UpdateConfigBackend_next_resetpaths'])) {
+ elseif (isset($_REQUEST['_qf_UpdateConfigBackend_next_resetpaths'])) {
$msg = CRM_Core_BAO_ConfigSetting::doSiteMove();
CRM_Core_Session::setStatus($msg, ts("Success"), "success");
}
- return CRM_Utils_System::redirect(CRM_Utils_System::url('civicrm/admin/setting/updateConfigBackend', 'reset=1'));
+ CRM_Utils_System::redirect(CRM_Utils_System::url('civicrm/admin/setting/updateConfigBackend', 'reset=1'));
}
}
'subject' => CRM_Utils_Array::value('subject', $note),
'contact_id' => $contactId,
);
- CRM_Core_BAO_Note::add($noteParams, CRM_Core_DAO::$_nullArray);
+ CRM_Core_BAO_Note::add($noteParams);
}
}
else {
'subject' => CRM_Utils_Array::value('subject', $params),
'contact_id' => $contactId,
);
- CRM_Core_BAO_Note::add($noteParams, CRM_Core_DAO::$_nullArray);
+ CRM_Core_BAO_Note::add($noteParams);
}
}
FROM civicrm_contact
WHERE id IN ( $idString )
";
- $count = CRM_Core_DAO::singleValueQuery($query,
- CRM_Core_DAO::$_nullArray
- );
+ $count = CRM_Core_DAO::singleValueQuery($query);
return $count > 1 ? TRUE : FALSE;
}
AND is_current_member = 1";
$result = CRM_Core_DAO::singleValueQuery($query);
if ($result < CRM_Utils_Array::value('max_related', $membershipValues, PHP_INT_MAX)) {
- CRM_Member_BAO_Membership::create($membershipValues, CRM_Core_DAO::$_nullArray);
+ CRM_Member_BAO_Membership::create($membershipValues);
}
}
}
public function count() {
$sql = $this->all();
- $dao = CRM_Core_DAO::executeQuery($sql,
- CRM_Core_DAO::$_nullArray
- );
+ $dao = CRM_Core_DAO::executeQuery($sql);
return $dao->N;
}
return $sql;
}
- return CRM_Core_DAO::composeQuery($sql, CRM_Core_DAO::$_nullArray);
+ return CRM_Core_DAO::composeQuery($sql);
}
/**
public function count() {
$sql = $this->all();
- $dao = CRM_Core_DAO::executeQuery($sql,
- CRM_Core_DAO::$_nullArray
- );
+ $dao = CRM_Core_DAO::executeQuery($sql);
return $dao->N;
}
date_added >= '$startDate 00:00:00'
$endDateFix";
- CRM_Core_DAO::executeQuery($dateRange, CRM_Core_DAO::$_nullArray);
+ CRM_Core_DAO::executeQuery($dateRange);
// Only include groups in the search query of one or more Include OR Exclude groups has been selected.
// CRM-6356
civicrm_group_contact.status = 'Added' AND
civicrm_group_contact.group_id IN( {$xGroups})";
- CRM_Core_DAO::executeQuery($excludeGroup, CRM_Core_DAO::$_nullArray);
+ CRM_Core_DAO::executeQuery($excludeGroup);
//search for smart group contacts
foreach ($this->_excludeGroups as $keys => $values) {
$smartGroupQuery = " INSERT IGNORE INTO {$this->_xgTable}(contact_id) $smartSql";
- CRM_Core_DAO::executeQuery($smartGroupQuery, CRM_Core_DAO::$_nullArray);
+ CRM_Core_DAO::executeQuery($smartGroupQuery);
}
}
}
$includeGroup .= " AND {$this->_xgTable}.contact_id IS null";
}
- CRM_Core_DAO::executeQuery($includeGroup, CRM_Core_DAO::$_nullArray);
+ CRM_Core_DAO::executeQuery($includeGroup);
//search for smart group contacts
foreach ($this->_includeGroups as $keys => $values) {
{$this->_igTable}(contact_id)
$smartSql";
- CRM_Core_DAO::executeQuery($smartGroupQuery, CRM_Core_DAO::$_nullArray);
+ CRM_Core_DAO::executeQuery($smartGroupQuery);
$insertGroupNameQuery = "UPDATE IGNORE {$this->_igTable}
SET group_names = (SELECT title FROM civicrm_group
WHERE civicrm_group.id = $values)
WHERE {$this->_igTable}.contact_id IS NOT NULL
AND {$this->_igTable}.group_names IS NULL";
- CRM_Core_DAO::executeQuery($insertGroupNameQuery, CRM_Core_DAO::$_nullArray);
+ CRM_Core_DAO::executeQuery($insertGroupNameQuery);
}
}
}
public function count() {
$sql = $this->all();
- $dao = CRM_Core_DAO::executeQuery($sql,
- CRM_Core_DAO::$_nullArray
- );
+ $dao = CRM_Core_DAO::executeQuery($sql);
return $dao->N;
}
//drop the temp. tables if they exist
if ($this->_igTable && !empty($this->_includeGroups)) {
$sql = "DROP TEMPORARY TABLE IF EXISTS {$this->_igTable}";
- CRM_Core_DAO::executeQuery($sql, CRM_Core_DAO::$_nullArray);
+ CRM_Core_DAO::executeQuery($sql);
}
if ($this->_xgTable && !empty($this->_excludeGroups)) {
$sql = "DROP TEMPORARY TABLE IF EXISTS {$this->_xgTable}";
- CRM_Core_DAO::executeQuery($sql, CRM_Core_DAO::$_nullArray);
+ CRM_Core_DAO::executeQuery($sql);
}
}
WHERE $where
";
- $dao = CRM_Core_DAO::executeQuery($sql,
- CRM_Core_DAO::$_nullArray
- );
+ $dao = CRM_Core_DAO::executeQuery($sql);
$totals = [];
while ($dao->fetch()) {
$totals['payment_amount'] = $dao->payment_amount;
public function count() {
$sql = $this->all();
- $dao = CRM_Core_DAO::executeQuery($sql,
- CRM_Core_DAO::$_nullArray
- );
+ $dao = CRM_Core_DAO::executeQuery($sql);
return $dao->N;
}
public function count() {
$sql = $this->all();
- $dao = CRM_Core_DAO::executeQuery($sql,
- CRM_Core_DAO::$_nullArray
- );
+ $dao = CRM_Core_DAO::executeQuery($sql);
return $dao->N;
}
AND v.is_active = 1
ORDER By v.weight
";
- $dao = CRM_Core_DAO::executeQuery($sql,
- CRM_Core_DAO::$_nullArray
- );
+ $dao = CRM_Core_DAO::executeQuery($sql);
$rows = [];
while ($dao->fetch()) {
$websiteTypes = CRM_Core_PseudoConstant::get('CRM_Core_DAO_Website', 'website_type_id');
$params = ['contact_id' => $contactId];
- $websites = CRM_Core_BAO_Website::getValues($params, CRM_Core_DAO::$_nullArray);
+ $websites = CRM_Core_BAO_Website::getValues($params);
if (!empty($websites)) {
foreach ($websites as $key => & $value) {
$value['website_type'] = $websiteTypes[$value['website_type_id']];
*
* @return CRM_Contribute_BAO_Contribution
*/
- public static function retrieve(&$params, &$defaults, &$ids) {
+ public static function retrieve(&$params, &$defaults = [], &$ids = []) {
$contribution = CRM_Contribute_BAO_Contribution::getValues($params, $defaults, $ids);
return $contribution;
}
WHERE entity_table = 'civicrm_contribution_page'
AND entity_id ={$id}";
- $premiumDao = CRM_Core_DAO::executeQuery($premiumQuery, CRM_Core_DAO::$_nullArray);
+ $premiumDao = CRM_Core_DAO::executeQuery($premiumQuery);
while ($premiumDao->fetch()) {
if ($premiumDao->id) {
CRM_Core_DAO::copyGeneric('CRM_Contribute_DAO_PremiumsProduct', [
$honorId = CRM_Utils_Array::value(0, $ids);
}
+ $null = [];
$honorId = CRM_Contact_BAO_Contact::createProfileContact(
- $params['honor'], CRM_Core_DAO::$_nullArray,
+ $params['honor'], $null,
$honorId, NULL,
$form->_values['honoree_profile_id']
);
FROM civicrm_contribution_product
WHERE contribution_id = {$id}
";
- $dao = CRM_Core_DAO::executeQuery($sql,
- CRM_Core_DAO::$_nullArray
- );
+ $dao = CRM_Core_DAO::executeQuery($sql);
if ($dao->fetch()) {
$this->_premiumID = $dao->id;
$this->_productDAO = $dao;
INNER JOIN civicrm_contact ct ON ( co.contact_id = ct.id )
WHERE co.id IN ( $contribIDs )";
- $dao = CRM_Core_DAO::executeQuery($query,
- CRM_Core_DAO::$_nullArray
- );
+ $dao = CRM_Core_DAO::executeQuery($query);
while ($dao->fetch()) {
$rows[] = [
FROM civicrm_contribution
WHERE contribution_status_id != 2
AND {$this->_componentClause}";
- $count = CRM_Core_DAO::singleValueQuery($query,
- CRM_Core_DAO::$_nullArray
- );
+ $count = CRM_Core_DAO::singleValueQuery($query);
if ($count != 0) {
CRM_Core_Error::statusBounce(ts('Please select only online contributions with Pending status.'));
}
civicrm_contribution co
WHERE co.contact_id = c.id
AND co.id IN ( $contribIDs )";
- $dao = CRM_Core_DAO::executeQuery($query,
- CRM_Core_DAO::$_nullArray
- );
+ $dao = CRM_Core_DAO::executeQuery($query);
// build a row for each contribution id
$this->_rows = [];
WHERE c.id IN ( $contributionIDs )";
$rows = [];
- $dao = CRM_Core_DAO::executeQuery($query,
- CRM_Core_DAO::$_nullArray
- );
+ $dao = CRM_Core_DAO::executeQuery($query);
while ($dao->fetch()) {
$rows[$dao->contribution_id]['component'] = $dao->participant_id ? 'event' : 'contribute';
// civihr/uk.co.compucorp.civicrm.hrcore
'HRCore_Info',
- // nz.co.fuzion.entitysetting
- 'CiviCRM setting Spec',
-
];
// Handle Legacy Multisite caching group.
$extensions = CRM_Extension_System::singleton()->getManager();
$groups[] = 'descendant groups for an org';
}
}
+ $entitySettingExtensionStatus = $extensions->getStatus('nz.co.fuzion.entitysetting');
+ if ($multisiteExtensionStatus == $extensions::STATUS_INSTALLED) {
+ $extension_version = civicrm_api3('Extension', 'get', ['key' => 'nz.co.fuzion.entitysetting'])['values'][0]['version'];
+ if (version_compare($extension_version, '1.3', '<')) {
+ Civi::log()->warning(
+ 'CRM_Core_BAO_Cache_PSR is deprecated for entity setting extension, you should upgrade to the latest version to avoid this warning, this code will be removed at the end of 2019',
+ ['civi.tag' => 'deprecated']
+ );
+ $groups[] = 'CiviCRM setting Spec';
+ }
+ }
return $groups;
}
FROM $tableName
WHERE $columnName is not null
";
- $count = CRM_Core_DAO::singleValueQuery($query,
- CRM_Core_DAO::$_nullArray
- );
+ $count = CRM_Core_DAO::singleValueQuery($query);
if ($count > 0) {
$query = "
SELECT extends
}
}
- $contactId = CRM_Contact_BAO_Contact::createProfileContact($params, CRM_Core_DAO::$_nullArray);
+ $contactId = CRM_Contact_BAO_Contact::createProfileContact($params);
$ufmatch->contact_id = $contactId;
$ufmatch->uf_name = $uniqId;
}
*
* @return bool
*/
- public static function &getValues(&$params, &$values) {
+ public static function &getValues(&$params = [], &$values = []) {
$websites = [];
$website = new CRM_Core_DAO_Website();
$website->contact_id = $params['contact_id'];
*
* @return CRM_Event_BAO_Participant|null the found object or null
*/
- public static function getValues(&$params, &$values, &$ids) {
+ public static function getValues(&$params, &$values = [], &$ids = []) {
if (empty($params)) {
return NULL;
}
// email sending
if (!empty($params['send_receipt'])) {
$fetchParticipantVals = ['id' => $this->_participantId];
- CRM_Event_BAO_Participant::getValues($fetchParticipantVals, $participantDetails, CRM_Core_DAO::$_nullArray);
+ CRM_Event_BAO_Participant::getValues($fetchParticipantVals, $participantDetails);
$participantParams = array_merge($params, $participantDetails[$this->_participantId]);
$mailSent = $this->emailReceipt($participantParams);
}
*
* @return CRM_Contribute_BAO_ContributionType
*/
- public static function retrieve(&$params, &$defaults, &$allValues = []) {
+ public static function retrieve(&$params, &$defaults = [], &$allValues = []) {
$financialTypeAccount = new CRM_Financial_DAO_EntityFinancialAccount();
$financialTypeAccount->copyValues($params);
$financialTypeAccount->find();
protected static function getContributionAndParamsInFormatForRecordFinancialTransaction($contributionId) {
$getInfoOf['id'] = $contributionId;
$defaults = [];
- $contributionDAO = CRM_Contribute_BAO_Contribution::retrieve($getInfoOf, $defaults, CRM_Core_DAO::$_nullArray);
+ $contributionDAO = CRM_Contribute_BAO_Contribution::retrieve($getInfoOf, $defaults);
// build params for recording financial trxn entry
$params['contribution'] = $contributionDAO;
$params = [
'id' => $this->_id,
];
- $financialAccount = CRM_Financial_BAO_FinancialAccount::retrieve($params, CRM_Core_DAO::$_nullArray);
+ $financialAccount = CRM_Financial_BAO_FinancialAccount::retrieve($params);
$financialAccountTypeId = key(CRM_Core_PseudoConstant::accountOptionValues('financial_account_type', NULL, " AND v.name LIKE 'Asset' "));
if ($financialAccount->financial_account_type_id == $financialAccountTypeId
&& strtolower($financialAccount->account_type_code) == 'ar'
$params['entity_id'] = $dao->id;
$params['entity_table'] = 'civicrm_financial_type';
- CRM_Financial_BAO_FinancialTypeAccount::retrieve($params, CRM_Core_DAO::$_nullArray, $financialAccountIds);
+ $null = [];
+ CRM_Financial_BAO_FinancialTypeAccount::retrieve($params, $null, $financialAccountIds);
foreach ($financialAccountIds as $key => $values) {
if (!empty($financialAccounts[$values['financial_account_id']])) {
* @return int
*/
public static function add(&$params) {
- return CRM_Contact_BAO_Contact::createProfileContact($params, CRM_Core_DAO::$_nullArray);
+ return CRM_Contact_BAO_Contact::createProfileContact($params);
}
/**
if ($force || !isset(\Civi::$statics[__CLASS__]['columnsOf'][$table])) {
$from = (substr($table, 0, 4) == 'log_') ? "`{$this->db}`.$table" : $table;
CRM_Core_TemporaryErrorScope::ignoreException();
- $dao = CRM_Core_DAO::executeQuery("SHOW COLUMNS FROM $from", CRM_Core_DAO::$_nullArray, TRUE, NULL, FALSE, FALSE);
+ $dao = CRM_Core_DAO::executeQuery("SHOW COLUMNS FROM $from", [], TRUE, NULL, FALSE, FALSE);
if (is_a($dao, 'DB_Error')) {
return [];
}
* @param string $table
*/
private function createLogTableFor($table) {
- $dao = CRM_Core_DAO::executeQuery("SHOW CREATE TABLE $table", CRM_Core_DAO::$_nullArray, TRUE, NULL, FALSE, FALSE);
+ $dao = CRM_Core_DAO::executeQuery("SHOW CREATE TABLE $table", [], TRUE, NULL, FALSE, FALSE);
$dao->fetch();
$query = $dao->Create_Table;
$query = self::fixTimeStampAndNotNullSQL($query);
$query = preg_replace("/(,*\n*\) )ENGINE/m", "$cols\n) ENGINE", $query);
- CRM_Core_DAO::executeQuery($query, CRM_Core_DAO::$_nullArray, TRUE, NULL, FALSE, FALSE);
+ CRM_Core_DAO::executeQuery($query, [], TRUE, NULL, FALSE, FALSE);
$columns = implode(', ', $this->columnsOf($table));
- CRM_Core_DAO::executeQuery("INSERT INTO `{$this->db}`.log_$table ($columns, log_conn_id, log_user_id, log_action) SELECT $columns, @uniqueID, @civicrm_user_id, 'Initialization' FROM {$table}", CRM_Core_DAO::$_nullArray, TRUE, NULL, FALSE, FALSE);
+ CRM_Core_DAO::executeQuery("INSERT INTO `{$this->db}`.log_$table ($columns, log_conn_id, log_user_id, log_action) SELECT $columns, @uniqueID, @civicrm_user_id, 'Initialization' FROM {$table}", [], TRUE, NULL, FALSE, FALSE);
$this->tables[] = $table;
if (empty($this->logs)) {
*
* @return CRM_Member_BAO_Membership|CRM_Core_Error
*/
- public static function create(&$params, &$ids, $skipRedirect = FALSE) {
+ public static function create(&$params, &$ids = [], $skipRedirect = FALSE) {
// always calculate status if is_override/skipStatusCal is not true.
// giving respect to is_override during import. CRM-4012
AND mp.membership_id = " . CRM_Utils_Type::escape($membershipID, 'Integer')
. " ORDER BY mp.id DESC";
- return CRM_Core_DAO::singleValueQuery($query,
- CRM_Core_DAO::$_nullArray
- );
+ return CRM_Core_DAO::singleValueQuery($query);
}
/**
// set all other defaults to false.
if (!empty($params['is_default'])) {
$query = "UPDATE civicrm_membership_status SET is_default = 0";
- CRM_Core_DAO::executeQuery($query,
- CRM_Core_DAO::$_nullArray
- );
+ CRM_Core_DAO::executeQuery($query);
}
// action is taken depending upon the mode
*
* @return CRM_Price_BAO_LineItem
*/
- public static function retrieve(&$params, &$defaults) {
+ public static function retrieve(&$params = [], &$defaults = []) {
$lineItem = new CRM_Price_BAO_LineItem();
$lineItem->copyValues($params);
if ($lineItem->find(TRUE)) {
$updatedContributionDAO->save();
// adjusted amount financial_trxn creation
$updatedContribution = CRM_Contribute_BAO_Contribution::getValues(
- ['id' => $contributionId],
- CRM_Core_DAO::$_nullArray,
- CRM_Core_DAO::$_nullArray
+ ['id' => $contributionId]
);
$toFinancialAccount = CRM_Contribute_PseudoConstant::getRelationalFinancialAccount($updatedContribution->financial_type_id, 'Accounts Receivable Account is');
$adjustedTrxnValues = [
$tempFinancialTrxnID = ['id' => $adjustedTrxn->id];
}
}
- $lineObj = CRM_Price_BAO_LineItem::retrieve($lineParams, CRM_Core_DAO::$_nullArray);
+ $lineObj = CRM_Price_BAO_LineItem::retrieve($lineParams);
// insert financial items
// ensure entity_financial_trxn table has a linking of it.
CRM_Financial_BAO_FinancialItem::add($lineObj, $updatedContribution, NULL, $tempFinancialTrxnID);
* @return Object
*/
public function runQuery($query) {
- return CRM_Core_DAO::executeQuery($query,
- CRM_Core_DAO::$_nullArray
- );
+ return CRM_Core_DAO::executeQuery($query);
}
/**
$sqlDropFK = "ALTER TABLE `civicrm_msg_template`
DROP FOREIGN KEY `{$dao->CONSTRAINT_NAME}`,
DROP KEY `{$dao->CONSTRAINT_NAME}`";
- CRM_Core_DAO::executeQuery($sqlDropFK, CRM_Core_DAO::$_nullArray, TRUE, NULL, FALSE, FALSE);
+ CRM_Core_DAO::executeQuery($sqlDropFK, [], TRUE, NULL, FALSE, FALSE);
}
}
$query = "
ALTER TABLE civicrm_domain ADD contact_id INT( 10 ) UNSIGNED NULL DEFAULT NULL COMMENT 'FK to Contact ID. This is specifically not an FK to avoid circular constraints',
ADD CONSTRAINT FK_civicrm_domain_contact_id FOREIGN KEY (contact_id) REFERENCES civicrm_contact(id);";
- CRM_Core_DAO::executeQuery($query, CRM_Core_DAO::$_nullArray, TRUE, NULL, FALSE, FALSE);
+ CRM_Core_DAO::executeQuery($query, [], TRUE, NULL, FALSE, FALSE);
$query = '
SELECT cd.id, cd.name, ce.email FROM civicrm_domain cd
CRM_Utils_String::extractName($name, $params);
- return CRM_Contact_BAO_Contact::createProfileContact($params,
- CRM_Core_DAO::$_nullArray
- );
+ return CRM_Contact_BAO_Contact::createProfileContact($params);
}
}
}
return $match;
}
- return CRM_Core_DAO::$_nullArray;
+ return [];
}
/**
padding: 4px;
margin: 0;
line-height: 15px;
+ white-space: initial;
}
.crm-container .action-item-wrap {
var buttonContainers = '.crm-submit-buttons, .action-link',
buttons = [],
added = [];
- $(buttonContainers, $el).find('input.crm-form-submit, a.button').each(function() {
+ $(buttonContainers, $el).find('input.crm-form-submit, a.button, button').each(function() {
var $el = $(this),
label = $el.is('input') ? $el.attr('value') : $el.text(),
identifier = $el.attr('name') || $el.attr('href');
('Student', 'Discount membership for full-time students.', " . $contact_id . ", 1, 50, 'year', 1, 'rolling', null, null, 7, 'b_a', 'Public', 2, 1),
('Lifetime', 'Lifetime membership.', " . $contact_id . ", 2, 1200, 'lifetime', 1, 'rolling', null, null, 7, 'b_a', 'Admin', 3, 1);
";
- CRM_Core_DAO::executeQuery($membershipType, CRM_Core_DAO::$_nullArray);
+ CRM_Core_DAO::executeQuery($membershipType);
}
public function addMembership() {
}
}
- CRM_Core_DAO::executeQuery($membership, CRM_Core_DAO::$_nullArray);
+ CRM_Core_DAO::executeQuery($membership);
- CRM_Core_DAO::executeQuery($activity, CRM_Core_DAO::$_nullArray);
+ CRM_Core_DAO::executeQuery($activity);
}
/**
( NULL, 1, 1, 1, 'E 11B Woodbridge Path SW', 11, 'B', NULL, 'Woodbridge', 'Path', NULL, NULL, NULL, NULL, NULL, 'Dayton', NULL, 1034, NULL, '45417', NULL, 1228, 39.7531, -84.2471, NULL),
( NULL, 1, 1, 1, 'E 581O Lincoln Dr SW', 581, 'O', NULL, 'Lincoln', 'Dr', NULL, NULL, NULL, NULL, NULL, 'Santa Fe', NULL, 1030, NULL, '87594', NULL, 1228, 35.5212, -105.982, NULL)
";
- CRM_Core_DAO::executeQuery($event, CRM_Core_DAO::$_nullArray);
+ CRM_Core_DAO::executeQuery($event);
$sql = "SELECT id from civicrm_address where street_address = 'S 14S El Camino Way E'";
- $eventAdd1 = CRM_Core_DAO::singleValueQuery($sql, CRM_Core_DAO::$_nullArray);
+ $eventAdd1 = CRM_Core_DAO::singleValueQuery($sql);
$sql = "SELECT id from civicrm_address where street_address = 'E 11B Woodbridge Path SW'";
- $eventAdd2 = CRM_Core_DAO::singleValueQuery($sql, CRM_Core_DAO::$_nullArray);
+ $eventAdd2 = CRM_Core_DAO::singleValueQuery($sql);
$sql = "SELECT id from civicrm_address where street_address = 'E 581O Lincoln Dr SW'";
- $eventAdd3 = CRM_Core_DAO::singleValueQuery($sql, CRM_Core_DAO::$_nullArray);
+ $eventAdd3 = CRM_Core_DAO::singleValueQuery($sql);
$event = "INSERT INTO civicrm_email (contact_id, location_type_id, email, is_primary, is_billing, on_hold, hold_date, reset_date)
VALUES
(NULL, 1, 'tournaments@example.org', 0, 0, 0, NULL, NULL),
(NULL, 1, 'celebration@example.org', 0, 0, 0, NULL, NULL)
";
- CRM_Core_DAO::executeQuery($event, CRM_Core_DAO::$_nullArray);
+ CRM_Core_DAO::executeQuery($event);
$sql = "SELECT id from civicrm_email where email = 'development@example.org'";
- $eventEmail1 = CRM_Core_DAO::singleValueQuery($sql, CRM_Core_DAO::$_nullArray);
+ $eventEmail1 = CRM_Core_DAO::singleValueQuery($sql);
$sql = "SELECT id from civicrm_email where email = 'tournaments@example.org'";
- $eventEmail2 = CRM_Core_DAO::singleValueQuery($sql, CRM_Core_DAO::$_nullArray);
+ $eventEmail2 = CRM_Core_DAO::singleValueQuery($sql);
$sql = "SELECT id from civicrm_email where email = 'celebration@example.org'";
- $eventEmail3 = CRM_Core_DAO::singleValueQuery($sql, CRM_Core_DAO::$_nullArray);
+ $eventEmail3 = CRM_Core_DAO::singleValueQuery($sql);
$event = "INSERT INTO civicrm_phone (contact_id, location_type_id, is_primary, is_billing, mobile_provider_id, phone, phone_type_id)
VALUES
(NULL, 1, 0, 0, NULL,'204 223-1000', '1'),
(NULL, 1, 0, 0, NULL,'303 323-1000', '1')
";
- CRM_Core_DAO::executeQuery($event, CRM_Core_DAO::$_nullArray);
+ CRM_Core_DAO::executeQuery($event);
$sql = "SELECT id from civicrm_phone where phone = '204 222-1000'";
- $eventPhone1 = CRM_Core_DAO::singleValueQuery($sql, CRM_Core_DAO::$_nullArray);
+ $eventPhone1 = CRM_Core_DAO::singleValueQuery($sql);
$sql = "SELECT id from civicrm_phone where phone = '204 223-1000'";
- $eventPhone2 = CRM_Core_DAO::singleValueQuery($sql, CRM_Core_DAO::$_nullArray);
+ $eventPhone2 = CRM_Core_DAO::singleValueQuery($sql);
$sql = "SELECT id from civicrm_phone where phone = '303 323-1000'";
- $eventPhone3 = CRM_Core_DAO::singleValueQuery($sql, CRM_Core_DAO::$_nullArray);
+ $eventPhone3 = CRM_Core_DAO::singleValueQuery($sql);
$event = "INSERT INTO civicrm_loc_block ( address_id, email_id, phone_id, address_2_id, email_2_id, phone_2_id)
VALUES
( $eventAdd3, $eventEmail3, $eventPhone3, NULL,NULL,NULL)
";
- CRM_Core_DAO::executeQuery($event, CRM_Core_DAO::$_nullArray);
+ CRM_Core_DAO::executeQuery($event);
$sql = "SELECT id from civicrm_loc_block where phone_id = $eventPhone1 AND email_id = $eventEmail1 AND address_id = $eventAdd1";
- $eventLok1 = CRM_Core_DAO::singleValueQuery($sql, CRM_Core_DAO::$_nullArray);
+ $eventLok1 = CRM_Core_DAO::singleValueQuery($sql);
$sql = "SELECT id from civicrm_loc_block where phone_id = $eventPhone2 AND email_id = $eventEmail2 AND address_id = $eventAdd2";
- $eventLok2 = CRM_Core_DAO::singleValueQuery($sql, CRM_Core_DAO::$_nullArray);
+ $eventLok2 = CRM_Core_DAO::singleValueQuery($sql);
$sql = "SELECT id from civicrm_loc_block where phone_id = $eventPhone3 AND email_id = $eventEmail3 AND address_id = $eventAdd3";
- $eventLok3 = CRM_Core_DAO::singleValueQuery($sql, CRM_Core_DAO::$_nullArray);
+ $eventLok3 = CRM_Core_DAO::singleValueQuery($sql);
//create event fees
$optionGroup = "INSERT INTO civicrm_option_group ( name, is_reserved, is_active)
( 'civicrm_event.amount.2', 0, 1),
( 'civicrm_event.amount.3', 0, 1)
";
- CRM_Core_DAO::executeQuery($optionGroup, CRM_Core_DAO::$_nullArray);
+ CRM_Core_DAO::executeQuery($optionGroup);
$sql = "SELECT max(id) from civicrm_option_group where name = 'civicrm_event.amount.1'";
- $page1 = CRM_Core_DAO::singleValueQuery($sql, CRM_Core_DAO::$_nullArray);
+ $page1 = CRM_Core_DAO::singleValueQuery($sql);
$sql = "SELECT max(id) from civicrm_option_group where name = 'civicrm_event.amount.2'";
- $page2 = CRM_Core_DAO::singleValueQuery($sql, CRM_Core_DAO::$_nullArray);
+ $page2 = CRM_Core_DAO::singleValueQuery($sql);
$sql = "SELECT max(id) from civicrm_option_group where name = 'civicrm_event.amount.3'";
- $page3 = CRM_Core_DAO::singleValueQuery($sql, CRM_Core_DAO::$_nullArray);
+ $page3 = CRM_Core_DAO::singleValueQuery($sql);
$optionValue = "INSERT INTO civicrm_option_value (option_group_id, label, value, is_default, weight, is_optgroup, is_reserved, is_active)
VALUES
($page3, 'Junior Stars (ages 9-12)', '1000', 0, 2, 0, 0, 1),
($page3, 'Super Stars (ages 13-18)', '1500', 0, 3, 0, 0, 1)";
- CRM_Core_DAO::executeQuery($optionValue, CRM_Core_DAO::$_nullArray);
+ CRM_Core_DAO::executeQuery($optionValue);
$sql = "SELECT max(id) FROM civicrm_option_value WHERE civicrm_option_value.option_group_id = $page1 AND civicrm_option_value.weight=2";
- $defaultFee1 = CRM_Core_DAO::singleValueQuery($sql, CRM_Core_DAO::$_nullArray);
+ $defaultFee1 = CRM_Core_DAO::singleValueQuery($sql);
$sql = "SELECT max(id) FROM civicrm_option_value WHERE civicrm_option_value.option_group_id = $page2 AND civicrm_option_value.weight=2";
- $defaultFee2 = CRM_Core_DAO::singleValueQuery($sql, CRM_Core_DAO::$_nullArray);
+ $defaultFee2 = CRM_Core_DAO::singleValueQuery($sql);
$sql = "SELECT max(id) FROM civicrm_option_value WHERE civicrm_option_value.option_group_id = $page3 AND civicrm_option_value.weight=2";
- $defaultFee3 = CRM_Core_DAO::singleValueQuery($sql, CRM_Core_DAO::$_nullArray);
+ $defaultFee3 = CRM_Core_DAO::singleValueQuery($sql);
$event = "INSERT INTO civicrm_event
( title, summary, description, event_type_id, participant_listing_id, is_public, start_date, end_date, is_online_registration, registration_link_text, max_participants, event_full_text, is_monetary, financial_type_id, is_map, is_active, fee_label, is_show_location, loc_block_id,intro_text, footer_text, confirm_title, confirm_text, confirm_footer_text, is_email_confirm, confirm_email_text, confirm_from_name, confirm_from_email, cc_confirm, bcc_confirm, default_fee_id, thankyou_title, thankyou_text, thankyou_footer_text, is_pay_later, pay_later_text, pay_later_receipt, is_multiple_registrations, allow_same_participant_emails )
( 'Summer Solstice Festival Day Concert', 'Festival Day is coming! Join us and help support your parks.', 'We will gather at noon, learn a song all together, and then join in a joyous procession to the pavilion. We will be one of many groups performing at this wonderful concert which benefits our city parks.', 5, 1, 1, '2011-06-01 12:00:00', '2011-06-01 17:00:00', 1, 'Register Now', 50, 'We have all the singers we can handle. Come to the pavilion anyway and join in from the audience.', 1, 2, NULL, 1, 'Festival Fee', 1, $eventLok2, 'Complete the form below and click Continue to register online for the festival. Or you can register by calling us at 204 222-1000 ext 22.', '', 'Confirm Your Registration Information', '', '', 1, 'This email confirms your registration. If you have questions or need to change your registration - please do not hesitate to call us.', 'Event Dept.', 'events@example.org', '', NULL, {$defaultFee2}, 'Thanks for Your Joining In!', '<p>Thank you for your support. Your participation will help build new parks.</p><p>Please tell your friends and colleagues about the concert.</p>', '<p><a href=https://civicrm.org>Back to CiviCRM Home Page</a></p>', 0, NULL, NULL, 1, 0 ),
( 'Rain-forest Cup Youth Soccer Tournament', 'Sign up your team to participate in this fun tournament which benefits several Rain-forest protection groups in the Amazon basin.', 'This is a FYSA Sanctioned Tournament, which is open to all USSF/FIFA affiliated organizations for boys and girls in age groups: U9-U10 (6v6), U11-U12 (8v8), and U13-U17 (Full Sided).', 3, 1, 1, '2011-12-27 07:00:00', '2011-12-29 17:00:00', 1, 'Register Now', 500, 'Sorry! All available team slots for this tournament have been filled. Contact Jill Futbol for information about the waiting list and next years event.', 1, 4, NULL, 1, 'Tournament Fees',1, $eventLok3, 'Complete the form below to register your team for this year''s tournament.', '<em>A Soccer Youth Event</em>', 'Review and Confirm Your Registration Information', '', '<em>A Soccer Youth Event</em>', 1, 'Contact our Tournament Director for eligibility details.', 'Tournament Director', 'tournament@example.org', '', NULL, {$defaultFee3}, 'Thanks for Your Support!', '<p>Thank you for your support. Your participation will help save thousands of acres of rainforest.</p>', '<p><a href=https://civicrm.org>Back to CiviCRM Home Page</a></p>', 0, NULL, NULL, 0, 0 )
";
- CRM_Core_DAO::executeQuery($event, CRM_Core_DAO::$_nullArray);
+ CRM_Core_DAO::executeQuery($event);
}
public function addParticipant() {
$sql = "SELECT DISTINCT(contact_id), id, total_amount from civicrm_contribution LIMIT 200";
- $contriInfo = CRM_Core_DAO::executeQuery($sql, CRM_Core_DAO::$_nullArray);
+ $contriInfo = CRM_Core_DAO::executeQuery($sql);
$prevContactID = NULL;
(43, 1, 1, 800.00, 'month', 3, 1, 4, '2010-07-01 10:11:09', '2010-06-23 10:11:14', '2010-06-23 10:11:18', NULL, NULL, '2010-04-01 10:11:40', NULL, NULL, 5, 0),
(32, 1, 1, 600.00, 'month', 1, 1, 3, '2010-06-01 10:12:35', '2010-05-14 10:12:44', '2010-05-14 10:12:52', NULL, NULL, '2010-08-01 10:13:11', NULL, NULL, 5, 0);
";
- CRM_Core_DAO::executeQuery($pledge, CRM_Core_DAO::$_nullArray);
+ CRM_Core_DAO::executeQuery($pledge);
}
public function addPledgePayment() {
(3, 13, 200.00, '2010-07-01 10:59:35', '2010-06-28 10:59:41', 1, 1),
(3, null, 200.00, '2010-08-01 11:00:12', null, 0, 2);
";
- CRM_Core_DAO::executeQuery($pledgePayment, CRM_Core_DAO::$_nullArray);
+ CRM_Core_DAO::executeQuery($pledgePayment);
}
public function addMembershipPayment() {
WHERE contribution_page_id IS NULL AND
total_amount = {$amount[$i]} limit 0, 50 ";
- $contributionDAO = CRM_Core_DAO::executeQuery($contributionSQL, CRM_Core_DAO::$_nullArray);
+ $contributionDAO = CRM_Core_DAO::executeQuery($contributionSQL);
while ($contributionDAO->fetch()) {
$contributionsArray[] = $contributionDAO->id;
SELECT id
FROM civicrm_membership
WHERE civicrm_membership.membership_type_id = {$j} limit 0, 50";
- $membershipDAO = CRM_Core_DAO::executeQuery($membershipSQL, CRM_Core_DAO::$_nullArray);
+ $membershipDAO = CRM_Core_DAO::executeQuery($membershipSQL);
while ($membershipDAO->fetch()) {
$membershipArray[] = $membershipDAO->id;
+--------------------------------------------------------------------+
*}
<div class="help">
- <p>
+ <p>
{ts}When migrating a site to a new server, the paths and URLs of your CiviCRM installation may change. {/ts}
- </p>
- <p>
+ </p>
+ <p>
{capture assign="pathsURL"}{crmURL p="civicrm/admin/setting/path" q="reset=1"}{/capture}
{capture assign="urlsURL"}{crmURL p="civicrm/admin/setting/url" q="reset=1"}{/capture}
{ts 1=$pathsURL 2=$urlsURL}The old paths and URLs may be retained in some database records. Use this form to clear caches or to reset paths to their defaults. If you need further customizations, then update the <a href="%1">Directories</a> and <a href="%2">Resource URLs</a>.{/ts}
- </p>
+ </p>
</div>
<div class="crm-block crm-form-block crm-config-backend-form-block">
- <div class="crm-submit-buttons">
- <span class="crm-button crm-i-button">
- <i class="crm-i fa-undo"></i>
- {$form._qf_UpdateConfigBackend_next_cleanup.html}
- </span>
- <span class="crm-button crm-i-button">
- <i class="crm-i fa-terminal"></i>
- {$form._qf_UpdateConfigBackend_next_resetpaths.html}
- </span>
- </div>
- <div>{include file="CRM/common/formButtons.tpl" location="bottom"}</div>
-<div class="spacer"></div>
+ <div>{include file="CRM/common/formButtons.tpl" location="bottom"}</div>
</div>
);
$softParam = array('soft_credit_type_id' => 1);
- $honoreeContactId = CRM_Contact_BAO_Contact::createProfileContact($params, CRM_Core_DAO::$_nullArray,
+ $null = [];
+ $honoreeContactId = CRM_Contact_BAO_Contact::createProfileContact($params, $null,
NULL, NULL, $honoreeProfileId
);
'account_relationship' => $relationTypeId,
'financial_account_id' => 7,
);
- CRM_Financial_BAO_FinancialTypeAccount::add($financialParams, CRM_Core_DAO::$_nullArray);
+ CRM_Financial_BAO_FinancialTypeAccount::add($financialParams);
$this->assertNotEmpty($optionValue['values'][$optionValue['id']]['value']);
return $optionValue['values'][$optionValue['id']]['value'];
}