Merge pull request #4054 from eileenmcnaughton/CRM-15237
[civicrm-core.git] / CRM / Upgrade / Incremental / sql / 3.4.alpha2.mysql.tpl
1 -- CRM-7494
2 -- update navigation.
3
4 UPDATE civicrm_navigation
5 SET name = 'Survey Report (Detail)',
6 label = 'Survey Report (Detail)'
7 WHERE name LIKE 'Walk List Survey Report';
8
9 -- update report instance.
10
11 UPDATE civicrm_report_instance
12 SET title = 'Survey Report (Detail)',
13 description = 'Detailed report for canvassing, phone-banking, walk lists or other surveys.'
14 WHERE report_id LIKE 'survey/detail';
15
16 -- update report template option values.
17 {if $multilingual}
18
19 {foreach from=$locales item=loc}
20
21 UPDATE civicrm_option_value val
22 INNER JOIN civicrm_option_group grp ON ( grp.id = val.option_group_id )
23 SET val.label_{$loc} = '{ts escape="sql"}Survey Report (Detail){/ts}',
24 val.description_{$loc} = '{ts escape="sql"}Detailed report for canvassing, phone-banking, walk lists or other surveys.{/ts}'
25 WHERE val.name = 'CRM_Report_Form_Campaign_SurveyDetails'
26 AND grp.name = 'report_template';
27
28 {/foreach}
29
30 {else}
31
32 UPDATE civicrm_option_value val
33 INNER JOIN civicrm_option_group grp ON ( grp.id = val.option_group_id )
34 SET val.label = '{ts escape="sql"}Survey Report (Detail){/ts}',
35 val.description = '{ts escape="sql"}Detailed report for canvassing, phone-banking, walk lists or other surveys.{/ts}'
36 WHERE val.name = 'CRM_Report_Form_Campaign_SurveyDetails'
37 AND grp.name = 'report_template';
38
39 {/if}
40
41 -- get rid of standalone tables CRM-7672
42 DROP TABLE IF EXISTS civicrm_openid_associations;
43 DROP TABLE IF EXISTS civicrm_openid_nonces;
44
45 -- insert 5395 Logo style event name badge CRM-7695
46 SELECT @option_group_id_eventBadge := max(id) from civicrm_option_group where name = 'event_badge';
47 {if $multilingual}
48 INSERT INTO civicrm_option_value
49 (option_group_id, {foreach from=$locales item=locale}label_{$locale}, description_{$locale}, {/foreach} value, name, weight, is_active, component_id )
50 VALUES
51 (@option_group_id_eventBadge , {foreach from=$locales item=locale}'5395 with Logo', 'Avery 5395 compatible labels with logo (4 up by 2, 59.2mm x 85.7mm)', {/foreach} '4', 'CRM_Event_Badge_Logo5395', 1, 1, NULL );
52 {else}
53 INSERT INTO civicrm_option_value
54 (option_group_id, label, description, value, name, weight, is_active, component_id )
55 VALUES
56 (@option_group_id_eventBadge , '{ts escape="sql"}5395 with Logo{/ts}', '{ts escape="sql"}Avery 5395 compatible labels with logo (4 up by 2, 59.2mm x 85.7mm){/ts}', '4', 'CRM_Event_Badge_Logo5395', 1, 1, NULL );
57 {/if}