civicrm-core.git
4 years agodev/translation#39 - Fix `core:install --lang`. Realign boot code.
Tim Otten [Wed, 6 May 2020 22:02:09 +0000 (15:02 -0700)]
dev/translation#39 - Fix `core:install --lang`. Realign boot code.

Overview
--------

Suppose you run a command like:

```
cv core:install --lang=fr_FR --cms-base-url=http://example.com/
```

This fixes that use-case by realigning some of the bootstrap steps under `setup/plugins/installDatabase/*`.

Before
------

* The above `core:install` command crashes because the `paths` service is unavailable.

* The `civi.setup.installDatabase` begins with these two steps:

    1. `InstallSchema.civi-setup.php` manipulates some global options (to make certain services work),
       and it also installs the schema, and it also reboots the `Container`.
    2. `BootstrapCivi.civi-setup.php` tries to boot again - e.g. it loads `civicrm.settings.php` and
       calls `CRM_Core_Config::singleton($loadFromDB=TRUE)`. But this is suspect because it
       neglects to set `$force=TRUE`.

After
-----

* The above `core:install` command runs.

* The `civi.setup.installDatabase` begins with these *three* steps:

    1. `Preboot.civi-setup.php` starts the system in a *partially booted* mode (ie with `$loadFromDB==FALSE`).
    2. `InstallSchema.civi-setup.php` just installs the schema.
    3. `BootstrapCivi.civi-setup.php` switches the system to a fully booted mode (ie with `$loadFromDB==TRUE`).

Technical details
-----------------

I tested this on a D7 build. My dev/test loop was basically these steps:

```
cv core:uninstall -f
cv core:install --lang fr_FR --cms-base-url='http://dmaster.bknix:8001' -vvv
echo 'select name, label, value from civicrm_option_value where name like "Meet%"' | cv sql
```

If the install succeeded, then the SQL command would display localized
labels for "Meeting" ("Reunion").

4 years agoMerge pull request #17236 from civicrm/5.25
Eileen McNaughton [Wed, 6 May 2020 00:51:42 +0000 (12:51 +1200)]
Merge pull request #17236 from civicrm/5.25

5.25

4 years agoMerge pull request #17232 from seamuslee001/dev_core_1742
Eileen McNaughton [Tue, 5 May 2020 23:27:29 +0000 (11:27 +1200)]
Merge pull request #17232 from seamuslee001/dev_core_1742

dev/core#1742 Expose CiviCRM Database details for views configuration…

4 years agoMerge pull request #17197 from eileenmcnaughton/act_r_test
Seamus Lee [Tue, 5 May 2020 23:26:07 +0000 (09:26 +1000)]
Merge pull request #17197 from eileenmcnaughton/act_r_test

[REF] [Test] IDE cleanup on ReportTemplateTest

4 years agoMerge pull request #17234 from MegaphoneJon/reporting-20-alt
Seamus Lee [Tue, 5 May 2020 23:23:55 +0000 (09:23 +1000)]
Merge pull request #17234 from MegaphoneJon/reporting-20-alt

Reporting #20 - correct stats when force=1 on Contribution Detail Report

4 years agoMerge pull request #16584 from eileenmcnaughton/role
Seamus Lee [Tue, 5 May 2020 23:19:39 +0000 (09:19 +1000)]
Merge pull request #16584 from eileenmcnaughton/role

[REF] Simplify non-creditcard participant.create

4 years agoMerge pull request #17237 from eileenmcnaughton/525
Seamus Lee [Tue, 5 May 2020 23:17:20 +0000 (09:17 +1000)]
Merge pull request #17237 from eileenmcnaughton/525

(dev/core#1740) Cumulative contributions not being calculated with the correct criteria

4 years ago(dev/core#1740) Cumulative contributions not being calculated with the correct criteria
yashodha [Mon, 4 May 2020 14:40:13 +0000 (20:10 +0530)]
(dev/core#1740) Cumulative contributions not being calculated with the correct criteria

4 years agoMerge pull request #17026 from jitendrapurohit/dev-57
Eileen McNaughton [Tue, 5 May 2020 21:59:27 +0000 (09:59 +1200)]
Merge pull request #17026 from jitendrapurohit/dev-57

dev/core#57 On Behalf Of fails to populate in Email Receipt

4 years agoMerge pull request #17235 from colemanw/apiLog
Eileen McNaughton [Tue, 5 May 2020 21:40:02 +0000 (09:40 +1200)]
Merge pull request #17235 from colemanw/apiLog

APIv4 - Deprecate option_value joins and display notices in Explorer

4 years agoMerge pull request #17233 from alifrumin/rn5.25
Seamus Lee [Tue, 5 May 2020 21:08:03 +0000 (07:08 +1000)]
Merge pull request #17233 from alifrumin/rn5.25

[NFC] First Pass at 5.25 release notes

4 years agoAPIv4 - Deprecate option_value joins in favor of pseudoconstant suffix
Coleman Watts [Tue, 5 May 2020 19:52:08 +0000 (15:52 -0400)]
APIv4 - Deprecate option_value joins in favor of pseudoconstant suffix

4 years agoAPI - Display all logged warnings, errors, etc. in debug output and APIv4 explorer.
Coleman Watts [Tue, 5 May 2020 19:19:08 +0000 (15:19 -0400)]
API - Display all logged warnings, errors, etc. in debug output and APIv4 explorer.

4 years agoReporting #20 - correct stats when force=1 on Contribution Detail Report
Jon Goldberg [Tue, 5 May 2020 15:37:39 +0000 (11:37 -0400)]
Reporting #20 - correct stats when force=1 on Contribution Detail Report

4 years agoMerge pull request #17231 from totten/master-token-tweak
colemanw [Tue, 5 May 2020 14:56:03 +0000 (10:56 -0400)]
Merge pull request #17231 from totten/master-token-tweak

(REF,NFC) TokenProcessor - Minor DX improvements

4 years agoFirst Pass at 5.25 releasenotes
Alice Frumin [Thu, 23 Apr 2020 19:43:41 +0000 (15:43 -0400)]
First Pass at 5.25 releasenotes

4 years agoMerge pull request #17230 from seamuslee001/domain_token_thank_you_letter
Monish Deb [Tue, 5 May 2020 13:49:16 +0000 (19:19 +0530)]
Merge pull request #17230 from seamuslee001/domain_token_thank_you_letter

[REF] Permit domain tokens being used within Thank You letters

4 years ago[REF] Permit domain tokens being used within Thank You letters
Seamus Lee [Tue, 5 May 2020 06:58:07 +0000 (16:58 +1000)]
[REF] Permit domain tokens being used within Thank You letters

Re-arrange code as per Matt's comment

4 years agodev/core#1742 Expose CiviCRM Database details for views configuration in Drupal 8...
Seamus Lee [Tue, 5 May 2020 10:07:57 +0000 (20:07 +1000)]
dev/core#1742 Expose CiviCRM Database details for views configuration in Drupal 8 as well as in Drupal 7 and Backdrop

4 years ago(NFC) TokenProcessor - Improve docblocks
Tim Otten [Tue, 5 May 2020 09:01:15 +0000 (02:01 -0700)]
(NFC) TokenProcessor - Improve docblocks

4 years ago(REF) TokenProcessor - Allowing adding rows by array
Tim Otten [Tue, 5 May 2020 05:54:38 +0000 (22:54 -0700)]
(REF) TokenProcessor - Allowing adding rows by array

Before
-------------------

When composing a message, you need to add a row and then use the fluent
`TokenRow` stub, eg:

```php
$p->addRow()->context(['contact_id' => 123]);
$p->addRow()->context(['contact_id' => 456]);
```

After
-------------------

When composing a message, you don't have to use the fluent `TokenRow` stub.
Just give an array:

```php
$p->addRow(['contact_id' => 123]);
$p->addRow(['contact_id' => 456]);
```

Or:

```php
$p->addRows([
  ['contact_id' => 123],
  ['contact_id' => 456],
]);
```

You still have the option of using the fluent interface.

4 years ago(NFC) TokenRow - Improve docblocks
Tim Otten [Tue, 5 May 2020 04:35:18 +0000 (21:35 -0700)]
(NFC) TokenRow - Improve docblocks

4 years agoMerge pull request #17212 from eileenmcnaughton/fatal
Eileen McNaughton [Tue, 5 May 2020 04:23:01 +0000 (16:23 +1200)]
Merge pull request #17212 from eileenmcnaughton/fatal

Convert fatals to statusBounces in case forms

4 years agoMerge pull request #17124 from totten/master-hook-cleanup
Eileen McNaughton [Tue, 5 May 2020 01:02:03 +0000 (13:02 +1200)]
Merge pull request #17124 from totten/master-hook-cleanup

(REF) CRM_Utils_Hook - Remove deprecated formulations of `invoke(int,…)`

4 years agoMerge pull request #17126 from totten/master-upgr-dispatch
Eileen McNaughton [Tue, 5 May 2020 00:57:58 +0000 (12:57 +1200)]
Merge pull request #17126 from totten/master-upgr-dispatch

dev/core#1460, dev/core#1713 - Categorical fix for upgrade<=>hook issues

4 years agoMerge pull request #17006 from mattwire/l10nallowoverrideinherit
Matthew Wire [Mon, 4 May 2020 11:45:19 +0000 (12:45 +0100)]
Merge pull request #17006 from mattwire/l10nallowoverrideinherit

Allow override of inherited CMS language when in CiviCRM

4 years agoMerge pull request #17130 from jitendrapurohit/mail-62
Seamus Lee [Mon, 4 May 2020 09:31:14 +0000 (19:31 +1000)]
Merge pull request #17130 from jitendrapurohit/mail-62

dev/mail#62 - Mailing Error when civicrm_mailing_group has duplicate …

4 years agoMerge pull request #17091 from colemanw/noArrayValue
Seamus Lee [Mon, 4 May 2020 09:21:39 +0000 (19:21 +1000)]
Merge pull request #17091 from colemanw/noArrayValue

[REF] Switch CRM_Utils_Array::value to empty in conditionals

4 years agoMerge pull request #17175 from eileenmcnaughton/batch
Seamus Lee [Mon, 4 May 2020 09:09:21 +0000 (19:09 +1000)]
Merge pull request #17175 from eileenmcnaughton/batch

Further removal of long-deprecated skipCleanMoney

4 years agoMerge pull request #17225 from eileenmcnaughton/cont
colemanw [Mon, 4 May 2020 01:13:11 +0000 (21:13 -0400)]
Merge pull request #17225 from eileenmcnaughton/cont

[REF] Minor code cleanup

4 years agoMerge pull request #17219 from colemanw/api4deprecateOptions
Eileen McNaughton [Sun, 3 May 2020 23:55:22 +0000 (11:55 +1200)]
Merge pull request #17219 from colemanw/api4deprecateOptions

APIv4 - Deprecate old way of retrieving activityType/optionValue ids

4 years ago[REF] Minor code cleanup
eileen [Sun, 3 May 2020 22:26:50 +0000 (10:26 +1200)]
[REF] Minor code cleanup

Do not pass params as reference as unchanged

4 years agoMerge pull request #17222 from eileenmcnaughton/obh
Seamus Lee [Sun, 3 May 2020 22:02:11 +0000 (08:02 +1000)]
Merge pull request #17222 from eileenmcnaughton/obh

[REF] Minor code cleanup.

4 years agoAPIv4 - Deprecate old way of retrieving activityType/optionValue ids
Coleman Watts [Sat, 2 May 2020 00:30:08 +0000 (20:30 -0400)]
APIv4 - Deprecate old way of retrieving activityType/optionValue ids

4 years agoMerge pull request #17224 from eileenmcnaughton/testc
colemanw [Sun, 3 May 2020 13:35:35 +0000 (09:35 -0400)]
Merge pull request #17224 from eileenmcnaughton/testc

[NFC] Test cleanup

4 years agoMerge pull request #17223 from demeritcowboy/conference-slots
Eileen McNaughton [Sun, 3 May 2020 09:02:50 +0000 (21:02 +1200)]
Merge pull request #17223 from demeritcowboy/conference-slots

Fix admin page url for "conference slots" option values

4 years ago[NFC] Test cleanup
eileen [Sun, 3 May 2020 05:07:37 +0000 (17:07 +1200)]
[NFC] Test cleanup

4 years agofix admin page url
demeritcowboy [Sun, 3 May 2020 04:14:47 +0000 (00:14 -0400)]
fix admin page url

4 years agoREF - Switch CRM_Utils_Array::value to empty in conditionals
Coleman Watts [Thu, 16 Apr 2020 19:33:43 +0000 (15:33 -0400)]
REF - Switch CRM_Utils_Array::value to empty in conditionals

4 years agoMerge pull request #17221 from civicrm/5.25
Seamus Lee [Sat, 2 May 2020 21:05:32 +0000 (07:05 +1000)]
Merge pull request #17221 from civicrm/5.25

5.25

4 years ago[REF] Minor code cleanup.
eileen [Sat, 2 May 2020 07:49:07 +0000 (19:49 +1200)]
[REF] Minor code cleanup.

Once we compress the 2 ifs we find the value in the 'else' is never used

4 years agoMerge pull request #17218 from seamuslee001/5.25
Eileen McNaughton [Sat, 2 May 2020 03:43:22 +0000 (15:43 +1200)]
Merge pull request #17218 from seamuslee001/5.25

[REF] Fix retrieving invoice related settings when doing complete tra…

4 years agoMerge pull request #17216 from totten/master-disp-cleanup
colemanw [Sat, 2 May 2020 00:19:19 +0000 (20:19 -0400)]
Merge pull request #17216 from totten/master-disp-cleanup

dev/core#1460 - Small cleanups in CiviEventDispatcher{,Test}

4 years agoMerge pull request #17217 from civicrm/5.25
Seamus Lee [Fri, 1 May 2020 21:52:09 +0000 (07:52 +1000)]
Merge pull request #17217 from civicrm/5.25

5.25

4 years ago[REF] Fix retreiving invoice related settings when doing complete transaction
Seamus Lee [Fri, 1 May 2020 21:40:12 +0000 (07:40 +1000)]
[REF] Fix retreiving invoice related settings when doing complete transaction

4 years agoMerge pull request #17215 from eileenmcnaughton/act
colemanw [Fri, 1 May 2020 13:54:29 +0000 (09:54 -0400)]
Merge pull request #17215 from eileenmcnaughton/act

dev/core#1714 Fix mis-filtering on activity type

4 years agoMerge pull request #17172 from colemanw/writeRecord
Seamus Lee [Fri, 1 May 2020 07:39:00 +0000 (17:39 +1000)]
Merge pull request #17172 from colemanw/writeRecord

[REF] Reduce boilerplate code in BAO add/create functions

4 years agoMerge pull request #17151 from eileenmcnaughton/actsched
Seamus Lee [Fri, 1 May 2020 07:38:38 +0000 (17:38 +1000)]
Merge pull request #17151 from eileenmcnaughton/actsched

[REF] Minor cleanup around action schedule code.

4 years agoMerge pull request #17213 from eileenmcnaughton/test
Seamus Lee [Fri, 1 May 2020 07:37:59 +0000 (17:37 +1000)]
Merge pull request #17213 from eileenmcnaughton/test

[NFC][Test] Preliminary cleanup

4 years ago(NFC) CiviEventDispatcher - Improve docblocks
Tim Otten [Fri, 1 May 2020 03:38:49 +0000 (20:38 -0700)]
(NFC) CiviEventDispatcher - Improve docblocks

4 years agoConvert fatals to statusBounces in case forms
eileen [Fri, 1 May 2020 00:22:56 +0000 (12:22 +1200)]
Convert fatals to statusBounces in case forms

4 years ago[REF] [Test] IDE cleanup on ReportTemplateTest
eileen [Thu, 30 Apr 2020 03:11:44 +0000 (15:11 +1200)]
[REF] [Test] IDE cleanup on ReportTemplateTest

4 years agoCiviEventDispatcherTest - Fix warning on newer versions of PHP
Tim Otten [Fri, 1 May 2020 03:30:06 +0000 (20:30 -0700)]
CiviEventDispatcherTest - Fix warning on newer versions of PHP

4 years agoMerge pull request #17184 from mattwire/opencasenofatal
Eileen McNaughton [Fri, 1 May 2020 03:28:48 +0000 (15:28 +1200)]
Merge pull request #17184 from mattwire/opencasenofatal

Cleanup and throw exceptions in OpenCase form

4 years agodev/core#1714 Fix mis-filtering on activity type
eileen [Fri, 1 May 2020 03:00:56 +0000 (15:00 +1200)]
dev/core#1714 Fix mis-filtering on activity type

This fixes a bug where the activity_type_id was being compared against the label of the option value

4 years agoMerge pull request #17211 from eileenmcnaughton/id
colemanw [Fri, 1 May 2020 02:51:35 +0000 (22:51 -0400)]
Merge pull request #17211 from eileenmcnaughton/id

(NFC) Remove $Id$ artifacts from old SCM

4 years agoMerge pull request #17122 from colemanw/buildOptions
Eileen McNaughton [Fri, 1 May 2020 02:29:53 +0000 (14:29 +1200)]
Merge pull request #17122 from colemanw/buildOptions

Cleanup core pseudoconstant buildOptions

4 years agoREF - Reduce boilerplate code in BAO add/create functions
Coleman Watts [Mon, 27 Apr 2020 01:11:27 +0000 (21:11 -0400)]
REF - Reduce boilerplate code in BAO add/create functions

The new CRM_Core_DAO::writeRecord function can be used instead of boilerplate

4 years ago[NFC][Test] Preliminary cleanup
eileen [Fri, 1 May 2020 01:14:16 +0000 (13:14 +1200)]
[NFC][Test] Preliminary cleanup

Margin cleanup - declare exceptions, use right quotes, remove unused params

4 years agoMerge pull request #17167 from colemanw/moreOptions
Eileen McNaughton [Fri, 1 May 2020 00:44:28 +0000 (12:44 +1200)]
Merge pull request #17167 from colemanw/moreOptions

APIv4 - Allow field options to be returned in multiple formats

4 years agoMerge pull request #17196 from eileenmcnaughton/session
Seamus Lee [Fri, 1 May 2020 00:37:02 +0000 (10:37 +1000)]
Merge pull request #17196 from eileenmcnaughton/session

[REF] Cleanup a few instances where we use old call to get loggedInUserID

4 years agoA bit less svn
eileen [Fri, 1 May 2020 00:16:54 +0000 (12:16 +1200)]
A bit less svn

4 years agoAPIv4 - Improve pseudoconstants in HAVING and Explorer
Coleman Watts [Thu, 30 Apr 2020 19:14:07 +0000 (15:14 -0400)]
APIv4 - Improve pseudoconstants in HAVING and Explorer

4 years agoAPIv4 - Allow field options to be returned in multiple formats
Coleman Watts [Fri, 24 Apr 2020 17:50:26 +0000 (13:50 -0400)]
APIv4 - Allow field options to be returned in multiple formats

4 years agoMerge pull request #17209 from civicrm/5.25
Seamus Lee [Thu, 30 Apr 2020 22:46:46 +0000 (08:46 +1000)]
Merge pull request #17209 from civicrm/5.25

5.25

4 years agoMerge pull request #17208 from seamuslee001/5.25
Seamus Lee [Thu, 30 Apr 2020 22:45:39 +0000 (08:45 +1000)]
Merge pull request #17208 from seamuslee001/5.25

Update 5.24.6.md

4 years agoUpdate 5.24.6.md
Tim Otten [Thu, 30 Apr 2020 22:42:44 +0000 (15:42 -0700)]
Update 5.24.6.md

4 years agoMerge pull request #17207 from civicrm/5.25
Seamus Lee [Thu, 30 Apr 2020 22:33:14 +0000 (08:33 +1000)]
Merge pull request #17207 from civicrm/5.25

5.25

4 years agoMerge pull request #17205 from colemanw/noMultiJoins
Eileen McNaughton [Thu, 30 Apr 2020 22:32:06 +0000 (10:32 +1200)]
Merge pull request #17205 from colemanw/noMultiJoins

APIv4 - Don't advertise implicit multi-joins in Explorer

4 years agoMerge pull request #17206 from seamuslee001/5.25
Seamus Lee [Thu, 30 Apr 2020 22:30:24 +0000 (08:30 +1000)]
Merge pull request #17206 from seamuslee001/5.25

5.24.6 Release Notes

4 years agoUpdate release-notes/5.24.6
Tim Otten [Thu, 30 Apr 2020 21:52:58 +0000 (14:52 -0700)]
Update release-notes/5.24.6

4 years agoAdd release-notes/5.24.6.md
Tim Otten [Thu, 30 Apr 2020 03:04:31 +0000 (20:04 -0700)]
Add release-notes/5.24.6.md

4 years agoMerge pull request #17201 from civicrm/5.25
Seamus Lee [Thu, 30 Apr 2020 22:02:58 +0000 (08:02 +1000)]
Merge pull request #17201 from civicrm/5.25

5.25

4 years agoMerge pull request #17176 from eileenmcnaughton/batch1
colemanw [Thu, 30 Apr 2020 20:17:12 +0000 (16:17 -0400)]
Merge pull request #17176 from eileenmcnaughton/batch1

Move batch-form support code back to the form

4 years agoAPIv4 - Don't advertise implicit multi-joins in Explorer
Coleman Watts [Thu, 30 Apr 2020 20:09:12 +0000 (16:09 -0400)]
APIv4 - Don't advertise implicit multi-joins in Explorer

These joins are problematic and may be removed. The Explorer should not display them.

4 years agoMerge pull request #17195 from eileenmcnaughton/act_report2
colemanw [Thu, 30 Apr 2020 19:26:53 +0000 (15:26 -0400)]
Merge pull request #17195 from eileenmcnaughton/act_report2

[REF] Simplify determination of enabled components

4 years agoMerge pull request #17200 from eileenmcnaughton/rep
Seamus Lee [Thu, 30 Apr 2020 07:17:16 +0000 (17:17 +1000)]
Merge pull request #17200 from eileenmcnaughton/rep

dev/core#1729 Fix filters skipping on activity report

4 years agodev/core#1729 Fix filters skipping onn activity report
eileen [Thu, 30 Apr 2020 04:19:34 +0000 (16:19 +1200)]
dev/core#1729 Fix filters skipping onn activity report

4 years agoMerge pull request #17190 from mattwire/contributionpageselectedchildfromactions
Seamus Lee [Thu, 30 Apr 2020 04:08:36 +0000 (14:08 +1000)]
Merge pull request #17190 from mattwire/contributionpageselectedchildfromactions

dev/core#1738 Fix opening specific contribution page tab from Manage Contribution Pages

4 years agoMerge pull request #17199 from seamuslee001/new_master
Seamus Lee [Thu, 30 Apr 2020 03:48:29 +0000 (13:48 +1000)]
Merge pull request #17199 from seamuslee001/new_master

5.25

4 years agomerge in 5.25
Seamus Lee [Thu, 30 Apr 2020 03:46:42 +0000 (13:46 +1000)]
merge in 5.25

4 years agoMerge pull request #17188 from totten/5.25-contrib-virt-itemcanon
Seamus Lee [Thu, 30 Apr 2020 03:42:51 +0000 (13:42 +1000)]
Merge pull request #17188 from totten/5.25-contrib-virt-itemcanon

 Fix loading, saving, and upgrade of CiviContribute settings

4 years agoMerge pull request #17194 from eileenmcnaughton/act_report
Seamus Lee [Thu, 30 Apr 2020 03:42:20 +0000 (13:42 +1000)]
Merge pull request #17194 from eileenmcnaughton/act_report

[REF] stop overriding postProcess function in activity report detail

4 years ago[REF] Cleanup a few instances where we use old call to get loggedInUserID
eileen [Thu, 30 Apr 2020 02:38:48 +0000 (14:38 +1200)]
[REF] Cleanup a few instances where we use old call to get loggedInUserID

4 years ago[REF] stop overriding postProcess function in activity report detail
eileen [Thu, 30 Apr 2020 02:17:00 +0000 (14:17 +1200)]
[REF] stop overriding postProcess function in activity report detail

The function is the same as master except one extra thing that can be done in the function intended for
report-specific preProcess overrides

4 years ago[REF] Simplify determination of enabled components
eileen [Thu, 30 Apr 2020 02:30:26 +0000 (14:30 +1200)]
[REF] Simplify determination of enabled components

4 years agotestHandlingOfContributionInvoiceSetting() - More realistic data+assertion
Tim Otten [Thu, 30 Apr 2020 01:23:40 +0000 (18:23 -0700)]
testHandlingOfContributionInvoiceSetting() - More realistic data+assertion

In practice, for the old setting `contribution_invoice_settings`, the
`invoicing` property could take one of two values:

1. If enabled, the value is an array with trueish subkey: `['invoicing'=>['invoicing'=>1]]`
2. If disabled, the value is a numeric `0`: `['invoicing'=>0]`

Following this means better compatibility.

The format is counter-intuitive, and the unit-test sets the value to enabled
using a more intuitive format (`['invoicing'=>1]`).  It's currently valid to
`set()` this way, but `get()`ting the value produces the
more-compatible/historical format.

4 years agodev/core#1724 - Backward-compatible handling of 'contribution_invoice_settings.invoicing'
Tim Otten [Wed, 29 Apr 2020 04:54:12 +0000 (21:54 -0700)]
dev/core#1724 - Backward-compatible handling of 'contribution_invoice_settings.invoicing'

In the old setting `contribution_invoice_settings`, the `invoicing`
property (aka "CiviContribute Component Settings" => "Enable Tax and
Invoicing") could take one of two values:

1. If enabled, it's an array with trueish subkey: `['invoicing'=>1]`
2. If disabled, it's a numeric zero.

This encoding is weird, and `contribution_invoice_settings` is generally deprecated
and has been replaced by a virtual rendition which needs to be consistent with the
old representation -- so that a couple-dozen things continue working.

For testing, it helped me to try these commands at different points:

```
cv ev 'return CRM_Invoicing_Utils::isInvoicingEnabled();'
cv api setting.get return=invoicing
cv api setting.get return=contribution_invoice_settings

select * from civicrm_setting where name like 'contrib%' or name like 'invoic%';
```

4 years agoFiveTwentyFive - Convert settings during upgrade
Tim Otten [Wed, 29 Apr 2020 00:40:03 +0000 (17:40 -0700)]
FiveTwentyFive - Convert settings during upgrade

Consider this use-case:

* Install 5.22
* Configure `CiviContribute Component Settings`
* Upgrade to 5.25.beta

The settings are lost during the upgrade.

4 years agoSet version to 5.25.beta3
Tim Otten [Wed, 29 Apr 2020 23:34:28 +0000 (16:34 -0700)]
Set version to 5.25.beta3

4 years agoMerge pull request #17068 from colemanw/currentPath
colemanw [Wed, 29 Apr 2020 13:55:59 +0000 (09:55 -0400)]
Merge pull request #17068 from colemanw/currentPath

[REF] Reconcile CRM_Utils_System::getUrlPath and CRM_Utils_System::currentPath

4 years agoFix opening specific contribution page tab from Manage Contribution Pages
Matthew Wire [Wed, 29 Apr 2020 10:31:42 +0000 (11:31 +0100)]
Fix opening specific contribution page tab from Manage Contribution Pages

4 years agoMerge pull request #17125 from eileenmcnaughton/dupe1
Seamus Lee [Wed, 29 Apr 2020 09:34:59 +0000 (19:34 +1000)]
Merge pull request #17125 from eileenmcnaughton/dupe1

Fix Dedupe entity_tag mangling bug

4 years agoMerge pull request #17187 from alexymik/recur_contribution_source
Eileen McNaughton [Wed, 29 Apr 2020 02:26:19 +0000 (14:26 +1200)]
Merge pull request #17187 from alexymik/recur_contribution_source

Add contribution source to recurring contribution report

4 years agoMerge pull request #17186 from demeritcowboy/gitlab-issue-template
Eileen McNaughton [Wed, 29 Apr 2020 01:03:23 +0000 (13:03 +1200)]
Merge pull request #17186 from demeritcowboy/gitlab-issue-template

Gitlab issue template - Ask for link to stackexchange or chat conversations

4 years agodev/core#1724 - Fix defaults for invoice-related settings
Tim Otten [Tue, 28 Apr 2020 22:33:33 +0000 (15:33 -0700)]
dev/core#1724 - Fix defaults for invoice-related settings

The default values were previously stored in 'contribution_invoice_settings', but
the updates are stored in individual settings, which makes it difficult to reconcile
the default values and explicit values.

With this revision, 'contribution_invoice_settings' is strictly virtual, and
all the other settings (like 'invoice_due_date') are canonical.

4 years ago(REF) dev/core#1724 - SettingsBag - Convert to computeVirtual/updateVirtual
Tim Otten [Tue, 28 Apr 2020 21:14:45 +0000 (14:14 -0700)]
(REF) dev/core#1724 - SettingsBag - Convert to computeVirtual/updateVirtual

The `SettingsBag` uses the `$combined` property to (locally) cache a full
view of the active settings (based on combining different layers of data --
default-values, explicit-values, and mandatory-values). This design is
good for read-mostly data.

This patch changes the `__ContributionSettings` to be another layer in the
construction of `$combined` -- the virtual-values layer.  It fixes issues
wherein:

1. The virtual value is recomputed during every call to `get($key)`.

2. The virtual value is only based on explicit-values -- it disregards
   default-values and mandatory-values.

4 years agodev/core#1724 - SettingsBagTest - Add coverage for contribution_invoice_settings
Tim Otten [Tue, 28 Apr 2020 21:24:34 +0000 (14:24 -0700)]
dev/core#1724 - SettingsBagTest - Add coverage for contribution_invoice_settings

4 years agoAdd contribution source to recurring contribution report
Alexy Mikhailichenko [Tue, 28 Apr 2020 20:55:51 +0000 (13:55 -0700)]
Add contribution source to recurring contribution report

4 years agoask for link to external conversations
demeritcowboy [Tue, 28 Apr 2020 20:35:40 +0000 (16:35 -0400)]
ask for link to external conversations