CiviCRM Core issueshttps://lab.civicrm.org/dev/core/-/issues2021-11-15T07:59:28Zhttps://lab.civicrm.org/dev/core/-/issues/2942Displaying map for contact address causes WP error2021-11-15T07:59:28Ztreasurer@tricitiesprideDisplaying map for contact address causes WP errorOverview
----------------------------------------
Selecting "map" from the contact detail causes a Wordpress error.
![image](/uploads/6da1e74e2278d36dd879c7cf4a106605/image.png)
![image](/uploads/86c348df39b887caa6d56a9f92756bee/image....Overview
----------------------------------------
Selecting "map" from the contact detail causes a Wordpress error.
![image](/uploads/6da1e74e2278d36dd879c7cf4a106605/image.png)
![image](/uploads/86c348df39b887caa6d56a9f92756bee/image.png)
Reproduction steps
----------------------------------------
1. Click on **Contacts -> Map**.
Current behaviour
----------------------------------------
Selecting "map" from the contact detail causes a Wordpress error.
![image](/uploads/6da1e74e2278d36dd879c7cf4a106605/image.png)
![image](/uploads/86c348df39b887caa6d56a9f92756bee/image.png)
```
Error Details
=============
An error of type E_ERROR was caused in line 128 of the file /wp-content/plugins/civicrm/civicrm/CRM/Contact/Form/Task/Map.php. Error message: Uncaught Error: Using $this when not in object context in /wp-content/plugins/civicrm/civicrm/CRM/Contact/Form/Task/Map.php:128
Stack trace:
#0 /wp-content/plugins/civicrm/civicrm/CRM/Contact/Form/Task/Map.php(92): CRM_Contact_Form_Task_Map::createMapXML(Array, 1, Object(CRM_Contact_Form_Task_Map), true, 'Contact')
#1 /wp-content/plugins/civicrm/civicrm/CRM/Core/Form.php(629): CRM_Contact_Form_Task_Map->preProcess()
#2 /wp-content/plugins/civicrm/civicrm/CRM/Core/QuickForm/Action/Display.php(76): CRM_Core_Form->buildForm()
#3 /wp-content/plugins/civicrm/civicrm/packages/HTML/QuickForm/Controller.php(203): CRM_Core_QuickForm_Action_Display->perform(Object(CRM_Contact_Form_Task_Map), 'display')
#4 /wp-content/plugins/civicrm/civicrm/packages/HTML/QuickForm/Page.php(103): HTML_QuickForm_Controller->handle(Object(CRM_C
```
Expected behaviour
----------------------------------------
Map should display
Environment information
----------------------------------------
* __Browser:__ _Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/95.0.4638.69 Safari/537.36_
* __CiviCRM:__ Version 5.43.0
* __PHP:__ _7.4.22__
* __CMS:__ _Wordpress Version 5.8.1_
* __Database:__ MariaDB 10.3.31-MariaDB-log-cll-lve - MariaDB Server..._
* __Web Server:__ Apache 2.4.48_5.43.1https://lab.civicrm.org/dev/core/-/issues/2923Upgrade to 5.43-RC causes Fatal `Class 'CRM_Contact_Form_Search_Custom_Base' ...2021-10-31T15:52:13ZkcristianoUpgrade to 5.43-RC causes Fatal `Class 'CRM_Contact_Form_Search_Custom_Base' not found`Upgrade to today's RC from 5.39.3 results in fatal errors and being unable to load the Admin UI or run `cv` commands.
`cv flush` results in
```
[Symfony\Component\Debug\Exception\FatalThrowableError]
Class 'CRM_Contact_Form_Search_C...Upgrade to today's RC from 5.39.3 results in fatal errors and being unable to load the Admin UI or run `cv` commands.
`cv flush` results in
```
[Symfony\Component\Debug\Exception\FatalThrowableError]
Class 'CRM_Contact_Form_Search_Custom_Base' not found
```
Removing all files (except .htaccess) under `templates_c` does not correct this error.
any other `cv` command results in the same error. `wp-admin/admin.php?page=CiviCRM&q=civicrm%2Fadmin%2Fsetting%2FupdateConfigBackend&reset=1`cannot load trying to clear from `/wp-admin/admin.php?page=civi_options` also fails
log shows:
```
[22-Oct-2021 12:49:27 UTC] PHP Fatal error: Uncaught Error: Class 'CRM_Contact_Form_Search_Custom_Base' not found in /home/wpcv/public_html/wp-content/uploads/civicrm/ext/dataprocessor/CRM/DataprocessorSearch/Form/Search/Custom/DataprocessorSmartGroupIntegration.php:29
Stack trace:
#0 /home/wpcv/public_html/wp-content/plugins/civicrm/civicrm/CRM/Core/ClassLoader.php(220): require_once()
#1 [internal function]: CRM_Core_ClassLoader->loadClass('CRM_Dataprocess...')
#2 /home/wpcv/public_html/wp-content/plugins/civicrm/civicrm/vendor/symfony/event-dispatcher/EventDispatcher.php(214): spl_autoload_call('CRM_Dataprocess...')
#3 /home/wpcv/public_html/wp-content/plugins/civicrm/civicrm/vendor/symfony/event-dispatcher/EventDispatcher.php(44): Symfony\Component\EventDispatcher\EventDispatcher->doDispatch(Array, 'civi.dao.postUp...', Object(Civi\Core\DAO\Event\PostUpdate))
#4 /home/wpcv/public_html/wp-content/plugins/civicrm/civicrm/Civi/Core/CiviEventDispatcher.php(198): Symfony\Component\EventDispatcher\EventDispatcher->dispatch('civi.dao.postUp...', Object(Civi\Co in /home/wpcv/public_html/wp-content/uploads/civicrm/ext/dataprocessor/CRM/DataprocessorSearch/Form/Search/Custom/DataprocessorSmartGroupIntegration.php on line 29
```
I had updated this site last week to 5.43-RC but I rolled back to production (5.39.3) for other reasons and today's RC build fails.
I can update to 5.42.1, so the issue appears to be in the RC.
I have not tried disabling DataProcessor before upgrade. I'll try thta and report back.https://lab.civicrm.org/dev/core/-/issues/2914Count of sent messages can be wrong in status popup for email form2021-10-18T14:28:03ZDaveDCount of sent messages can be wrong in status popup for email formMaster and 5.43 are broken right at this moment and you can't send any email, but in 5.43+ if you do this:
1. Contacts - New Email.
1. Add one of more valid recipients.
1. Fill it out and send.
1. The status popup will say 0 messages se...Master and 5.43 are broken right at this moment and you can't send any email, but in 5.43+ if you do this:
1. Contacts - New Email.
1. Add one of more valid recipients.
1. Fill it out and send.
1. The status popup will say 0 messages sent, even though they were sent. The number it shows is however many were prepopulated on the form when it first opened, and doesn't account for any you added or subtracted.
(This isn't about emails that were for deceased or on-hold etc.)
It worked in 5.42.5.43.0https://lab.civicrm.org/dev/core/-/issues/2902Date fields are empty on memberships (created with pay later OR with an API c...2021-10-14T04:08:04ZjitendraDate fields are empty on memberships (created with pay later OR with an API call)To replicate -
- Create a contribution page with Membership + Pay later.
- Submit the page in live mode.
- Date fields (join, start & end) are empty for the membership.
Found while writing this test - https://github.com/colemanw/webfor...To replicate -
- Create a contribution page with Membership + Pay later.
- Submit the page in live mode.
- Date fields (join, start & end) are empty for the membership.
Found while writing this test - https://github.com/colemanw/webform_civicrm/pull/622
Probably related to https://github.com/civicrm/civicrm-core/pull/20759 merge where api/v3 code used to calculate the dates for all NEW memberships. https://github.com/civicrm/civicrm-core/pull/20759/files#diff-74f06c64d06b6b6c191ff86ab31113f7198e73c0a1f8c5487116e7b3faef26fcL95
Now, in BAO, the membership date calculation is avoided if `skipStatusCal` is set in the params. See https://github.com/civicrm/civicrm-core/blob/master/CRM/Member/BAO/Membership.php#L260
I think a test with below API should be able to replicate it in the test
```
$membership = civicrm_api3('Membership', 'create', [
'membership_type_id' => "General",
'contact_id' => 2,
'status_id' => "Current", (or Pending, New, etc)
'skipStatusCal' => 1,
]);
// Verify if membership dates are correctly set. Currently, they're not.
```
I've confirmed that CiviCRM v5.35 sets the date on the above API call, but >5.40 does NOT. Does that seem to be an unintentional change of behavior?
Not sure what should be the desired result - Does the API call need to set start_date separately when `skipStatusCal` is enabled?
OR
`skipStatusCal` should only skip the calculation of "status" on the membership and continue to set the dates as it used to do in previous versions?
fyi - @KarinG @eileen5.42.1https://lab.civicrm.org/dev/core/-/issues/2901Find Activities + Send Email task always says the contact is on hold or decea...2021-10-10T12:48:05ZDaveDFind Activities + Send Email task always says the contact is on hold or deceased etcEven if all the communication prefs are good and the email is valid it still gives the warning message and doesn't let you send.
1. Find Activities.
2. Select one that has a valid With Contact who isn't deceased and doesn't have email o...Even if all the communication prefs are good and the email is valid it still gives the warning message and doesn't let you send.
1. Find Activities.
2. Select one that has a valid With Contact who isn't deceased and doesn't have email on hold etc.
3. From the actions dropdown choose send email
4. Choose With Contact.
5. Warning comes up and redirects you back to search. `Selected contact(s) do not have a valid email address, or communication preferences specify DO NOT EMAIL, or they are deceased or Primary email address is On Hold.`
I'm putting regression but not 100% sure it is recent.5.43.0https://lab.civicrm.org/dev/core/-/issues/2897Send an email activity is weird -possible unreleased regression in 5.43/master2021-10-10T01:01:55ZeileenSend an email activity is weird -possible unreleased regression in 5.43/masterhttps://lab.civicrm.org/dev/core/-/issues/2895Emails can't resolve tokens for non-contact components for recipients added t...2021-10-13T20:23:45ZDaveDEmails can't resolve tokens for non-contact components for recipients added to the list after email form was openedhttps://github.com/civicrm/civicrm-core/pull/21745#discussion_r724286717
Affects 5.43 only.
e.g.
1. Create a case email, e.g. clicking on the mail icon in the roles section.
1. Add a recipient to the recipient field.
1. In the body pu...https://github.com/civicrm/civicrm-core/pull/21745#discussion_r724286717
Affects 5.43 only.
e.g.
1. Create a case email, e.g. clicking on the mail icon in the roles section.
1. Add a recipient to the recipient field.
1. In the body put something like `Dear {contact.display_name} Case {case.id}`
1. The email sent to the original recipient will resolve case.id. The added recipient will have it blank.
See below this also applies to other non-contact components, e.g. event tokens.5.43.0https://lab.civicrm.org/dev/core/-/issues/2861regression: Custom searches are completely broken when used as smart groups2021-09-25T08:04:08ZJonGoldregression: Custom searches are completely broken when used as smart groupsI'm attaching a video that demonstrates the replication steps, but:
* Create a new custom search.
* The results of the search are correct.
* Save the results as a smart group.
* View the smart group.
* The smart group contains all contac...I'm attaching a video that demonstrates the replication steps, but:
* Create a new custom search.
* The results of the search are correct.
* Save the results as a smart group.
* View the smart group.
* The smart group contains all contacts.
![broken_custom_searches](/uploads/7298e847393f8456bb907c80820c6d93/broken_custom_searches.mp4)
This led to someone emailing all contacts in their database on a CiviMail, which they're predictably taking seriously.
I traced the issue and found that at `CRM_Contact_BAO_GroupContactCache::insertGroupContactsIntoTempTable()`, there's an [if statement](https://github.com/civicrm/civicrm-core/blob/master/CRM/Contact/BAO/GroupContactCache.php#L832) that looks like it should evaluate to `TRUE` that evaluates to `FALSE` but forcing it to `TRUE` doesn't solve the problem.5.41.2https://lab.civicrm.org/dev/core/-/issues/2856Something something tokens something tokens2021-09-23T15:28:04ZDaveDSomething something tokens something tokensThe below line seems to now be a problem for contribution receipts when using Order api. Trying to track it down - a (non-core) unit test that was working before is failing.
https://github.com/civicrm/civicrm-core/blob/29d047d701c7223e7...The below line seems to now be a problem for contribution receipts when using Order api. Trying to track it down - a (non-core) unit test that was working before is failing.
https://github.com/civicrm/civicrm-core/blob/29d047d701c7223e7999fc1f66381022c3dee0e7/Civi/Token/TokenProcessor.php#L435
Based on the lines above it, filter is expected to possibly be null, so `$filter[0]` errors. That seems pretty clear regardless.
What's confusing me is there must be tests in core that would trigger this, basically anything that uses order api + payment to complete a contribution, so am looking closer.5.43.0https://lab.civicrm.org/dev/core/-/issues/2840Recent items list behaving weird2021-09-16T14:55:28ZDaveDRecent items list behaving weirdSeems ok in 5.41 but in master it seems to only show the most recent item, sometimes 2. Also affects the recentitems extension.Seems ok in 5.41 but in master it seems to only show the most recent item, sometimes 2. Also affects the recentitems extension.5.42.0https://lab.civicrm.org/dev/core/-/issues/2839Contribution Thank You letters always have "_preview" on the end of the filename2021-09-20T17:59:38ZDaveDContribution Thank You letters always have "_preview" on the end of the filenameThis seems to be in master (5.43). Works ok in 5.42.This seems to be in master (5.43). Works ok in 5.42.5.43.0https://lab.civicrm.org/dev/core/-/issues/2835Activity export broken - takes you to some other screen instead2021-09-14T05:00:39ZDaveDActivity export broken - takes you to some other screen instead1. Find Activities
1. Select a couple and from the dropdown choose export.
1. You're now on a different screen - which screen seems to depend where you were before.
1. Warning: Illegal offset type in CRM_Activity_StateMachine_Search->__c...1. Find Activities
1. Select a couple and from the dropdown choose export.
1. You're now on a different screen - which screen seems to depend where you were before.
1. Warning: Illegal offset type in CRM_Activity_StateMachine_Search->__construct() (line 41 of ...\CRM\Activity\StateMachine\Search.php).
Working in 5.40.3, not working in 5.41.5.42.0https://lab.civicrm.org/dev/core/-/issues/2829Dashboard error `Trying to access array offset on value of type null`2021-09-12T22:46:24ZDaveDDashboard error `Trying to access array offset on value of type null`Pretty sure this is coming from https://github.com/civicrm/civicrm-core/pull/21424 which was just merged today.
```
#0 ...\Civi\Api4\Query\Api4SelectQuery.php(1033): "Trying to access array offset on value of type null", "...\Civi\A..."...Pretty sure this is coming from https://github.com/civicrm/civicrm-core/pull/21424 which was just merged today.
```
#0 ...\Civi\Api4\Query\Api4SelectQuery.php(1033): "Trying to access array offset on value of type null", "...\Civi\A...", 1033, (Array:8))
#1 ...\Civi\Api4\Query\Api4SelectQuery.php(250): Civi\Api4\Query\Api4SelectQuery->autoJoinFK("dashboard_contact.id")
#2 ...\Civi\Api4\Query\Api4SelectQuery.php(148): Civi\Api4\Query\Api4SelectQuery->buildSelectClause()
#3 ...\Civi\Api4\Query\Api4SelectQuery.php(164): Civi\Api4\Query\Api4SelectQuery->getSql()
#4 ...\Civi\Api4\Generic\DAOGetAction.php(111): Civi\Api4\Query\Api4SelectQuery->run()
#5 ...\Civi\Api4\Generic\DAOGetAction.php(99): Civi\Api4\Generic\DAOGetAction->getObjects(Object(Civi\Api4\Generic\Result))
#6 ...\Civi\Api4\Provider\ActionObjectProvider.php(68): Civi\Api4\Generic\DAOGetAction->_run(Object(Civi\Api4\Generic\Result))
#7 ...\Civi\API\Kernel.php(149): Civi\Api4\Provider\ActionObjectProvider->invoke(Object(Civi\Api4\Generic\DAOGetAction))
#8 ...\Civi\Api4\Generic\AbstractAction.php(234): Civi\API\Kernel->runRequest(Object(Civi\Api4\Generic\DAOGetAction))
#9 ...\api\api.php(85): Civi\Api4\Generic\AbstractAction->execute()
#10 ...\CRM\Core\BAO\Dashboard.php(69): civicrm_api4("Dashboard", "get", (Array:2))
#11 ...\CRM\Contact\Page\DashBoard.php(52): CRM_Core_BAO_Dashboard::getContactDashlets()
#12 ...\CRM\Core\Invoke.php(313): CRM_Contact_Page_DashBoard->run((Array:2), NULL)
#13 ...\CRM\Core\Invoke.php(69): CRM_Core_Invoke::runItem((Array:13))
#14 ...\CRM\Core\Invoke.php(36): CRM_Core_Invoke::_invoke((Array:2))
#15 ...\drupal\civicrm.module(458): CRM_Core_Invoke::invoke((Array:2))
#16 ...\includes\menu.inc(527): civicrm_invoke("dashboard")
#17 ...\index.php(21): menu_execute_active_handler()
#18 {main}
```5.43.0https://lab.civicrm.org/dev/core/-/issues/2828Getting system status message about contributeMode after upgrade to 5.43 when...2021-09-11T18:57:53ZDaveDGetting system status message about contributeMode after upgrade to 5.43 when it seems like it shouldn'tThis only affects master (5.43). You'd only see this on a site that was installed before 5.20 I think.
What seems to be happening is that the text version of the message template was updated in 5.20 at https://github.com/civicrm/civicrm...This only affects master (5.43). You'd only see this on a site that was installed before 5.20 I think.
What seems to be happening is that the text version of the message template was updated in 5.20 at https://github.com/civicrm/civicrm-core/pull/15682/files#diff-5eff848ae038ac430860eb2b822aa501ad7135621221116d204c5ee8ca07fcde, but the corresponding thing that replaces updated templates in the db didn't include a reference to the text version, just the html version: https://github.com/civicrm/civicrm-core/blob/f5eb3977811d1701a3c086f4ca5b34f8d172c958/CRM/Upgrade/Incremental/MessageTemplates.php#L118
So what happens is you still get the status notice since you have an old copy of the text version in the db.
I guess the way to fix this is to add `['name' => 'contribution_online_receipt', 'type' => 'text'],` into MessageTemplates.php numbered at 5.43?5.43.0https://lab.civicrm.org/dev/core/-/issues/2816New contribution can't be saved when validation fails on first try2021-09-17T19:48:05ZDaveDNew contribution can't be saved when validation fails on first try
1. Define a premium product.
1. Contributions - New Contribution
1. Fill out the contact and the amount, but forget, let's say, the financial type.
1. Click save.
1. Ok it warns you and reloads the form.
1. Now pick Donation.
1. Click s...
1. Define a premium product.
1. Contributions - New Contribution
1. Fill out the contact and the amount, but forget, let's say, the financial type.
1. Click save.
1. Ok it warns you and reloads the form.
1. Now pick Donation.
1. Click save.
```
INSERT INTO `civicrm_contribution_product` (`product_id` , `contribution_id` , `fulfilled_date` ) VALUES ( 0 , 96 , NULL ) [nativecode=1452 ** Cannot add or update a child row: a foreign key constraint fails (`dmastercivi_g5lis`.`civicrm_contribution_product`, CONSTRAINT `FK_civicrm_contribution_product_product_id` FOREIGN KEY (`product_id`) REFERENCES `civicrm_product` (`id`) ON DELETE CASCADE)]
```
I'm also getting a variation sometimes about receipt_date. Not sure the exact reproduction steps.
```
INSERT INTO `civicrm_contribution` (`contact_id` , `financial_type_id` , `contribution_page_id` , `payment_instrument_id` , `receive_date` , `total_amount` , `fee_amount` , `net_amount` , `trxn_id` , `invoice_id` , `currency` , `cancel_date` , `cancel_reason` , `receipt_date` , `thankyou_date` , `source` , `is_pay_later` , `contribution_status_id` , `check_number` , `campaign_id` , `creditnote_id` , `tax_amount` ) VALUES ( 193 , 1 , NULL , 4 , 20210903234000 , 12 , 0 , 12 , NULL , NULL , 'USD' , NULL , NULL , 19 , NULL , NULL , 0 , 1 , NULL , NULL , NULL , 0 ) [nativecode=1292 ** Incorrect datetime value: '19' for column `dmastercivi_g5lis`.`civicrm_contribution`.`receipt_date` at row 1]
```5.41.1https://lab.civicrm.org/dev/core/-/issues/2812CiviCRM 5.41.0 - WSOD crash with error PHP message: PHP Fatal error: Uncaught...2021-09-16T10:28:05Zjustinfreeman (Agileware)CiviCRM 5.41.0 - WSOD crash with error PHP message: PHP Fatal error: Uncaught Error: Class 'CRM_Contact_Form_Search_Custom_BaseWhen updating to CiviCRM 5.41.0. Site crashes (WSOD) with error, **PHP message: PHP Fatal error: Uncaught Error: Class 'CRM_Contact_Form_Search_Custom_Base**.
This is due to the **CRM_Contact_Form_Search_Custom_Base** class being moved ...When updating to CiviCRM 5.41.0. Site crashes (WSOD) with error, **PHP message: PHP Fatal error: Uncaught Error: Class 'CRM_Contact_Form_Search_Custom_Base**.
This is due to the **CRM_Contact_Form_Search_Custom_Base** class being moved to the **legacycustomsearches** (core distributed) extension which is not enabled.
A CiviCRM site which has any of the following extensions installed (this is not an exhaustive list) would be impacted:
- nz.co.fuzion.historicmembershipdata
- uk.co.vedaconsulting.gdpr
- org.civicoop.recurringcontributionsearch
- org.civicoop.dataprocessor
Any extension that extends CRM_Contact_Form_Search_Custom_Base would be impacted by this issue.
**Workaround**
The workaround for this issue would be:
1. Before the upgrade
1. Disable each of the extensions that extends CRM_Contact_Form_Search_Custom_Base
1. Perform the upgrade
1. Enable the legacycustomsearches extension
1. Re-enable each of the extensions that extends CRM_Contact_Form_Search_Custom_Base
Agileware Ref: CIVIBLD-2755.41.1https://lab.civicrm.org/dev/core/-/issues/2810CiviCRM A/B Mailing feature broken. CiviCRM now only sends Mailing A to all R...2021-09-18T01:29:49Zjustinfreeman (Agileware)CiviCRM A/B Mailing feature broken. CiviCRM now only sends Mailing A to all Recipients, not a percentage of the recipients. Mailing B and Final Mailing are not sent, they have zero recipients.CiviCRM A/B Mailing feature broken. CiviCRM now only sends Mailing A to all Recipients, not a percentage of the recipients. Mailing B and Final Mailing are not sent, they have zero recipients..
Regardless of whether the Final Mailing is...CiviCRM A/B Mailing feature broken. CiviCRM now only sends Mailing A to all Recipients, not a percentage of the recipients. Mailing B and Final Mailing are not sent, they have zero recipients..
Regardless of whether the Final Mailing is based on Mailing A or Mailing B, **no recipients are set** and the Final Mailing is not sent.
Using CiviCRM 5.40.4
Below is a series of screenshots of each step in the process.
Selecting the target group percentage.
![Screenshot_20210901_162830](/uploads/25ec6235f5b254f2ff7ce5182fd5a0e9/Screenshot_20210901_162830.png)
Mailing A and B scheduled.
![Screenshot_20210901_162944](/uploads/1a60aecd10487b95098cbb9614f7ff95/Screenshot_20210901_162944.png)
Mailing A and B sent.
![Screenshot_20210901_163011](/uploads/b8cac068f85033a31b147794c90d306c/Screenshot_20210901_163011.png)
Final mailing selected and sent.
![Screenshot_20210901_163602](/uploads/6bebe6684f90270063341ac1940aae8d/Screenshot_20210901_163602.png)
Related https://github.com/civicrm/civicrm-core/pull/20093 and dev/core#2100
Agileware Ref: CIVICRM-1828https://lab.civicrm.org/dev/core/-/issues/2807Contribution thank-you letters give Undefined index: contribution when you do...2021-08-31T21:40:26ZDaveDContribution thank-you letters give Undefined index: contribution when you don't have any contribution tokens in the message1. Search for contributions.
1. From actions choose thank-you letter.
1. Don't use any contribution tokens in the message.
```
0 ...\CRM\Contribute\BAO\Contribution.php(5121): "Undefined index: contribution"
1 ...\CRM\Contribute\Form\Ta...1. Search for contributions.
1. From actions choose thank-you letter.
1. Don't use any contribution tokens in the message.
```
0 ...\CRM\Contribute\BAO\Contribution.php(5121): "Undefined index: contribution"
1 ...\CRM\Contribute\Form\Task\PDFLetter.php(311): CRM_Contribute_BAO_Contribution::getContributionTokenValues("69", (Array:0))
2 ...\CRM\Contribute\Form\Task\PDFLetter.php(192): CRM_Contribute_Form_Task_PDFLetter->buildContributionArray(NULL, (Array:1), (Array:0), FALSE, FALSE, (Array:0), "CRM_Contribution_Form_Task_PDFLetterCommon", "****~~~~", FALSE)
3 ...\CRM\Core\Form.php(527): CRM_Contribute_Form_Task_PDFLetter->postProcess()
4 ...\CRM\Core\QuickForm\Action\Upload.php(152): CRM_Core_Form->mainProcess()
5 ...\CRM\Core\QuickForm\Action\Upload.php(119): CRM_Core_QuickForm_Action_Upload->realPerform(Object(CRM_Contribute_Form_Task_PDFLetter), "upload")
6 ...\packages\HTML\QuickForm\Controller.php(203): CRM_Core_QuickForm_Action_Upload->perform(Object(CRM_Contribute_Form_Task_PDFLetter), "upload")
7 ...\packages\HTML\QuickForm\Page.php(103): HTML_QuickForm_Controller->handle(Object(CRM_Contribute_Form_Task_PDFLetter), "upload")
8 ...\CRM\Core\Controller.php(352): HTML_QuickForm_Page->handle("upload")
9 ...\CRM\Core\Invoke.php(313): CRM_Core_Controller->run((Array:3), NULL)
10 ...\CRM\Core\Invoke.php(69): CRM_Core_Invoke::runItem((Array:14))
11 ...\CRM\Core\Invoke.php(36): CRM_Core_Invoke::_invoke((Array:3))
12 ...\drupal\civicrm.module(458): CRM_Core_Invoke::invoke((Array:3))
13 ...\includes\menu.inc(527): civicrm_invoke("contribute", "task")
14 ...\index.php(21): menu_execute_active_handler()
15 {main}
```5.41.0https://lab.civicrm.org/dev/core/-/issues/2806Contribution custom field tokens are duplicated in the dropdown2021-09-01T23:18:32ZDaveDContribution custom field tokens are duplicated in the dropdownAlso there are a bunch showing up that say "Machine name: xxx".
1. Make a custom field for contributions.
1. Do a search for contributions.
1. From the actions choose thank-you letters.
1. Look in the tokens dropdown. There's duplicates...Also there are a bunch showing up that say "Machine name: xxx".
1. Make a custom field for contributions.
1. Do a search for contributions.
1. From the actions choose thank-you letters.
1. Look in the tokens dropdown. There's duplicates for the custom field and some "Machine Name" entries.
The custom fields seems to be only in master but the machine name stuff is in 5.41.5.42.0https://lab.civicrm.org/dev/core/-/issues/2791Membership start date ignores trxn_date/receive_date gets recalculated to today2021-10-27T08:58:08ZRichMembership start date ignores trxn_date/receive_date gets recalculated to todayOverview
----------------------------------------
https://chat.civicrm.org/civicrm/pl/5bwnarinz7y73nwdjri9oidyno
Reproduction steps
----------------------------------------
Do an Order.create call which includes:
- `receive_date`...Overview
----------------------------------------
https://chat.civicrm.org/civicrm/pl/5bwnarinz7y73nwdjri9oidyno
Reproduction steps
----------------------------------------
Do an Order.create call which includes:
- `receive_date`: `2020-01-01`
- entity `params` in the line item contain `2020-01-01` for `start_date`.
This works, a pending membership is created with the start date of `2020-01-01` but then the subsequent Payment.create which includes the same historical `trxn_date` updates the membership's `start_date` to today.
Expected behaviour
----------------------------------------
Membership start date should take the date of the transaction. (I belive this was the case up to and including 5.39 but not in 5.40)
Environment information
----------------------------------------
buildkit d7 Civi 5.40
Comments
----------------------------------------
<del>This was picked up by the test assertion at
https://lab.civicrm.org/extensions/gocardless/-/blob/main/tests/phpunit/GoCardlessTest.php#L915
After the work is done in
https://lab.civicrm.org/extensions/gocardless/-/blob/main/tests/phpunit/GoCardlessTest.php#L1913
and specifically the Payment.create at
https://lab.civicrm.org/extensions/gocardless/-/blob/main/tests/phpunit/GoCardlessTest.php#L1998
</del>
These tests have been completely rewritten. See https://lab.civicrm.org/extensions/gocardless/-/issues/1235.42.1