*
* Generated from xml/schema/CRM/Campaign/Campaign.xml
* DO NOT EDIT. Generated by CRM_Core_CodeGen
- * (GenCodeChecksum:7c80d509cf26b13e8284140579330818)
+ * (GenCodeChecksum:75a9a33157dcd3411e3072a2b3740b0f)
*/
/**
*/
public static function indices($localize = TRUE) {
$indices = [
- 'UI_campaign_name' => [
- 'name' => 'UI_campaign_name',
+ 'UI_name' => [
+ 'name' => 'UI_name',
'field' => [
0 => 'name',
],
'localizable' => FALSE,
- 'sig' => 'civicrm_campaign::0::name',
+ 'unique' => TRUE,
+ 'sig' => 'civicrm_campaign::1::name',
],
'UI_campaign_type_id' => [
'name' => 'UI_campaign_type_id',
$this->addTask(ts('Create index %1', [1 => 'civicrm_cache.UI_group_name_path']), 'addIndex', 'civicrm_cache', [['group_name', 'path']], 'UI');
$this->addTask(ts('Create index %1', [1 => 'civicrm_cache.index_expired_date']), 'addIndex', 'civicrm_cache', [['expired_date']], 'index');
$this->addTask(ts('Update Saved Mapping for contribution import', [1 => $rev]), 'convertMappingFieldsToApi4StyleNames', $rev);
+
+ $this->addTask(ts('Drop index %1', [1 => 'civicrm_campaign.UI_campaign_name']), 'dropIndex', 'civicrm_campaign', 'UI_campaign_name');
+ $this->addTask(ts('Create index %1', [1 => 'civicrm_campaign.UI_name']), 'addIndex', 'civicrm_campaign', 'name', 'UI');
}
/**
UPDATE civicrm_payment_processor
SET {localize field="title"}title = name{/localize};
+{* https://github.com/civicrm/civicrm-core/pull/25994 *}
+UPDATE civicrm_campaign c1, civicrm_campaign c2
+ SET c2.name = CONCAT(c2.name, '_', c2.id)
+ WHERE c2.name = c1.name AND c2.id > c1.id;
+
UPDATE civicrm_navigation SET url = 'civicrm/import/contribution?reset=1' WHERE url = 'civicrm/contribute/import?reset=1';
<add>3.3</add>
</field>
<index>
- <name>UI_campaign_name</name>
+ <name>UI_name</name>
<fieldName>name</fieldName>
- <add>5.34</add>
+ <unique>true</unique>
+ <add>5.61</add>
</index>
<field>
<name>title</name>