class CRM_Upgrade_Incremental_php_FourThree {
const BATCH_SIZE = 5000;
+ /**
+ * @param $errors
+ *
+ * @return bool
+ */
function verifyPreDBstate(&$errors) {
return TRUE;
}
* @param $rev string, a version number, e.g. '4.3.alpha1', '4.3.beta3', '4.3.0'
* @param null $currentVer
*
- * @internal param string $postUpgradeMessage , alterable
* @return void|bool
*/
function setPreUpgradeMessage(&$preUpgradeMessage, $rev, $currentVer = NULL) {
}
}
+ /**
+ * @param $rev
+ *
+ * @return bool
+ */
function upgrade_4_3_alpha1($rev) {
self::task_4_3_alpha1_checkDBConstraints();
return TRUE;
}
+ /**
+ * @param $rev
+ */
function upgrade_4_3_alpha2($rev) {
//CRM-11847
$isColumnPresent = CRM_Core_DAO::checkFieldExists('civicrm_dedupe_rule_group', 'is_default');
$this->addTask(ts('Upgrade DB to %1: SQL', array(1 => '4.3.alpha2')), 'task_4_3_x_runSql', $rev);
}
+ /**
+ * @param $rev
+ */
function upgrade_4_3_alpha3($rev) {
$this->addTask(ts('Upgrade DB to %1: SQL', array(1 => '4.3.alpha3')), 'task_4_3_x_runSql', $rev);
}
+ /**
+ * @param $rev
+ */
function upgrade_4_3_beta2($rev) {
$this->addTask(ts('Upgrade DB to %1: SQL', array(1 => '4.3.beta2')), 'task_4_3_x_runSql', $rev);
}
}
+ /**
+ * @param $rev
+ */
function upgrade_4_3_beta3($rev) {
$this->addTask(ts('Upgrade DB to %1: SQL', array(1 => '4.3.beta3')), 'task_4_3_x_runSql', $rev);
// CRM-12065
$this->addTask('Replace contribution_type to financial_type in table civicrm_saved_search', 'replaceContributionTypeId', $query, 'savedSearch');
}
+ /**
+ * @param $rev
+ */
function upgrade_4_3_beta4($rev) {
$this->addTask(ts('Upgrade DB to %1: SQL', array(1 => '4.3.beta4')), 'task_4_3_x_runSql', $rev);
// add indexes for civicrm_entity_financial_trxn
$this->addTask('Check/Add indexes for civicrm_entity_financial_trxn', 'task_4_3_x_checkIndexes', $rev);
}
+ /**
+ * @param $rev
+ */
function upgrade_4_3_beta5($rev) {
// CRM-12205
if (
$this->addTask(ts('Upgrade DB to %1: SQL', array(1 => '4.3.beta5')), 'task_4_3_x_runSql', $rev);
}
+ /**
+ * @param $rev
+ */
function upgrade_4_3_4($rev) {
$this->addTask(ts('Upgrade DB to %1: SQL', array(1 => '4.3.4')), 'task_4_3_x_runSql', $rev);
}
+ /**
+ * @param $rev
+ */
function upgrade_4_3_5($rev) {
// CRM-12156
$config = CRM_Core_Config::singleton();
$this->addTask(ts('Upgrade DB to %1: SQL', array(1 => '4.3.5')), 'task_4_3_x_runSql', $rev);
}
+ /**
+ * @param $rev
+ */
function upgrade_4_3_6($rev) {
//CRM-13094
$this->addTask(ts('Add missing constraints'), 'addMissingConstraints', $rev);
}
//CRM-11636
+ /**
+ * @return bool
+ */
function assignFinancialTypeToPriceRecords() {
$upgrade = new CRM_Upgrade_Form();
//here we update price set entries
return TRUE;
}
+ /**
+ * @return bool
+ */
static function _checkAndMigrateDefaultFinancialTypes() {
$modifiedDefaults = FALSE;
//insert types if not exists
return $modifiedDefaults;
}
+ /**
+ * @return bool
+ */
function createFinancialRecords() {
$upgrade = new CRM_Upgrade_Form();
return TRUE;
}
+ /**
+ * @return array
+ */
function createDomainContacts() {
$domainParams = $context = array();
$query = "
}
/**
- * change index and add missing constraints for civicrm_contribution_recur
+ * Change index and add missing constraints for civicrm_contribution_recur
*/
function addMissingConstraints(CRM_Queue_TaskContext $ctx) {
$query = "SHOW KEYS FROM `civicrm_contribution_recur` WHERE key_name = 'UI_contrib_payment_instrument_id'";
}
/**
- * replace contribution_type to financial_type in table
+ * Replace contribution_type to financial_type in table
* civicrm_saved_search and Structure civicrm_report_instance
*/
function replaceContributionTypeId(CRM_Queue_TaskContext $ctx, $query, $table) {