Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
Core
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Container registry
Model registry
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
justinfreeman (Agileware)
Core
Commits
8e9bbf87
Commit
8e9bbf87
authored
11 years ago
by
Kurund Jalmi
Browse files
Options
Downloads
Plain Diff
Merge pull request #1868 from dlobo/CRM-13665
CRM-13665 - Make upgrade fault tolerant for merging activity contacts
parents
69b8c5bb
3a88e331
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
CRM/Upgrade/Incremental/php/FourFour.php
+6
-1
6 additions, 1 deletion
CRM/Upgrade/Incremental/php/FourFour.php
with
6 additions
and
1 deletion
CRM/Upgrade/Incremental/php/FourFour.php
+
6
−
1
View file @
8e9bbf87
...
...
@@ -133,7 +133,7 @@ class CRM_Upgrade_Incremental_php_FourFour {
2
=>
array
(
'Fattorini Name Badge 100x65'
,
'String'
),
3
=>
array
(
'Hanging Badge 3-3/4" x 4-3"/4'
,
'String'
),
);
foreach
(
$insertStatements
as
$values
)
{
$query
=
'INSERT INTO civicrm_option_value (`option_group_id`, `label`, `value`, `name`, `grouping`, `filter`, `is_default`, `weight`, `description`, `is_optgroup`, `is_reserved`, `is_active`, `component_id`, `visibility_id`) VALUES'
.
$values
;
CRM_Core_DAO
::
executeQuery
(
$query
,
$queryParams
);
...
...
@@ -193,6 +193,10 @@ VALUES
$dao
=
CRM_Core_DAO
::
executeQuery
(
$query
);
}
// sometimes an user does not make a clean backup and the above table
// already exists, so lets delete this table - CRM-13665
$query
=
"DROP TABLE civicrm_activity_contact"
;
$dao
=
CRM_Core_DAO
::
executeQuery
(
$query
);
$query
=
"
CREATE TABLE IF NOT EXISTS civicrm_activity_contact (
...
...
@@ -208,6 +212,7 @@ CREATE TABLE IF NOT EXISTS civicrm_activity_contact (
$dao
=
CRM_Core_DAO
::
executeQuery
(
$query
);
$query
=
"
INSERT INTO civicrm_activity_contact (activity_id, contact_id, record_type_id)
SELECT activity_id, target_contact_id,
{
$targetID
}
as record_type_id
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment