dev/mailing#59 Update the version of zetacomponents/mail package to 1.9.0 to be one...
[civicrm-core.git] / release-notes / 5.22.0.md
CommitLineData
b899efe3
AH
1# CiviCRM 5.22.0
2
80b16320 3Released February 5, 2020
b899efe3 4
80b16320 5- **[Synopsis](#synopsis)**
b899efe3
AH
6- **[Features](#features)**
7- **[Bugs resolved](#bugs)**
8- **[Miscellany](#misc)**
9- **[Credits](#credits)**
80b16320
AH
10- **[Feedback](#feedback)**
11
12## <a name="synopsis"></a>Synopsis
13
14| *Does this version...?* | |
15|:--------------------------------------------------------------- |:-------:|
423e1d8f
AF
16| Fix security vulnerabilities? | no |
17| **Change the database schema?** | **yes** |
18| **Alter the API?** | **yes** |
19| Require attention to configuration options? | no |
20| Fix problems installing or upgrading to a previous version? | no |
21| **Introduce features?** | **yes** |
22| **Fix bugs?** | **yes** |
b899efe3
AH
23
24## <a name="features"></a>Features
25
26### Core CiviCRM
27
423e1d8f
AF
28- **Field Names now Reserved Words in MySQL8
29 ([dev/core#1143](https://lab.civicrm.org/dev/core/issues/1143),
30 [dev/core#1144](https://lab.civicrm.org/dev/core/issues/1144) and
31 [dev/core#1480](https://lab.civicrm.org/dev/core/issues/1480):
32 [16179](https://github.com/civicrm/civicrm-core/pull/16179) and
33 [16182](https://github.com/civicrm/civicrm-core/pull/16182))**
b899efe3 34
423e1d8f
AF
35 Allows CiviCRM installations to run on MySQL8 and updates the test
36 infastructure to support MySQL8.
b899efe3 37
423e1d8f
AF
38- **Add controlField metadata for ChainSelect fields
39 ([16164](https://github.com/civicrm/civicrm-core/pull/16164))**
b899efe3 40
423e1d8f
AF
41 Adds additional field metadata for state/province and county address fields
42 for the sake of autogenerated forms (afform).
b899efe3 43
423e1d8f
AF
44- **Allow Angular modules to provide dynamic HTML snippets
45 ([16078](https://github.com/civicrm/civicrm-core/pull/16078))**
b899efe3 46
423e1d8f
AF
47 Supports afforms dynamic templates by allowing angular partials to be passed
48 as strings not just file paths.
b899efe3 49
423e1d8f
AF
50- **Allow values to be passed to api4 GetFields
51 ([16154](https://github.com/civicrm/civicrm-core/pull/16154) and
52 [16162](https://github.com/civicrm/civicrm-core/pull/16162))**
b899efe3 53
423e1d8f
AF
54 Makes it possible to filter api4 `getFields` calls by contact
55 type, only returning custom fields appropriate to certain contact types.
b899efe3 56
423e1d8f
AF
57- **Pass api4 getFields values through to getOptions
58 ([16168](https://github.com/civicrm/civicrm-core/pull/16168))**
b899efe3 59
423e1d8f 60 Allows option filtering in api4, similar to how it works in api3.
b899efe3 61
423e1d8f
AF
62- **Add api to check for missing indices
63 ([16145](https://github.com/civicrm/civicrm-core/pull/16145))**
b899efe3 64
423e1d8f 65 Adds an api to check for missing mysql indices.
b899efe3 66
423e1d8f
AF
67- **Add in Country and StateProvince APIv4 Entities
68 ([16110](https://github.com/civicrm/civicrm-core/pull/16110))**
b899efe3 69
423e1d8f 70 Adds Country and StateProvince APIv4 Entities.
b899efe3 71
423e1d8f
AF
72- **Replace all instances of CRM_Core_Fatal with throw new CRM_Core_Exception
73 (Work Towards [dev/core#560](https://lab.civicrm.org/dev/core/issues/560):
74 [16141](https://github.com/civicrm/civicrm-core/pull/16141) and
75 [16067](https://github.com/civicrm/civicrm-core/pull/16067))**
b899efe3 76
423e1d8f 77 Work towards throwing exceptions (instead of fatal errors).
b899efe3 78
423e1d8f
AF
79- **Deadlocked queries cause an instant error for end-users, but are retried in
80 other circumstances (Work Towards
81 [dev/core#395](https://lab.civicrm.org/dev/core/issues/395):
82 [275](https://github.com/civicrm/civicrm-packages/pull/275) and
83 [16143](https://github.com/civicrm/civicrm-core/pull/16143))**
b899efe3 84
423e1d8f
AF
85 Improves logging from deadlocks specifically, before this change an error
86 recorded because of a deadlock query was recorded as "DBError::Unknown Error"
87 now they are recorded as "DBError::deadlock".
b899efe3 88
423e1d8f 89### CiviContribute
b899efe3 90
423e1d8f
AF
91- **We should give user feedback in case of a Payment Processor Exception
92 ([15676](https://github.com/civicrm/civicrm-core/pull/15676))**
b899efe3 93
423e1d8f
AF
94 Improves user experience when updating or canceling a recurring payment by
95 displaying any error message sent from the payment processor to the user.
b899efe3 96
423e1d8f
AF
97- **Code cleanup Update Paypal invokeApi to only throw exceptions.
98 ([16072](https://github.com/civicrm/civicrm-core/pull/16072))**
b899efe3 99
423e1d8f 100 Standardizes and improves error handling within PayPal.
b899efe3 101
423e1d8f 102## <a name="bugs"></a>Bugs resolved
b899efe3 103
423e1d8f 104### Core CiviCRM
b899efe3 105
423e1d8f
AF
106- **CIVI-SA-2019-21 may lead to regressions when following typehints on
107 CRM_Core_BAO_Setting::setItem()
108 ([dev/core#1425](https://lab.civicrm.org/dev/core/issues/1425):
109 [15975](https://github.com/civicrm/civicrm-core/pull/15975))**
b899efe3 110
423e1d8f
AF
111 Deprecates old setItem & setOptionValue functions on
112 BAO_Setting to prevent regressions.
b899efe3 113
423e1d8f
AF
114- **Deadlocks on acl_cache (Work Towards
115 [dev/core#1486](https://lab.civicrm.org/dev/core/issues/1486):
116 [16144](https://github.com/civicrm/civicrm-core/pull/16144))**
b899efe3 117
423e1d8f
AF
118 Adds an index to the `civicrm_acl_cache.modified_date` column to reduce
119 deadlocks when running the ACL Cache.
b899efe3 120
423e1d8f
AF
121- **Port "+options" for constant-parameters to APIv4-PHP (Work Towards
122 [dev/core#1489](https://lab.civicrm.org/dev/core/issues/1489):
123 [16149](https://github.com/civicrm/civicrm-core/pull/16149))**
b899efe3 124
423e1d8f 125 Ensures managed entities are not reconciled during upgrades.
b899efe3 126
423e1d8f
AF
127- **Api4 - Fix auto serialize array input for CheckBox/MultiSelect fields
128 ([16152](https://github.com/civicrm/civicrm-core/pull/16152))**
b899efe3 129
423e1d8f
AF
130 In Api4, serialized fields should input/output as array data. This wasn't
131 working on the input side for custom entities. This fixes array input handling
132 and adds test coverage.
b899efe3 133
423e1d8f
AF
134- **Fix output display in api4 explorer
135 ([16130](https://github.com/civicrm/civicrm-core/pull/16130))**
b899efe3 136
423e1d8f 137 Ensures api4 explorer displays output with html entities properly.
b899efe3 138
423e1d8f
AF
139- **Add in searchFieldMetadata for contact_tags, contact_type, group and
140 deleted_contacts fields for contribute, pledge searches
141 ([15942](https://github.com/civicrm/civicrm-core/pull/15942))**
b899efe3 142
423e1d8f
AF
143 Adds url support on search forms (other than the search builder) for the
144 following fields: `contact_tags`, `contact_type`, `group` and
145 `deleted_contacts`.
b899efe3 146
423e1d8f
AF
147- **Update Smart Group form uses different labels for Group Title and Group
148 Description ([16042](https://github.com/civicrm/civicrm-core/pull/16042))**
b899efe3 149
423e1d8f
AF
150 Improves user experience by making the Smart Group field labels on the
151 Advanced Search from match the labels used on the Smart Group edit form.
b899efe3 152
423e1d8f
AF
153- **Update Smart Group form unsets the existing Group Types
154 ([16043](https://github.com/civicrm/civicrm-core/pull/16043))**
b899efe3 155
423e1d8f
AF
156 Ensures the Mailing List group type remains set on the Update Smart Group
157 form.
b899efe3 158
423e1d8f
AF
159- **Activity type listing shows name instead label
160 ([dev/core#1470](https://lab.civicrm.org/dev/core/issues/1470):
161 [16094](https://github.com/civicrm/civicrm-core/pull/16094))**
b899efe3 162
423e1d8f
AF
163- **Export doesn't work in Excel with diacritic chars
164 ([dev/core#1424](https://lab.civicrm.org/dev/core/issues/1424):
165 [16117](https://github.com/civicrm/civicrm-core/pull/16117) and
166 [15968](https://github.com/civicrm/civicrm-core/pull/15968))**
b899efe3 167
423e1d8f
AF
168- **text missing from email column when custom search profile is used
169 in Advanced Search
170 ([dev/core#1474](https://lab.civicrm.org/dev/core/issues/1474):
171 [16101](https://github.com/civicrm/civicrm-core/pull/16101))**
b899efe3 172
423e1d8f 173### CiviCase
b899efe3 174
423e1d8f
AF
175- **Add case activity action links to activity report
176 ([15135](https://github.com/civicrm/civicrm-core/pull/15135))**
b899efe3 177
423e1d8f
AF
178 Ensures if an activity is linked to a case the "case activity" actions are
179 displayed instead of the standard activity actions (eg. move/copy to case
180 instead of file on case).
b899efe3 181
423e1d8f
AF
182- **Case Detail 'Active Role?' filter excludes cases without relationships
183 ([dev/report#24](https://lab.civicrm.org/dev/report/issues/24):
184 [15972](https://github.com/civicrm/civicrm-core/pull/15972))**
b899efe3 185
423e1d8f
AF
186- **Manager/Creator Information not being returned for case related contacts
187 when fetching Case Details
188 ([dev/core#1426](https://lab.civicrm.org/dev/core/issues/1426):
189 [16006](https://github.com/civicrm/civicrm-core/pull/16006))**
b899efe3 190
423e1d8f 191### CiviContribute
b899efe3 192
423e1d8f
AF
193- **Thousands-separator corrupts price field values (comma)
194 ([dev/core#1472](https://lab.civicrm.org/dev/core/issues/1472):
195 [16111](https://github.com/civicrm/civicrm-core/pull/16111))**
b899efe3 196
423e1d8f
AF
197 Fixes a bug where price options with thousands operators didn't submit
198 correctly.
b899efe3 199
423e1d8f
AF
200- **E notice fix on Price set form
201 ([16096](https://github.com/civicrm/civicrm-core/pull/16096))**
b899efe3 202
423e1d8f 203 Removes an e notice when submitting the price set form.
b899efe3 204
423e1d8f
AF
205- **Advanced search fails to properly search for contribution source
206 ([dev/core#1468](https://lab.civicrm.org/dev/core/issues/1468):
207 [16083](https://github.com/civicrm/civicrm-core/pull/16083))**
b899efe3 208
423e1d8f 209### CiviEvent
b899efe3 210
423e1d8f
AF
211- **Event Participants actions (Print Name Badges, Export...) ignores search
212 criteria ([dev/core#1422](https://lab.civicrm.org/dev/core/issues/1422):
213 [16038](https://github.com/civicrm/civicrm-core/pull/16038))**
b899efe3 214
423e1d8f
AF
215 Ensures that the actions menu on the participant search form respects search
216 criteria.
b899efe3 217
423e1d8f 218### CiviMember
b899efe3 219
423e1d8f
AF
220- **Fix js error on choosing membership type
221 ([16058](https://github.com/civicrm/civicrm-core/pull/16058))**
b899efe3 222
423e1d8f
AF
223 Fixes a javascript error "Uncaught ReferenceError" when choosing a membership
224 type from the backend membership signup form.
b899efe3 225
423e1d8f 226### Drupal Integration
b899efe3 227
423e1d8f
AF
228- **Error when creating user record for Civi contact
229 ([dev/drupal#99](https://lab.civicrm.org/dev/drupal/issues/99):
230 [16157](https://github.com/civicrm/civicrm-core/pull/16157))**
b899efe3 231
423e1d8f
AF
232 Fixes an E-notice "Notice: Trying to get property 'id' of non-object in
233 CRM_Core_BAO_UFMatch::updateContactEmail() (line 449 of
234 /var/www/sitename/vendor/civicrm/civicrm-core/CRM/Core/BAO/UFMatch.php)." when
235 submitting the "Create User Record" form which can be found from the "Actions"
236 menu-button while viewing a CRM contact.
b899efe3 237
423e1d8f
AF
238- **Missing address on `/user` when location type label differs from its name
239 ([dev/core#1473](https://lab.civicrm.org/dev/core/issues/1473):
240 [16100](https://github.com/civicrm/civicrm-core/pull/16100))**
b899efe3 241
423e1d8f 242### Wordpress Integration
b899efe3 243
423e1d8f
AF
244- **Fix basepage title for Yoast SEO when theme declares "title-tag" support
245 ([174](https://github.com/civicrm/civicrm-wordpress/pull/174))**
b899efe3 246
423e1d8f
AF
247 Fixes a bug for sites with the Yoast SEO plugin where the CiviCRM page title
248 was not being displayed properly. Specifically the Yoast SEO plugin
249 short-circuits the code in `wp_get_document_title()` by filtering via
250 `pre_get_document_title`. This means that the CiviCRM code to apply the
251 CiviCRM basepage title via the document_title_parts filter is never reached
252 and the basepage title does not reflect the CiviCRM content.
b899efe3 253
423e1d8f 254## <a name="misc"></a>Miscellany
b899efe3 255
423e1d8f
AF
256- **Fix typo, Mailign should be Mailing
257 ([16031](https://github.com/civicrm/civicrm-core/pull/16031))**
b899efe3 258
423e1d8f
AF
259- **Switch static var to using Civi::statics
260 ([16138](https://github.com/civicrm/civicrm-core/pull/16138))**
b899efe3 261
423e1d8f
AF
262- **Remove code to create a subscription history entry when a contact is created
263 ([dev/core#1482](https://lab.civicrm.org/dev/core/issues/1482):
264 [16125](https://github.com/civicrm/civicrm-core/pull/16125))**
b899efe3 265
423e1d8f
AF
266- **Remove unnecessary query when updating org, if no name update.
267 ([16080](https://github.com/civicrm/civicrm-core/pull/16080))**
b899efe3 268
423e1d8f
AF
269- **Remove unnecessary, and possibly incorrect query from email update
270 ([16079](https://github.com/civicrm/civicrm-core/pull/16079))**
b899efe3 271
423e1d8f
AF
272- **Remove unneeded zendframwork/zend-validator and zendframwork/zend-stdlib
273 packages as not required by any other package
274 ([16112](https://github.com/civicrm/civicrm-core/pull/16112))**
b899efe3 275
423e1d8f
AF
276- **Remove legacy_redirect_path handling
277 ([16134](https://github.com/civicrm/civicrm-core/pull/16134))**
b899efe3 278
423e1d8f
AF
279- **Remove function marked as deprecated & unused by core nearly a year ago
280 ([16124](https://github.com/civicrm/civicrm-core/pull/16124))**
b899efe3 281
423e1d8f
AF
282- **Remove vestige of apiv2
283 ([16115](https://github.com/civicrm/civicrm-core/pull/16115))**
b899efe3 284
423e1d8f
AF
285- **Remove PEAR package Structures_Graph as there appears to be no use for it
286 ([279](https://github.com/civicrm/civicrm-packages/pull/279))**
b899efe3 287
423e1d8f
AF
288- **Remove Net_UserAgent_Detect package
289 ([272](https://github.com/civicrm/civicrm-packages/pull/272))**
b899efe3 290
423e1d8f
AF
291- **Paypal class cleanup
292 ([16088](https://github.com/civicrm/civicrm-core/pull/16088))**
b899efe3 293
423e1d8f
AF
294- **2020 test fixes.
295 ([16172](https://github.com/civicrm/civicrm-core/pull/16172))**
b899efe3 296
423e1d8f
AF
297- **Unit test for https://github.com/civicrm/civicrm-core/pull/16120
298 ([16127](https://github.com/civicrm/civicrm-core/pull/16127))**
b899efe3 299
423e1d8f
AF
300- **Update unit tests to use name spaced format of phpunit test classes for
301 phpunit6 compatability
302 ([594](https://github.com/civicrm/civicrm-drupal/pull/594))**
b899efe3 303
423e1d8f
AF
304- **Update to use the namespaced version of the PHPUnit test classes as this
305 will work for phpunit6 going forward as well as phpunit5
306 ([175](https://github.com/civicrm/civicrm-wordpress/pull/175))**
b899efe3 307
423e1d8f
AF
308- **Update PHPUnit Test class declarations to use namespaced format for phpunit6
309 compatability ([108](https://github.com/civicrm/civicrm-backdrop/pull/108))**
b899efe3 310
423e1d8f
AF
311- **[REF] Minor cleanup - declare exceptions, use single quotes, strict
312 comparison ([16137](https://github.com/civicrm/civicrm-core/pull/16137))**
b899efe3 313
423e1d8f
AF
314- **[REF] remove CRM_Core_Error check
315 ([16136](https://github.com/civicrm/civicrm-core/pull/16136))**
b899efe3 316
423e1d8f
AF
317- **[REF] Convert more petition signature fatals to status bounce
318 ([16075](https://github.com/civicrm/civicrm-core/pull/16075))**
b899efe3 319
423e1d8f
AF
320- **[REF] Switch CRM_Utils_Error::fatal calls for CRM_Core_Exception in Grant.
321 utils, bin/ and Civi/Angular/ folders
322 ([16109](https://github.com/civicrm/civicrm-core/pull/16109))**
b899efe3 323
423e1d8f
AF
324- **[REF] Minor simplification on additional_participants checks
325 ([16056](https://github.com/civicrm/civicrm-core/pull/16056))**
b899efe3 326
423e1d8f
AF
327- **[REF] Refactor Contact Search form to use standardised getSortID function
328 ([16054](https://github.com/civicrm/civicrm-core/pull/16054))**
b899efe3 329
423e1d8f
AF
330- **[REF] Refactor Activity Search to use parent getSortID function
331 ([16053](https://github.com/civicrm/civicrm-core/pull/16053))**
b899efe3 332
423e1d8f
AF
333- **[REF] Refactor Campaign Search form to use standardised getSortID function
334 ([16055](https://github.com/civicrm/civicrm-core/pull/16055))**
b899efe3 335
423e1d8f
AF
336- **[REF] Move wrangling of Front end form contribution param for autoRenew back
337 to form ([15927](https://github.com/civicrm/civicrm-core/pull/15927))**
b899efe3 338
423e1d8f
AF
339- **[REF] Replace Deprecated function CRM_Core_BAO_Setting::setItem with the
340 relevant Civi::contactSettings function
341 ([16044](https://github.com/civicrm/civicrm-core/pull/16044))**
b899efe3 342
423e1d8f
AF
343- **[REF] remove unused from getACLRoles
344 ([16180](https://github.com/civicrm/civicrm-core/pull/16180))**
b899efe3 345
423e1d8f
AF
346- **[REF] simplify recordAdjustedAmt function
347 ([16135](https://github.com/civicrm/civicrm-core/pull/16135))**
b899efe3 348
423e1d8f
AF
349- **[REF] extract member form batch update & add test
350 ([16151](https://github.com/civicrm/civicrm-core/pull/16151))**
b899efe3 351
423e1d8f
AF
352- **[REF] Remove unused params from function signature for getACLs
353 ([16175](https://github.com/civicrm/civicrm-core/pull/16175))**
b899efe3 354
423e1d8f
AF
355- **[REF] step towards wiping out $ids array in membership bao functions
356 ([16132](https://github.com/civicrm/civicrm-core/pull/16132))**
b899efe3 357
423e1d8f
AF
358- **[Ref] improve readability of acl code
359 ([16131](https://github.com/civicrm/civicrm-core/pull/16131))**
b899efe3 360
423e1d8f
AF
361- **[Ref] Remove php4 support from BAO_Acl class
362 ([16119](https://github.com/civicrm/civicrm-core/pull/16119))**
b899efe3 363
423e1d8f
AF
364- **[NFC] Test clean up.
365 ([16133](https://github.com/civicrm/civicrm-core/pull/16133))**
b899efe3 366
423e1d8f
AF
367- **[NFC] cleanup to declared exceptions, quotes, strict mode.
368 ([16114](https://github.com/civicrm/civicrm-core/pull/16114))**
b899efe3 369
423e1d8f
AF
370- **[NFC] Declare exceptions, use single quotes where possible, use strict
371 comparison ([16142](https://github.com/civicrm/civicrm-core/pull/16142))**
b899efe3 372
423e1d8f
AF
373- **[NFC] Add in unit test for dev/core#1460
374 ([16063](https://github.com/civicrm/civicrm-core/pull/16063))**
b899efe3 375
423e1d8f
AF
376- **[NFC] code cleanup
377 ([16050](https://github.com/civicrm/civicrm-core/pull/16050))**
378
379- **[NFC] Add in a unit test of passing an array into the Civi::settings set
380 facade and getting it back
381 ([16045](https://github.com/civicrm/civicrm-core/pull/16045))**
382
383- **[NFC] Add test on buildMembershipTypeValues & cleanup class
384 ([16167](https://github.com/civicrm/civicrm-core/pull/16167))**
385
386- **[NFC] Re-generate DAOs
387 ([16178](https://github.com/civicrm/civicrm-core/pull/16178))**
388
389- **[NFC] Extract duplicated code lines in test
390 ([16165](https://github.com/civicrm/civicrm-core/pull/16165))**
391
392- **[NFC] Clean up unit test
393 ([16163](https://github.com/civicrm/civicrm-core/pull/16163))**
394
395- **[NFC] If statement is always true
396 ([16122](https://github.com/civicrm/civicrm-core/pull/16122))**
b899efe3
AH
397
398## <a name="credits"></a>Credits
399
400This release was developed by the following code authors:
401
423e1d8f
AF
402AGH Strategies - Andrew Hunt; Agileware - Justin Freeman; Australian Greens -
403Seamus Lee; Christian Wach; Circle Interactive - Pradeep Nayak; CiviCRM -
404Coleman Watts, Tim Otten; Coop SymbioTIC - Mathieu Lutfy; Dave D; Fuzion -
405Jitendra Purohit; MJW Consulting - Matthew Wire; Squiffle Consulting - Aidan
406Saunders; Wikimedia Foundation - Eileen McNaughton
b899efe3
AH
407
408Most authors also reviewed code for this release; in addition, the following
409reviewers contributed their comments:
410
423e1d8f
AF
411AGH Strategies - Alice Frumin; Artful Robot - Rich Lott; CiviDesk - Yashodha
412Chaku; Joinery - Allen Shaw; Megaphone Technology Consulting - Jon Goldberg;
413Tadpole Collective - Kevin Cristiano;
80b16320
AH
414
415## <a name="feedback"></a>Feedback
416
417These release notes are edited by Alice Frumin and Andrew Hunt. If you'd like
418to provide feedback on them, please log in to https://chat.civicrm.org/civicrm
419and contact `@agh1`.