civicrm-core.git
3 years agoMerge pull request #19551 from eileenmcnaughton/msg_tpl_convert_test
Matthew Wire [Sun, 7 Feb 2021 15:41:27 +0000 (15:41 +0000)]
Merge pull request #19551 from eileenmcnaughton/msg_tpl_convert_test

Add unit test cover for the MessageTemplate::renderMessageTemplate function

3 years agoMerge pull request #19509 from jmcclelland/correctSmsNumbers
Matthew Wire [Sun, 7 Feb 2021 15:39:59 +0000 (15:39 +0000)]
Merge pull request #19509 from jmcclelland/correctSmsNumbers

Correct sms numbers

3 years agoMerge pull request #19553 from demeritcowboy/activity-import-test
Eileen McNaughton [Sun, 7 Feb 2021 04:25:38 +0000 (17:25 +1300)]
Merge pull request #19553 from demeritcowboy/activity-import-test

dev/core#2308 - Fix Activity Import Parser test and convert to civi statics

3 years agofix test and convert to civi statics
demeritcowboy [Sun, 7 Feb 2021 02:47:47 +0000 (21:47 -0500)]
fix test and convert to civi statics

3 years agoAdd unit test cover for the MessageTemplate::renderMessageTemplate function
eileen [Sat, 6 Feb 2021 03:19:30 +0000 (16:19 +1300)]
Add unit test cover for the MessageTemplate::renderMessageTemplate function

This provides cover for the 4 methods
- domain tokens
- contact tokens
- smarty assigns within the function
- smarty assigns before the function

3 years agoMerge pull request #19552 from demeritcowboy/php74-notice
Eileen McNaughton [Sat, 6 Feb 2021 21:40:57 +0000 (10:40 +1300)]
Merge pull request #19552 from demeritcowboy/php74-notice

php 7.4 E_NOTICE in Contact/BAO/Query

3 years agophp 7.4 notice
demeritcowboy [Sat, 6 Feb 2021 19:33:43 +0000 (14:33 -0500)]
php 7.4 notice

3 years agoMerge pull request #19531 from ahed-compucorp/master
colemanw [Sat, 6 Feb 2021 17:40:28 +0000 (12:40 -0500)]
Merge pull request #19531 from ahed-compucorp/master

Improve consistency of field titles, labels, types across the schema

3 years agoFix failing tests after regenerating DAO files
Ahed [Sat, 6 Feb 2021 11:37:09 +0000 (13:37 +0200)]
Fix failing tests after regenerating DAO files

3 years agoRegenerate DAO files
Ahed [Sat, 6 Feb 2021 11:36:32 +0000 (13:36 +0200)]
Regenerate DAO files

3 years agoMerge pull request #19524 from eileenmcnaughton/member
Eileen McNaughton [Sat, 6 Feb 2021 00:08:01 +0000 (13:08 +1300)]
Merge pull request #19524 from eileenmcnaughton/member

[REF] Simplify is_email_receipt handling

3 years agoMerge pull request #19545 from demeritcowboy/membership-notice-php74
Eileen McNaughton [Fri, 5 Feb 2021 23:44:14 +0000 (12:44 +1300)]
Merge pull request #19545 from demeritcowboy/membership-notice-php74

php 7.4 - E_NOTICE on membership dashboard

3 years agoMerge pull request #19548 from civicrm/5.35
Eileen McNaughton [Fri, 5 Feb 2021 23:43:20 +0000 (12:43 +1300)]
Merge pull request #19548 from civicrm/5.35

5.35 to master

3 years agoMerge pull request #19546 from colemanw/labelField
Eileen McNaughton [Fri, 5 Feb 2021 23:42:45 +0000 (12:42 +1300)]
Merge pull request #19546 from colemanw/labelField

APIv4 - Fix label_field to use underscore instead of camelCase

3 years agoFix any title or label that contain name of own entity
Ahed [Fri, 5 Feb 2021 19:34:33 +0000 (21:34 +0200)]
Fix any title or label that contain name of own entity

3 years agoEnsure field's title and html's lable attributes populated properly
Ahed [Fri, 5 Feb 2021 09:33:13 +0000 (11:33 +0200)]
Ensure field's title and html's lable attributes populated properly

3 years agoAdd html tag to all files in xml/schema
Ahed [Thu, 4 Feb 2021 19:48:41 +0000 (21:48 +0200)]
Add html tag to all files in xml/schema

3 years agoMerge pull request #18830 from adixon/asset-building-error-2137
Eileen McNaughton [Fri, 5 Feb 2021 21:40:33 +0000 (10:40 +1300)]
Merge pull request #18830 from adixon/asset-building-error-2137

put asset rendering call into a try/catch - dev/core #2137

3 years ago[REF] Simplify is_email_receipt handling
eileen [Thu, 4 Feb 2021 03:13:06 +0000 (16:13 +1300)]
[REF] Simplify is_email_receipt handling

This removes a chunk of confusing handling from the previously shared code.

Philosophically we have a lot of arrays of data being passed around. The difference
between these arrays is unclear & the array that appears to exist specifically to
how what was actually submitted (formValues) is edited rather than left intact.

Where we are not dealing with a calcuated value, but rather referring to
what was submitted the quickform function getSubmittedValue() seems
like a good pick. It's clear we are looking up the submitted value not
some calculated value & when code is moved around we know this
value is not dependent on where it is sitting in the code.

The function returns 1 or NULL - hence I cast to boolean where I'm not
sure NULL is good enough

3 years agophp 7.4 is a bit stricter
demeritcowboy [Fri, 5 Feb 2021 20:39:37 +0000 (15:39 -0500)]
php 7.4 is a bit stricter

3 years agoAPIv4 - Fix label_field to use underscore instead of camelCase
Coleman Watts [Fri, 5 Feb 2021 20:36:26 +0000 (15:36 -0500)]
APIv4 - Fix label_field to use underscore instead of camelCase

3 years agoLog unexpected missing asset during AssetBuilder::build
Alan Dixon [Wed, 21 Oct 2020 20:24:41 +0000 (20:24 +0000)]
Log unexpected missing asset during AssetBuilder::build

3 years agoput asset rendering call into a try/catch
Alan Dixon [Wed, 21 Oct 2020 20:24:41 +0000 (20:24 +0000)]
put asset rendering call into a try/catch

3 years agoMerge pull request #19538 from eileenmcnaughton/repeat
Matthew Wire [Fri, 5 Feb 2021 11:24:22 +0000 (11:24 +0000)]
Merge pull request #19538 from eileenmcnaughton/repeat

[REF] [Repeattransaction] Stop setting contribution->id

3 years agoMerge pull request #19539 from eileenmcnaughton/repeat_fin
Matthew Wire [Fri, 5 Feb 2021 11:22:04 +0000 (11:22 +0000)]
Merge pull request #19539 from eileenmcnaughton/repeat_fin

[REF] [Repeattransaction] use financial_type_id from getTemplateContribution (which already has handling)

3 years agoMerge pull request #19540 from eileenmcnaughton/cont_page_input
Matthew Wire [Fri, 5 Feb 2021 11:20:08 +0000 (11:20 +0000)]
Merge pull request #19540 from eileenmcnaughton/cont_page_input

[REF] [Repeattransaction] Remove loading contribution page id from passed in object

3 years agoMerge pull request #19530 from colemanw/searchDisplayBlocks
Seamus Lee [Fri, 5 Feb 2021 08:04:36 +0000 (19:04 +1100)]
Merge pull request #19530 from colemanw/searchDisplayBlocks

Afform Gui - Block editing enhancements

3 years agoMerge pull request #19542 from seamuslee001/afform_fix_array_access
Eileen McNaughton [Fri, 5 Feb 2021 06:12:35 +0000 (19:12 +1300)]
Merge pull request #19542 from seamuslee001/afform_fix_array_access

[REF] Fix array access on NULL error when running afform unit tests o…

3 years agoMerge pull request #19541 from totten/master-aff-mock
Eileen McNaughton [Fri, 5 Feb 2021 05:45:52 +0000 (18:45 +1300)]
Merge pull request #19541 from totten/master-aff-mock

afform_mock - Hide extension. Clearly indicate as development-only

3 years ago[REF] Fix array access on NULL error when running afform unit tests on PHP 7.4
Seamus Lee [Fri, 5 Feb 2021 04:34:32 +0000 (15:34 +1100)]
[REF] Fix array access on NULL error when running afform unit tests on PHP 7.4

3 years ago(NFC) afform_mock - Hide extension. Clearly indicate as development-only.
Tim Otten [Fri, 5 Feb 2021 04:21:47 +0000 (20:21 -0800)]
(NFC) afform_mock - Hide extension. Clearly indicate as development-only.

3 years agoMerge pull request #19537 from colemanw/aliasLength
Eileen McNaughton [Fri, 5 Feb 2021 03:52:15 +0000 (16:52 +1300)]
Merge pull request #19537 from colemanw/aliasLength

APIv4 - Increase alias max length to 256

3 years ago[REF] Remove loading contribution page id from passed in object
eileen [Fri, 5 Feb 2021 03:15:25 +0000 (16:15 +1300)]
[REF] Remove loading contribution page id from passed in object

I believe this became obsolete with this PR
https://github.com/civicrm/civicrm-core/commit/6c3e774c322267c8e4449006db9cc14202b7028f

The other 2 (paypal) IPN classes no longer set contribution_page_id deliberately so
would be relying on the same data used for getTemplateContribution

3 years ago[REF] use financial_type_id from getTemplateContribution (which already has handling)
eileen [Fri, 5 Feb 2021 02:42:57 +0000 (15:42 +1300)]
[REF] use financial_type_id from getTemplateContribution (which already has handling)

The removed code is already incorporated into getTemplateContribution
and has test cover in testRepeatTransactionPassedInFinancialType

3 years ago[REF] Stop setting contribution->id
eileen [Fri, 5 Feb 2021 02:33:11 +0000 (15:33 +1300)]
[REF] Stop setting contribution->id

This is not needed as we can otherwise get it from the contributionResult directly

3 years agoAPIv4 - Increase alias max length to 256
Coleman Watts [Fri, 5 Feb 2021 01:52:45 +0000 (20:52 -0500)]
APIv4 - Increase alias max length to 256

3 years agoMerge pull request #19535 from colemanw/escapeRows
Monish Deb [Fri, 5 Feb 2021 01:11:19 +0000 (06:41 +0530)]
Merge pull request #19535 from colemanw/escapeRows

dev/core#2360 - Escape the word `rows` in sql query

3 years agoMerge pull request #19508 from mattwire/loadmemlineitems
Eileen McNaughton [Fri, 5 Feb 2021 00:19:17 +0000 (13:19 +1300)]
Merge pull request #19508 from mattwire/loadmemlineitems

Fix display of membership dates on receipts when lineitems do not have a price_set_id

3 years agoMerge pull request #19534 from civicrm/5.35
Eileen McNaughton [Fri, 5 Feb 2021 00:14:53 +0000 (13:14 +1300)]
Merge pull request #19534 from civicrm/5.35

5.35

3 years agodev/core#2360 - Escape the word `rows` in sql query
Coleman Watts [Thu, 4 Feb 2021 23:10:42 +0000 (18:10 -0500)]
dev/core#2360 - Escape the word `rows` in sql query

3 years agoMerge pull request #19533 from totten/master-api4-status-code
Seamus Lee [Thu, 4 Feb 2021 23:07:52 +0000 (10:07 +1100)]
Merge pull request #19533 from totten/master-api4-status-code

APIv4 - Fix HTTP status code selection

3 years agoMerge pull request #19529 from agh1/5.35.0-releasenotes-initial
Seamus Lee [Thu, 4 Feb 2021 21:55:06 +0000 (08:55 +1100)]
Merge pull request #19529 from agh1/5.35.0-releasenotes-initial

5.35.0 release notes - initial run

3 years agoAPIv4 - Fix HTTP status code selection
Tim Otten [Thu, 4 Feb 2021 21:15:17 +0000 (13:15 -0800)]
APIv4 - Fix HTTP status code selection

This is a follow-up to #19526 which addresses a typo that causes a misbehavior in reporting the HTTP status code.

Before
------

If an API request encounters an exception, then it always returns HTTP 403.

After
-----

If an API request encounters an exception, then:

* It may return HTTP 403 (for an authorization exception)
* It may return HTTP 500 (for any other/unrecognized exception)

3 years agoMerge pull request #19463 from colemanw/removeCampaignPseudoconstant
Eileen McNaughton [Thu, 4 Feb 2021 21:15:08 +0000 (10:15 +1300)]
Merge pull request #19463 from colemanw/removeCampaignPseudoconstant

Remove campaign_id pseudoconstants

3 years agoRemove campaign pseudoconstants from tests
Coleman Watts [Sat, 30 Jan 2021 02:45:07 +0000 (21:45 -0500)]
Remove campaign pseudoconstants from tests

3 years agoRemove campaign_id pseudoconstants
Coleman Watts [Sat, 30 Jan 2021 00:28:06 +0000 (19:28 -0500)]
Remove campaign_id pseudoconstants

Pseudoconstants are intended for option lists small enough to be loaded into memory,
whereas FKs are for options of any size.
It is possible to have thousands of campaigns, and some sites do,
which slows or breaks some UIs (first noticed in the Search Kit bulk update action).

All these fields have both an FK and a pseudoconstant declared, which is redundant;
both are not needed, and the pseudoconstant was unnecessarily hogging memory for sites with many campaigns.

3 years agoAfform Gui - Support editing entity-agnostic Content Blocks
Coleman Watts [Thu, 4 Feb 2021 19:16:21 +0000 (14:16 -0500)]
Afform Gui - Support editing entity-agnostic Content Blocks

3 years agoAfform Gui - Improve speed & accuracy of rendering fields/blocks palette
Coleman Watts [Thu, 4 Feb 2021 17:10:38 +0000 (12:10 -0500)]
Afform Gui - Improve speed & accuracy of rendering fields/blocks palette

Ensure the palette gets refreshed when saving a new block, and use ng-change instead of $watch

3 years ago5.35.0 release notes: added boilerplate
Andrew Hunt [Thu, 4 Feb 2021 16:26:40 +0000 (11:26 -0500)]
5.35.0 release notes: added boilerplate

3 years ago5.35.0 release notes: raw from script
Andrew Hunt [Thu, 4 Feb 2021 16:23:48 +0000 (11:23 -0500)]
5.35.0 release notes: raw from script

3 years agoAfform Gui - Move elements to top of palette (block list could be very long)
Coleman Watts [Thu, 4 Feb 2021 16:12:36 +0000 (11:12 -0500)]
Afform Gui - Move elements to top of palette (block list could be very long)

3 years agoAfform GUI - Fix search display block saving
Coleman Watts [Thu, 4 Feb 2021 15:07:06 +0000 (10:07 -0500)]
Afform GUI - Fix search display block saving

3 years agoAfform GUI - Enable blocks on search display afforms & optimize loading
Coleman Watts [Thu, 4 Feb 2021 14:32:32 +0000 (09:32 -0500)]
Afform GUI - Enable blocks on search display afforms & optimize loading

3 years agoMerge pull request #19527 from eileenmcnaughton/complete
Matthew Wire [Thu, 4 Feb 2021 11:57:16 +0000 (11:57 +0000)]
Merge pull request #19527 from eileenmcnaughton/complete

[REF] Complete order Unset contribution once we have finished with it.

3 years agoMerge pull request #19522 from eileenmcnaughton/ref_template
Matthew Wire [Thu, 4 Feb 2021 11:36:16 +0000 (11:36 +0000)]
Merge pull request #19522 from eileenmcnaughton/ref_template

[REF] Further extract the portion of sendTemplate that relates to rendering

3 years agoMerge pull request #19494 from seamuslee001/apiv4_annon_access
Eileen McNaughton [Thu, 4 Feb 2021 07:47:07 +0000 (20:47 +1300)]
Merge pull request #19494 from seamuslee001/apiv4_annon_access

(REF) APIv4 - Add hook for whitelisting select AJAX API's for anonymous invocation

3 years agoMerge pull request #19526 from totten/master-api4-error
Seamus Lee [Thu, 4 Feb 2021 07:40:07 +0000 (18:40 +1100)]
Merge pull request #19526 from totten/master-api4-error

APIv4 - AJAX errors should say *something* useful

3 years agoSet version to 5.36.alpha1
CiviCRM [Thu, 4 Feb 2021 07:05:43 +0000 (07:05 +0000)]
Set version to 5.36.alpha1

3 years agoSet version to 5.35.beta1
CiviCRM [Thu, 4 Feb 2021 07:00:42 +0000 (07:00 +0000)]
Set version to 5.35.beta1

3 years ago[REF] Complete order
eileen [Thu, 4 Feb 2021 04:50:29 +0000 (17:50 +1300)]
[REF] Complete order

Unset contribution once we have finished with it.

This patch does very little but it takes a bit of searching to check the handful of places
that call completeOrder and check that none of them use the contribution
object after this function call. With this merged it will be possible to
cleanup the references to the contribution in the repeattransaction
code safe in the knowledge that the object is not needed after that
function (or within it from my reading). It seems likely we can switch to
passing in contributionID rather than the whole object.

3 years agoAPIv4 - AJAX errors should say *something* useful
Tim Otten [Thu, 4 Feb 2021 03:46:49 +0000 (19:46 -0800)]
APIv4 - AJAX errors should say *something* useful

When calling APIv4 via AJAX, you may sometimes encounter an error. What response do you get?

Before
------

You are likely to get a completely blank response (`status=500, body=[]`).
There is no information in any of the logs (Apache, PHP, CiviCRM, etc).  You
have no way to tell what's gone wrong.

Of course, if you're logged in as a full administrator, then you may have
permission `view debug output`, in which case there might be something
useful.  But this won't help if you're using a less privileged user.

After
-----

For the administrator (`view debug output`), you still get a detailed error response.

For less privileged users, the error is logged. The response provides a generic message along with an
"Error ID". You can use the "Error ID" to locate information in the log.

Also, if the error is an `UnauthorizedException`, then the response code will be a semantic 403 instead of a generic 500.

3 years agoAfform.prefill - Allow anonymous requests
Tim Otten [Thu, 4 Feb 2021 03:46:12 +0000 (19:46 -0800)]
Afform.prefill - Allow anonymous requests

This API has its own security checks

3 years ago(NFC) hook_civicrm_alterApiRoutePermissions - Expand on docblock
Tim Otten [Thu, 4 Feb 2021 02:59:12 +0000 (18:59 -0800)]
(NFC) hook_civicrm_alterApiRoutePermissions - Expand on docblock

3 years agoMerge pull request #19521 from civicrm/5.34
Seamus Lee [Thu, 4 Feb 2021 01:49:34 +0000 (12:49 +1100)]
Merge pull request #19521 from civicrm/5.34

5.34

3 years agoMerge pull request #19519 from colemanw/afformGuiFixBlocks
Seamus Lee [Thu, 4 Feb 2021 01:42:31 +0000 (12:42 +1100)]
Merge pull request #19519 from colemanw/afformGuiFixBlocks

Afform GUI - Fix errors when creating & saving blocks

3 years ago[REF] Further extract the portion of sendTemplate that relates to rendering
eileen [Thu, 4 Feb 2021 00:51:45 +0000 (13:51 +1300)]
[REF] Further extract the portion of sendTemplate that relates to rendering

This is primary for the purposes of simplification at this stage

3 years agoMerge pull request #19520 from agh1/5.34.0-releasenotes-final
Seamus Lee [Thu, 4 Feb 2021 00:17:39 +0000 (11:17 +1100)]
Merge pull request #19520 from agh1/5.34.0-releasenotes-final

5.34.0 release notes: final edits and late changes

3 years ago5.34.0 release notes: final edits and late changes
Andrew Hunt [Thu, 4 Feb 2021 00:09:24 +0000 (19:09 -0500)]
5.34.0 release notes: final edits and late changes

3 years agoAfform Gui - Exclude self from list of available blocks when editing a block
Coleman Watts [Wed, 3 Feb 2021 23:55:02 +0000 (18:55 -0500)]
Afform Gui - Exclude self from list of available blocks when editing a block

3 years agoMerge pull request #19464 from eileenmcnaughton/menu
colemanw [Wed, 3 Feb 2021 23:46:26 +0000 (18:46 -0500)]
Merge pull request #19464 from eileenmcnaughton/menu

dev/core#2340 Skip rather than fail on bad menu item

3 years agoMerge pull request #19514 from colemanw/apiRelativeDateFix
Eileen McNaughton [Wed, 3 Feb 2021 23:30:23 +0000 (12:30 +1300)]
Merge pull request #19514 from colemanw/apiRelativeDateFix

APIv4 - Fix bug when using relative date filters in ON clause of a join

3 years agoAfform GUI - Fix errors when creating & saving blocks
Coleman Watts [Wed, 3 Feb 2021 22:58:38 +0000 (17:58 -0500)]
Afform GUI - Fix errors when creating & saving blocks

3 years agoMerge pull request #19517 from seamuslee001/fix_user_load_deprecation
Eileen McNaughton [Wed, 3 Feb 2021 22:42:42 +0000 (11:42 +1300)]
Merge pull request #19517 from seamuslee001/fix_user_load_deprecation

Override the DrupalBase getUserObject function with a Drupal8/9 compa…

3 years agoMerge pull request #19516 from colemanw/apiGetFkFields
Eileen McNaughton [Wed, 3 Feb 2021 21:57:16 +0000 (10:57 +1300)]
Merge pull request #19516 from colemanw/apiGetFkFields

APIv4 - Enable getFields to find fields across implicit FK joins

3 years agoMerge pull request #19510 from eileenmcnaughton/msg_tpl
Matthew Wire [Wed, 3 Feb 2021 21:04:54 +0000 (21:04 +0000)]
Merge pull request #19510 from eileenmcnaughton/msg_tpl

[REF] Extract logical functions from sendTemplate

3 years agoOverride the DrupalBase getUserObject function with a Drupal8/9 compatible version
Seamus Lee [Wed, 3 Feb 2021 20:41:07 +0000 (07:41 +1100)]
Override the DrupalBase getUserObject function with a Drupal8/9 compatible version

3 years agoMerge pull request #19443 from eileenmcnaughton/ipn
Matthew Wire [Wed, 3 Feb 2021 20:58:45 +0000 (20:58 +0000)]
Merge pull request #19443 from eileenmcnaughton/ipn

[REF] Move sendNotification out of recur, remove unused related_contact

3 years agoMerge pull request #19511 from eileenmcnaughton/mem_clean
Matthew Wire [Wed, 3 Feb 2021 20:57:13 +0000 (20:57 +0000)]
Merge pull request #19511 from eileenmcnaughton/mem_clean

[REF] Remove invalid attempt to load contriution id from invoiceID

3 years agoMerge pull request #19498 from eileenmcnaughton/complete_order_test
Seamus Lee [Wed, 3 Feb 2021 20:21:57 +0000 (07:21 +1100)]
Merge pull request #19498 from eileenmcnaughton/complete_order_test

[REF] Stop passing contributionPageID to isEmailReceipt

3 years agoMerge pull request #19515 from demeritcowboy/amtg-notice
Eileen McNaughton [Wed, 3 Feb 2021 20:11:32 +0000 (09:11 +1300)]
Merge pull request #19515 from demeritcowboy/amtg-notice

dev/core#2355 - E_NOTICE on Manage Contribution and Manage Event listings

3 years agoAPIv4 - Enable getFields to find fields across implicit FK joins
Coleman Watts [Wed, 3 Feb 2021 16:48:26 +0000 (11:48 -0500)]
APIv4 - Enable getFields to find fields across implicit FK joins

Now it is possible to retrieve field metadata for a joined entity

3 years agoE_NOTICE on contribution pages
demeritcowboy [Wed, 3 Feb 2021 14:24:46 +0000 (09:24 -0500)]
E_NOTICE on contribution pages

3 years agoAPIv4 - Fix bug when using relative date filters in ON clause of a join
Coleman Watts [Wed, 3 Feb 2021 13:18:36 +0000 (08:18 -0500)]
APIv4 - Fix bug when using relative date filters in ON clause of a join

3 years agoMerge pull request #19496 from colemanw/afformBugFixes
Eileen McNaughton [Wed, 3 Feb 2021 11:26:33 +0000 (00:26 +1300)]
Merge pull request #19496 from colemanw/afformBugFixes

Afform - Misc tweaks, validation & bug fixes

3 years agoMerge pull request #19513 from eileenmcnaughton/kernel_error
Eileen McNaughton [Wed, 3 Feb 2021 09:24:54 +0000 (22:24 +1300)]
Merge pull request #19513 from eileenmcnaughton/kernel_error

Move require once in api kernel to support edge cases

3 years agoMerge pull request #19492 from demeritcowboy/fatalerrorhandler
Seamus Lee [Wed, 3 Feb 2021 09:17:23 +0000 (20:17 +1100)]
Merge pull request #19492 from demeritcowboy/fatalerrorhandler

dev/core#2350 - Oauth extension - Setting a fatalErrorHandler might override the redirect url because typo

3 years agoconfig-form.html - Fix rendering of client-side validation error for "server_route"
Tim Otten [Wed, 3 Feb 2021 08:35:14 +0000 (00:35 -0800)]
config-form.html - Fix rendering of client-side validation error for "server_route"

3 years agoMove require once in api kernel to support edge cases
eileen [Wed, 3 Feb 2021 07:23:35 +0000 (20:23 +1300)]
Move require once in api kernel to support edge cases

The function 'createError' on the kernel class calls 3 functions that are in the api v3 utils file.
It is possible to reach this from apiv4 using drush (I realise we
don't really know much about how to support api v4 with drush but it DOES work with a simple
api with this patch in my testing). We could go with only including utils.php in
v4 api AND the createError function. I think it's more readable this way.

To test this try

 drush  cvapi  Contribution.get version=4

it will legitimately fail without checkPermissions=0 but it will fail with a
require_once error without this patch

3 years agoSearch Kit - Improve display of afforms in search list
Coleman Watts [Wed, 3 Feb 2021 01:57:03 +0000 (20:57 -0500)]
Search Kit - Improve display of afforms in search list

3 years agoRemove defunct reference to skilCleanMoney
eileen [Wed, 3 Feb 2021 01:42:29 +0000 (14:42 +1300)]
Remove defunct reference to skilCleanMoney

The BAO used to handle this param but it no longer does. The api does respond to it - but defaults to
true (we don't call the api here but anything other than setting it to false will always do nothing)

3 years agoRemove attempt to load contriution id from invoiceID
eileen [Wed, 3 Feb 2021 01:38:49 +0000 (14:38 +1300)]
Remove attempt to load contriution id from invoiceID

This might make sense (maybe) on the front end code this was previously shared with but on the
backoffice form id would be specifically set in the url

3 years ago[REF] Extract logical functions from sendTemplate
eileen [Tue, 2 Feb 2021 22:51:44 +0000 (11:51 +1300)]
[REF] Extract logical functions from sendTemplate

This simply makes it clear what the main chunks of code are doing

3 years ago[REF] Stop passing contributionPageID to isEmailReceipt
eileen [Tue, 2 Feb 2021 01:15:25 +0000 (14:15 +1300)]
[REF] Stop passing contributionPageID to isEmailReceipt

By switching to passing in contributionID instead we can significantly simplify this.

It could cause an extra query in some cases but the query would be very quick based
on my previous query reduction efforts and this will help us
remove a bunch of other code

3 years agoMerge pull request #19417 from eileenmcnaughton/test
Monish Deb [Tue, 2 Feb 2021 23:24:23 +0000 (04:54 +0530)]
Merge pull request #19417 from eileenmcnaughton/test

[REF] Standardise methods of determining isTest

3 years agoMerge pull request #19505 from mattwire/remotememrelated
Seamus Lee [Tue, 2 Feb 2021 22:28:05 +0000 (09:28 +1100)]
Merge pull request #19505 from mattwire/remotememrelated

Remove another use of loadRelatedObjects() function

3 years agoMerge pull request #19500 from eileenmcnaughton/cancel
Seamus Lee [Tue, 2 Feb 2021 22:16:58 +0000 (09:16 +1100)]
Merge pull request #19500 from eileenmcnaughton/cancel

dev/core#2206 Unhide contributioncancelactions core extension

3 years agorefactor to improve readability and expand test coverage.
Jamie McClelland [Tue, 2 Feb 2021 21:30:57 +0000 (16:30 -0500)]
refactor to improve readability and expand test coverage.

3 years agoMerge pull request #19507 from eileenmcnaughton/trans
Matthew Wire [Tue, 2 Feb 2021 21:24:03 +0000 (21:24 +0000)]
Merge pull request #19507 from eileenmcnaughton/trans

Comment intent to remove call to transition components

3 years agoensure we send to the right mobile numbers
Jamie McClelland [Tue, 2 Feb 2021 19:41:16 +0000 (14:41 -0500)]
ensure we send to the right mobile numbers

Depending on the order of contacts retrieved and whether or not the
mobile number is set to primary, we may repeat the same mobile number
over and over again.

3 years agoFix display of membership dates on receipts when lineitems do not have a price_set_id
Matthew Wire [Tue, 2 Feb 2021 21:05:21 +0000 (21:05 +0000)]
Fix display of membership dates on receipts when lineitems do not have a price_set_id