Matthew Wire [Mon, 2 Nov 2020 10:58:10 +0000 (10:58 +0000)]
Merge pull request #18903 from eileenmcnaughton/aip2
Remove deprecated code
Matthew Wire [Mon, 2 Nov 2020 10:55:38 +0000 (10:55 +0000)]
Merge pull request #18807 from jvos/postProcess-MessageTemplates
Add postProcess hook to MessageTemplates
Seamus Lee [Mon, 2 Nov 2020 06:50:56 +0000 (17:50 +1100)]
Merge pull request #18897 from eileenmcnaughton/ip3
[REF] Remove silly if
Seamus Lee [Mon, 2 Nov 2020 06:50:10 +0000 (17:50 +1100)]
Merge pull request #18902 from totten/master-altermailstore
dev/core#2141 - Add hook_civicrm_alterMailStore
eileen [Mon, 2 Nov 2020 04:18:54 +0000 (17:18 +1300)]
Remove deprecated code
These few lines have had any meaning removed already....
Seamus Lee [Mon, 2 Nov 2020 04:08:25 +0000 (15:08 +1100)]
Merge pull request #18852 from eileenmcnaughton/aip
[Ref] Move sending the email back out of the recur function
Tim Otten [Fri, 30 Oct 2020 23:01:42 +0000 (16:01 -0700)]
dev/core#2141 - Add hook_civicrm_alterMailStore
Overview
--------
The CiviCRM "MailStore" layer is used for importing email messages from
various sources (IMAP, POP3, Maildir, etc). There is a built-in list with a
handful of drivers (`CRM_Mailing_MailStore_Imap`, etc).
This patch adds a hook for manipulating those drivers.
Before
------
It's not possible for an extension to add a driver, modify a driver, etc.
After
-----
It is now possible to add/modify/replace drivers. Here are two examples.
(1) To supplement the IMAP authentication with a dynamic token for XOAuth2:
```php
function hook_civicrm_alterMailStore(&$mailSettings) {
if (...$mailSettings requires oauth...) {
$mailSettings['auth'] = 'XOAuth2';
$mailSettings['password'] = $myOauthSystem->getToken(...);
}
}
```
(2) To add a new protocol `FIZZBUZZ`, you would:
1. Register a value in the OptionGroup `mail_protocol`.
2. Create a driver class (eg `CRM_Mailing_MailStore_FizzBuzz` extends `CRM_Mailing_MailStore`)
3. Use the hook to activate the class:
```php
function hook_civicrm_alterMailStore(&$mailSettings) {
if ($mailSettings['protocol'] === 'FIZZBUZZ') {
$mailSettings['factory'] = function ($mailSettings) {
return new CRM_Mailing_MailStore_FizzBuzz(...);
};
}
}
```
Technical Details
-----------------
This adds a unit-test with examples of basic/non-hook behavior and hooked behavior.
In reading the diff for `getStore()`, note that it previously had a long
'switch()' to handle instantiation. I tried to make the change in a way that
you could see some continuity - e.g. it's still the same basic `switch()`.
The change is to basically wrap the bits inside a function:
* Before: `case 'FOO': return new Foo(...)`
* After: `case 'FOO': return ['factory' => function(...) { return new Foo(...); }]`
eileen [Mon, 2 Nov 2020 00:03:28 +0000 (13:03 +1300)]
[REF] Remove silly if
Checking component AND contributionRecur is silly - the latter will only
be set if relevant so remove the extra if
Eileen McNaughton [Sun, 1 Nov 2020 20:51:57 +0000 (09:51 +1300)]
Merge pull request #18893 from civicrm/5.31
5.31 to master
Eileen McNaughton [Sun, 1 Nov 2020 20:51:02 +0000 (09:51 +1300)]
Merge pull request #18877 from seamuslee001/dev_core_2149
dev/core#2149 Ensure that if a chained select field is required and t…
Matthew Wire [Sun, 1 Nov 2020 18:25:18 +0000 (18:25 +0000)]
Merge pull request #18881 from eileenmcnaughton/cancelb
dev/core#927 Move handling of participant.cancel from BaseIPN to contributioncancelactions
Matthew Wire [Sun, 1 Nov 2020 18:22:12 +0000 (18:22 +0000)]
Merge pull request #18882 from eileenmcnaughton/pps
[Ref] Use direct version of participant id
colemanw [Sat, 31 Oct 2020 13:44:15 +0000 (09:44 -0400)]
Merge pull request #18892 from eileenmcnaughton/uf
Hack away at false negative test fails
Seamus Lee [Sat, 31 Oct 2020 03:02:07 +0000 (14:02 +1100)]
Merge pull request #18891 from civicrm/5.31
5.31
Seamus Lee [Sat, 31 Oct 2020 00:53:04 +0000 (11:53 +1100)]
Merge pull request #18890 from seamuslee001/dev_core_2154
dev/core#2154 Fix the output of the full text custom search form
Eileen McNaughton [Fri, 30 Oct 2020 23:48:37 +0000 (12:48 +1300)]
Merge pull request #18887 from colemanw/entityPaths
Add entity paths to schema & APIv4
eileen [Fri, 30 Oct 2020 23:23:00 +0000 (12:23 +1300)]
Hack away at false negative test fails
colemanw [Fri, 30 Oct 2020 23:10:09 +0000 (19:10 -0400)]
Merge pull request #18889 from demeritcowboy/fulltext-attributes
dev/core#2154 - Pass correct parameters to CRM_Core_Form::add() in fulltext custom search
Seamus Lee [Fri, 30 Oct 2020 22:58:09 +0000 (09:58 +1100)]
Merge pull request #18876 from colemanw/searchDisplay
Lotsa new features for the Search Kit extension
Seamus Lee [Fri, 30 Oct 2020 22:44:19 +0000 (09:44 +1100)]
dev/core#2154 Fix the output of the full text custom search form
Eileen McNaughton [Fri, 30 Oct 2020 22:25:30 +0000 (11:25 +1300)]
Merge pull request #18888 from colemanw/deprecateCrudLink
Deprecate hook_civicrm_crudLink
Eileen McNaughton [Fri, 30 Oct 2020 22:18:34 +0000 (11:18 +1300)]
Merge pull request #18885 from totten/master-add-mail
dev/core#2141 - "Add Mail Account" - Allow hookable listing of setup links
demeritcowboy [Fri, 30 Oct 2020 21:33:03 +0000 (17:33 -0400)]
pass correct parameters
eileen [Fri, 30 Oct 2020 05:54:01 +0000 (18:54 +1300)]
Move handling of participant.cancel to contributioncancelactions extension
Coleman Watts [Fri, 30 Oct 2020 19:55:28 +0000 (15:55 -0400)]
Deprecate hook_civicrm_crudLink
The hook is not used anywhere in civicrm_universe, and the function calling it is only used in 1 place,
full-text search for generating links to file entities.
Seamus Lee [Fri, 30 Oct 2020 19:53:13 +0000 (06:53 +1100)]
Merge pull request #18886 from mlutfy/moneyTypo
(NFC) Fix typo in Money valueFormat depretation warning
Coleman Watts [Fri, 30 Oct 2020 19:38:10 +0000 (15:38 -0400)]
Mark version beta2 & add upgrade script
Coleman Watts [Fri, 30 Oct 2020 18:32:03 +0000 (14:32 -0400)]
Add entity paths to schema & APIv4
Entity paths can be used to construct a url to create/view/edit/update a given entity.
The paths are local and contain tokens which would need to be replace, e.g. [id] or [contact_id].
The token name corresponds to the field name whos value is requred.
colemanw [Fri, 30 Oct 2020 14:46:41 +0000 (10:46 -0400)]
Merge pull request #18884 from jaapjansma/dev_2152_master_2
/dev/core#2152: Merge contacts keep case roles
colemanw [Fri, 30 Oct 2020 13:23:24 +0000 (09:23 -0400)]
Merge pull request #18883 from eileenmcnaughton/ppp
Remove always-true & otherwise silly if
Mathieu Lutfy [Fri, 30 Oct 2020 13:08:00 +0000 (09:08 -0400)]
(NFC) Fix typo in Money valueFormat depretation warning
Tim Otten [Fri, 30 Oct 2020 06:59:51 +0000 (23:59 -0700)]
dev/core#2141 - "Add Mail Account" - Allow hookable listing of setup links
Overview
--------
For certain types of mail accounts -- such as Google Mail and Microsoft
Exchange Online -- the setup process may require interaction with a remote
web-service. The web-service provides some critical details (like
authentication tokens) and some handy details (like their username / email
address).
If the supports one of these services, then this revision will enable a
setup process. It alters the "Add Mail Account" action to use a more
fine-tuned procedure.
Before
------
* Navigate to "Administer => CiviMail => Mail Accounts".
* Below the table, there is a singular button "Add Mail Account".
* Click the button.
* It opens an empty form for configuring the account.
After
-----
By default, the UX is the same. However, if you have an extension like
`oauth-client`, then it changes:
* Navigate to "Administer => CiviMail => Mail Accounts".
* Below the table, there is a select box for "Add Mail Account". It lists different account types.
* Choose one of the options from the dropbox. The step depends on...
* If you choose "Standard Mail Account", it opens the empty config form.
* If you choose "Microsoft Exchange Online", it redirects to MS to get authorization
from the user. Then, it redirects and prefills the config form.
Jaap Jansma [Fri, 30 Oct 2020 10:08:42 +0000 (11:08 +0100)]
Fix for dev/core#2152
eileen [Fri, 30 Oct 2020 07:23:47 +0000 (20:23 +1300)]
Remove always-true & otherwise silly if
eileen [Fri, 30 Oct 2020 07:19:29 +0000 (20:19 +1300)]
[Ref] Use direct version of participant id
ids['Participant'] is taken from the url. It is then passed to loadRelatedObjects
where
https://github.com/civicrm/civicrm-core/blob/
0bd5e6bfbe8f339dbe066e3e96e00760c93a57e2/CRM/Contribute/BAO/Contribution.php#L2890
loads an object based on it. We then set ids too the object's id - which is a long way around to
using the paramter we started from. This does that
Seamus Lee [Fri, 30 Oct 2020 02:13:36 +0000 (13:13 +1100)]
Merge pull request #18879 from colemanw/fixDAOStyle
Fix extension generated DAO files to pass civilint
Coleman Watts [Fri, 30 Oct 2020 00:25:52 +0000 (20:25 -0400)]
Fix extension generated DAO files to pass civilint
Coleman Watts [Thu, 29 Oct 2020 20:58:29 +0000 (16:58 -0400)]
Search ext: Add option to format table cell as link in search display
Coleman Watts [Thu, 29 Oct 2020 17:18:48 +0000 (13:18 -0400)]
Search ext: decouple actions, add searchKit base module, rename searchAdmin module to crmSearchAdmin
Coleman Watts [Wed, 28 Oct 2020 20:15:34 +0000 (16:15 -0400)]
Search ext: Improve styling
Coleman Watts [Wed, 28 Oct 2020 18:02:36 +0000 (14:02 -0400)]
Search ext: Dynamic templates and a preview button for displays
Coleman Watts [Tue, 27 Oct 2020 20:18:41 +0000 (16:18 -0400)]
Search ext: Support for embedding search displays in afforms
Coleman Watts [Tue, 27 Oct 2020 14:36:07 +0000 (10:36 -0400)]
Search ext: Link to displays from admin screen
Coleman Watts [Tue, 27 Oct 2020 01:35:09 +0000 (21:35 -0400)]
Search ext: Exclude settings from being html-encoded in db
Coleman Watts [Tue, 20 Oct 2020 19:55:00 +0000 (15:55 -0400)]
Search ext: Add searchDisplay and searchPage modules
Coleman Watts [Sun, 18 Oct 2020 23:52:28 +0000 (19:52 -0400)]
Search ext: group tab
Coleman Watts [Sun, 18 Oct 2020 04:15:29 +0000 (00:15 -0400)]
Search ext: Rename component crmSearch to crmSearchAdmin
Coleman Watts [Sun, 18 Oct 2020 04:03:39 +0000 (00:03 -0400)]
Search ext: Add vertical tabs
Coleman Watts [Fri, 16 Oct 2020 18:42:27 +0000 (14:42 -0400)]
Search ext: Rework URL routing in preparation for search display management
Having the API params in the URL bar (like the API Explorer) was kinda neat but isn't going to work
with more complex management of multiple displays on the same screen.
This simplifies the routing to standard CRUD routes of /list, /create/:type, & /edit/:id
Coleman Watts [Fri, 16 Oct 2020 18:39:37 +0000 (14:39 -0400)]
Search ext: Improve wording of update & delete actions
Coleman Watts [Thu, 15 Oct 2020 20:35:50 +0000 (16:35 -0400)]
Search ext: Add list view
Coleman Watts [Thu, 15 Oct 2020 13:19:16 +0000 (09:19 -0400)]
Search ext: Add SearchDisplay database entity
Seamus Lee [Thu, 29 Oct 2020 23:08:35 +0000 (10:08 +1100)]
dev/core#2149 Ensure that if a chained select field is required and there are no valid options found ensure that jquery validation doesn't block submission
Eileen McNaughton [Thu, 29 Oct 2020 21:49:33 +0000 (10:49 +1300)]
Merge pull request #18875 from colemanw/5.31-merge
Merge branch 5.31 into master
Eileen McNaughton [Thu, 29 Oct 2020 21:48:56 +0000 (10:48 +1300)]
Merge pull request #18874 from mlutfy/totalParticipantTs
Participant Calculate/Fees: fix ts usage, simplify wording
Coleman Watts [Thu, 29 Oct 2020 21:19:51 +0000 (17:19 -0400)]
Merge branch '5.31' into master
Seamus Lee [Thu, 29 Oct 2020 21:03:18 +0000 (08:03 +1100)]
Merge pull request #18712 from eileenmcnaughton/locev3
dev/core#1879 Fix inconsistent ability to view event information
Eileen McNaughton [Thu, 29 Oct 2020 20:51:24 +0000 (09:51 +1300)]
Merge pull request #18867 from sunilpawar/sms_provider
Show only Active SMS provider List on Mass SMS form
Eileen McNaughton [Thu, 29 Oct 2020 20:12:25 +0000 (09:12 +1300)]
Merge pull request #18873 from colemanw/title_plural
APIv4 - Fix nonstandard camelCase of title_plural field
Mathieu Lutfy [Thu, 29 Oct 2020 18:57:09 +0000 (14:57 -0400)]
Participant Calculate/Fees: fix ts usage, simplify wording
Matthew Wire [Thu, 29 Oct 2020 17:26:43 +0000 (17:26 +0000)]
Merge pull request #18872 from seamuslee001/dev_core_2150
dev/core#2150 Re-enact the recapture validation by validating the res…
Coleman Watts [Thu, 29 Oct 2020 15:33:19 +0000 (11:33 -0400)]
APIv4 - Fix nonstandard camelCase of title_plural field
Seamus Lee [Thu, 29 Oct 2020 01:08:23 +0000 (12:08 +1100)]
dev/core#2150 Re-enact the recapture validation by validating the response token on recapture
Ensure the form rule is actually triggered not just registered
Eileen McNaughton [Wed, 28 Oct 2020 23:42:48 +0000 (12:42 +1300)]
Merge pull request #18871 from totten/master-api-single
APIv4 - Add `$result->single()` helper
Tim Otten [Wed, 28 Oct 2020 22:36:10 +0000 (15:36 -0700)]
Merge pull request #18870 from totten/master-api-al
ClassLoader - Fix autoloading of `API_Exception`
Tim Otten [Wed, 28 Oct 2020 02:44:41 +0000 (19:44 -0700)]
APIv4 - Add $result->single() helper
Tim Otten [Mon, 26 Oct 2020 22:21:06 +0000 (15:21 -0700)]
ClassLoader - Fix autoloading of API_Exception
Eileen McNaughton [Wed, 28 Oct 2020 20:14:15 +0000 (09:14 +1300)]
Merge pull request #18306 from mattwire/refactororderapientityparams
Refactor entityParams in Order.Create API so it is easier to understand/modify
Eileen McNaughton [Wed, 28 Oct 2020 20:13:10 +0000 (09:13 +1300)]
Merge pull request #18840 from yashodha/activity_report
(core/dev#2104) Add gender column for target contact to activity report
Matthew Wire [Wed, 28 Oct 2020 09:41:17 +0000 (09:41 +0000)]
Merge pull request #18853 from eileenmcnaughton/base
dev/core#927 Move cancelling of related memberships to extension from BaseIPN
Matthew Wire [Wed, 28 Oct 2020 09:38:50 +0000 (09:38 +0000)]
Merge pull request #18849 from eileenmcnaughton/finacl2
Move filtering of unpermitted options for reports/ search select to financialacl extension
Sunil Pawar [Wed, 28 Oct 2020 07:55:38 +0000 (13:25 +0530)]
Show only Active SMS provider List on Mass SMS form
eileen [Fri, 23 Oct 2020 05:36:14 +0000 (18:36 +1300)]
Move filtering of unpermitted options for reports/ search select to financial acl extension
Seamus Lee [Tue, 27 Oct 2020 22:11:40 +0000 (09:11 +1100)]
Merge pull request #18862 from demeritcowboy/mb-substr
dev/core#2146 - Long unicode contact names get truncated badly causing a crash
Eileen McNaughton [Tue, 27 Oct 2020 19:20:18 +0000 (08:20 +1300)]
Merge pull request #18860 from colemanw/fixEncode
APIv4 - Fix type coersion of non-string input
colemanw [Tue, 27 Oct 2020 18:25:26 +0000 (14:25 -0400)]
Merge pull request #18856 from eileenmcnaughton/int_amount
Remove meaningless legacy code
demeritcowboy [Mon, 26 Oct 2020 23:48:37 +0000 (19:48 -0400)]
truncate unicode strings better
Seamus Lee [Tue, 27 Oct 2020 03:06:13 +0000 (14:06 +1100)]
Merge pull request #18859 from masetto/italian_provinces
updated italian provinces (CRM-5048)
Eileen McNaughton [Tue, 27 Oct 2020 02:47:36 +0000 (15:47 +1300)]
Merge pull request #18861 from civicrm/5.31
5.31
Seamus Lee [Mon, 26 Oct 2020 23:11:24 +0000 (10:11 +1100)]
Merge pull request #18792 from eileenmcnaughton/status2
Fix campaign_id handling for batch entry
Seamus Lee [Mon, 26 Oct 2020 23:10:04 +0000 (10:10 +1100)]
Merge pull request #18857 from eileenmcnaughton/sort2
dev/core#2132 Fix for sort on search results
Matthew Wire [Fri, 21 Aug 2020 10:43:06 +0000 (11:43 +0100)]
Refactor entityParams in Order.Create API so it is easier to understand/modify
eileen [Mon, 26 Oct 2020 05:56:58 +0000 (18:56 +1300)]
dev/core#2132 Fix for sort on search results
Simpler fix - accept bad sql but catch it :-(
Ideally we would always be in exception mode
Coleman Watts [Mon, 26 Oct 2020 20:03:35 +0000 (16:03 -0400)]
APIv4 - Fix type coersion of non-string input
Eileen McNaughton [Mon, 26 Oct 2020 19:42:31 +0000 (08:42 +1300)]
Merge pull request #18808 from jvos/set-id-postProcess-mailing-Component
Set id after save for the mailing component in the postProcess
Samuele Masetto [Mon, 26 Oct 2020 18:07:40 +0000 (19:07 +0100)]
updated italian provinces (CRM-5048)
Samuele Masetto [Mon, 26 Oct 2020 15:55:33 +0000 (16:55 +0100)]
updated italian provinces (CRM-5048)
Dev [Tue, 20 Oct 2020 06:49:58 +0000 (08:49 +0200)]
Add postProcess hook to MessageTemplates
Added comments and removed withespace.
Dev [Tue, 20 Oct 2020 08:00:31 +0000 (10:00 +0200)]
Set id after save for the mailing component in the postProcess
Added comment and removed whitespace
Removed empty line.
eileen [Mon, 26 Oct 2020 05:22:38 +0000 (18:22 +1300)]
Remove meaningless legacy code
I looked around & I am pretty sure int_amount is never set and init_amount is never used
eileen [Fri, 23 Oct 2020 21:03:07 +0000 (10:03 +1300)]
Move sending the emaill back out of the recur function
This allows us not to pass in extra ids that are only required for that use and
steps us closer to not loading them
Seamus Lee [Mon, 26 Oct 2020 04:11:57 +0000 (15:11 +1100)]
Merge pull request #18848 from eileenmcnaughton/finacl
Move CRM_Member_BAO_MembershipType::getPermissionedMembershipTypes to financial acl extension
eileen [Mon, 19 Oct 2020 02:23:57 +0000 (15:23 +1300)]
Fix campaign_id handling for batch entry
Fixes a bug whereby campaign_id is not updated on batch entry if it has been added to the profile.
The underlying issue appears to be an attack of copy and paste. I tidied up the variable
in both the places that call the processMembership function such that it is passed in
as an array of pass-through params. The function can be simplified & eventually removed.
Eileen McNaughton [Sat, 24 Oct 2020 22:16:57 +0000 (11:16 +1300)]
Merge pull request #18745 from seamuslee001/backdrop_session
backdrop#116 Override sessionStart function and use backdrop function…
eileen [Fri, 23 Oct 2020 22:44:26 +0000 (11:44 +1300)]
dev/core#927 Move cancelling of related memberships to extension from BaseIPN
This moves the code to cancel memberships on a related contribution cancel to the contributioncancelactions
core extension.
Before
The cancellations are done using convoluted & elsewhere duplicated logic in BaseIPN
using convoluted input params
After
When a contribution is updated & the status_id of 'Cancellled' is set then
the hook will kick in, look for any related pending memberships and cancel them.
The test demonstrates that the api call will ensure related pending memberships
are cancelled.
Note that I am using line_items table to get the membership - we have been storing this
membership_payment link there for log enough it should be reliable but if there
are remaining data issues then this is a lower risk flow to flush them out.
Also note that once this is cleaned up I'll move to the 2 other flows I'm aware of
Order.create api & Contribuion form edits
Eileen McNaughton [Fri, 23 Oct 2020 21:57:20 +0000 (10:57 +1300)]
Merge pull request #18842 from ixiam/dev-#2138
Get phone_type by name. dev/core#2138
Matthew Wire [Fri, 23 Oct 2020 16:27:45 +0000 (17:27 +0100)]
Merge pull request #18850 from aydun/user-interface#34
dev/user-interface#34 Replace <th> with <td> on ContributionPage configuration Amount tab
Monish Deb [Fri, 23 Oct 2020 13:13:14 +0000 (18:43 +0530)]
Merge pull request #18835 from eileenmcnaughton/aip
dev/financial#152 [REF] Clean up interaction with contribution recur object
Monish Deb [Fri, 23 Oct 2020 12:39:36 +0000 (18:09 +0530)]
Merge pull request #18813 from eileenmcnaughton/base
dev/core#927 preliminary cleanup
Aidan Saunders [Fri, 23 Oct 2020 12:06:30 +0000 (13:06 +0100)]
Replace <th> with <td> on ContributionPage Amount tab