CiviCRM Core issueshttps://lab.civicrm.org/dev/core/-/issues2024-02-08T19:14:09Zhttps://lab.civicrm.org/dev/core/-/issues/4950Acivity tab timing out after 5.70 upgrade on large DB2024-02-08T19:14:09ZElliott EgglestonAcivity tab timing out after 5.70 upgrade on large DBThe admin_ui version of the activity tab is generating queries for some CIDs that don't return in a reasonable amount of time. EXPLAIN shows that filesort is being used for the first subquery.
One example query, generated for a contact ...The admin_ui version of the activity tab is generating queries for some CIDs that don't return in a reasonable amount of time. EXPLAIN shows that filesort is being used for the first subquery.
One example query, generated for a contact with only 18 activities: https://phabricator.wikimedia.org/P55961
Wikimedia's tracking task, with the SQL query explain: https://phabricator.wikimedia.org/T356269
Oddly, I WAS able to load the activities tab for my own user which has 700+ activities, so it's not just related to the number of activities on a contact.
If I just roll back 04078d359e298a5a02ea274404dcdb8af83225dd it restores the previous activity tab and I can load the CID's activity tab fine with no runaway query generated.5.70.0colemanwcolemanwhttps://lab.civicrm.org/dev/core/-/issues/4798Online contribution flow - fix for php8.x, notices, smarty32024-02-06T05:45:17ZeileenOnline contribution flow - fix for php8.x, notices, smarty3This is an oversight issue for fixing up the online contribution form in php8.x with a view to
1) resolving all the smarty & php layer notices, including in the message templateb
2) fixing the places where it doesn't work with Smarty3 (...This is an oversight issue for fixing up the online contribution form in php8.x with a view to
1) resolving all the smarty & php layer notices, including in the message templateb
2) fixing the places where it doesn't work with Smarty3 (in the online membership receipt & I think I fixed one in Confirm.tpl maybe)
3) fixing it to work with php8.2 (no undeclared properties)
4) fixing the underlying line item handling mess (we have multiple different ways of setting & retrieving the line itesm + a whole lot of code that does stuff to the line items but ultimately alters variables that get discarded. The impact of that I found tax bugs as soon as I started looking at the code.
5) fixing the online membership receipt such that it is previewable in MessageAdmin Ui, and does not require complex code to call it & have it render correctly (ie. `composeMessageArray` & the form layer both do a lot of assigning that should be unnecessary)
Much of this work has been done in small steps with a few in 5.68 & the bulk in 5.69. The goal is to try to resolve all the most important parts in 5.69 & then not do any more & encourage lots of rc testing on 5.69.
Areas to think about when testing
- data input with different currency separators
- non deductible amount with tax
- checking tax in separate payment & non separate payment scenarios (this actually has modest test cover but should be extended)
- checking the receipts
- checking the contribution recur amount is correct - when there is an autorenew membership + a contribution & it is not separate payment the amount should be equal to the tax-inclusive amount for the membership part of the contribution
Issues
**Must fix regressions**
- [x] Form layer issue on other amount js - probably regression in rc or master https://lab.civicrm.org/dev/core/-/issues/4795
- [x] Disabled options showing up https://github.com/civicrm/civicrm-core/pull/28356
- [x] Membership type not selected as a default https://github.com/civicrm/civicrm-core/pull/28361
- [ ] Is something weird happening with pledge? I couldn't figure out how to enable & disable & see it there & not there - UPDATE - I think this is a demo site data issue - https://github.com/civicrm/civicrm-core/pull/28497
- [x] Is the other Amount js right when there is NOT a membership? Need to compare to an older version... This might also be a demo site data issue per ^^
**Regression?Improvement?**
- [x] Change in line items for membership + contribution https://lab.civicrm.org/dev/core/-/issues/4814
**Extension issues**
- [x] A couple of extensions are interacting with the no-longer-in-use `_lineItem` undeclared property. This undeclared property also causes php8 fails. Declaring it would give a false sense of security but an alternative is to add a magic `__GET` & `__SET`. In my digging so far taxcalculator would need some small changes to adapt to this as the undeclared property is passed-by-reference but other extensions are likely to be OK with it. PR to add magic methods https://github.com/civicrm/civicrm-core/pull/28276 PR on taxcalculator https://lab.civicrm.org/extensions/taxcalculator/-/merge_requests/9
**Pre-existing issues**
These are not necessarily going to be fixed but the process of verifying them provides a goodly amount of rc testing. In some cases they are suspected fully or partially fixed already
*Tax*
- [ ] Long term issue on tax not applying to separate membership payments, in my testing pre-cleanup the tax-not-applied seemed to go beyond separate payments. This needs re-testing & a list of issues confirmed https://lab.civicrm.org/dev/financial/-/issues/154
- [ ] Aha - here is the general tax issue I hit https://lab.civicrm.org/dev/core/-/issues/4524 - needs verification
- [x] How should tax apply to 'Other amount' - is the amount entered inclusive? https://lab.civicrm.org/dev/core/-/issues/4806
- [ ] possible bug - needs verification https://lab.civicrm.org/dev/financial/-/issues/182
- [ ] Now that we have standardised on publicly supported `getLineItems()` & `setLineItems()` how is our hook support https://lab.civicrm.org/dev/core/-/issues/2796
*Localisation*
- [x] Non-English currency formatting messes with other amount field https://lab.civicrm.org/dev/core/-/issues/4802
*Page flow*
- [ ] Membership amount + contribution issues (erm what did I mean when I wrote this?)
- [ ] Data issue when email fails https://lab.civicrm.org/dev/core/-/issues/4540
- [ ] Data issue on payment fail https://github.com/civicrm/civicrm-core/pull/26120
- [ ] ContributionRecurID not always passed to payment processor https://lab.civicrm.org/dev/core/-/issues/4019
- [ ] The stretch goal - create order before adding payment https://lab.civicrm.org/dev/financial/-/issues/76
- [ ] Also the stretch goal https://lab.civicrm.org/dev/financial/-/issues/53
- [ ] Another meta issue of unknown status https://lab.civicrm.org/dev/core/-/issues/928
*Validation*
- [ ] Contribution + membership + quick config https://lab.civicrm.org/dev/core/-/issues/3314
*On Behalf*
- [ ] Profile bug?? https://lab.civicrm.org/dev/financial/-/issues/124
- [ ] Onbehalf hide for orgs https://lab.civicrm.org/dev/core/-/issues/4725
*Presentation issues*
- [ ] Notices on form - undefined property https://lab.civicrm.org/dev/core/-/issues/4760
- [x] Currency incorrect on thank you / confirm pages https://lab.civicrm.org/dev/core/-/issues/3381
- [ ] Probably the same https://lab.civicrm.org/dev/core/-/issues/3917
- [ ] Probably the same https://lab.civicrm.org/dev/core/-/issues/411
- [ ] Problems at form layer with auto-renew handling https://lab.civicrm.org/dev/core/-/issues/3963
- [ ] Frequency units translation issues https://lab.civicrm.org/dev/translation/-/issues/53
- [ ] On behalf confusing https://lab.civicrm.org/dev/core/-/issues/2266
- [ ] PCP notices https://lab.civicrm.org/dev/drupal/-/issues/159
- [ ] Translation missin ghttps://lab.civicrm.org/dev/translation/-/issues/27
- [ ] Show hide billing doesn't work https://lab.civicrm.org/dev/financial/-/issues/129
- [ ] Email appears twice https://lab.civicrm.org/dev/core/-/issues/3858
- [ ] Translation issue https://lab.civicrm.org/dev/core/-/issues/4071
- [ ] Possible bug https://lab.civicrm.org/dev/core/-/issues/4293
- [ ] Bug? replicable https://lab.civicrm.org/dev/core/-/issues/4488
- [ ] Upload image does not show https://lab.civicrm.org/dev/core/-/issues/4817
- [x] Undefined array key "honoreeProfileFields" also "title" in ThankYou.tpl.php that appeared when payment incorrectly recorded as $0 https://lab.civicrm.org/dev/core/-/issues/4863
- [x] Edit contribution has about a dozen undefined array keys for defaultContribution, displayLineItemFinancialType, getTaxDetails, pricesetFieldsCount, hookDiscount https://lab.civicrm.org/dev/core/-/issues/4864
*Membership calculation*
- [ ] Membership term usage issue https://lab.civicrm.org/dev/core/-/issues/3344
- [ ] Probably the same thing https://lab.civicrm.org/dev/core/-/issues/3810
- [ ] Probably the same thing https://lab.civicrm.org/dev/core/-/issues/3339
- [ ] Autorenew deep dive https://lab.civicrm.org/dev/financial/-/issues/128
- [ ] My read of the code suggests that if 2 membership types are configured to offer auto-renew it will only work for one
*Premiums*
- [x] notices on manage premiums https://lab.civicrm.org/dev/core/-/issues/4793
- [x] need api support for premiums https://github.com/civicrm/civicrm-core/pull/28261
- [x] Smarty notices on premiums in Online form flow https://lab.civicrm.org/dev/core/-/issues/4794
- [ ] pre-existing brokenness on deductible amount https://lab.civicrm.org/dev/core/-/issues/1083
- [ ] More non-deductible amount issues https://lab.civicrm.org/dev/core/-/issues/2414
- [ ] non-deductible amount misconfiguration https://lab.civicrm.org/dev/core/-/issues/3083 (note we could add a system check as a low-risk step)
*Manage contribution pages*
- [x] issue saving renew options https://github.com/civicrm/civicrm-core/pull/24997
- [ ] Validation lacking https://lab.civicrm.org/dev/core/-/issues/2846
- [ ] Widget issue https://lab.civicrm.org/dev/core/-/issues/20
*Membership receipts*
- [x ] Remove text version of receipt - we are moving to relying on generated text version rather than maintaining both
- [ ] Membership data wrong https://lab.civicrm.org/dev/core/-/issues/2354
- [ ] Credit card info sometimes missing https://lab.civicrm.org/dev/core/-/issues/661
- [ ] Receipt text inconsistently handled https://lab.civicrm.org/dev/user-interface/-/issues/13
- [ ] Issue on upsell https://lab.civicrm.org/dev/core/-/issues/4332
- [ ] Proposal - remove trxn_id https://lab.civicrm.org/dev/financial/-/issues/217
- [ ] Missing recur links https://lab.civicrm.org/dev/financial/-/issues/127
*Contribution receipts*
- [ ] Somewhat obscure bug on on-behalf profiles (should be addressed if we get as far as moving the handling of that to the WorkflowMessage class) https://lab.civicrm.org/dev/core/-/issues/4779
- [x] Remove text version of receipt - we are moving to relying on generated text version rather than maintaining both
- [ ] Duplicate of donor name https://lab.civicrm.org/dev/core/-/issues/2021
- [ ] Not sent for paypal express https://lab.civicrm.org/dev/financial/-/issues/13
- [ ] PDF file name issue https://lab.civicrm.org/dev/core/-/issues/3068
- [ ] Broken links in contribution issue https://lab.civicrm.org/dev/core/-/issues/1195
- [ ] Likely fixed bug https://lab.civicrm.org/dev/core/-/issues/4185
- [ ] Checksum wiht on-behalf of https://lab.civicrm.org/dev/core/-/issues/4265
*Wordpress issue?*
- [ ] https://lab.civicrm.org/dev/wordpress/-/issues/120
Feature request
- [ ] Configurable confirm button - more than one request - like events - https://lab.civicrm.org/dev/user-interface/-/issues/10 https://lab.civicrm.org/dev/core/-/issues/4324https://lab.civicrm.org/dev/core/-/issues/4745Joomla: Fails to download extension feed2023-11-09T23:56:48ZtottenJoomla: Fails to download extension feedOverview
----------------------------------------
There appears to be a Guzzle conflict when fetching the extension feed on Joomla.
Reproduction steps
----------------------------------------
1. Install CiviCRM on Joomla
1. Navigate to...Overview
----------------------------------------
There appears to be a Guzzle conflict when fetching the extension feed on Joomla.
Reproduction steps
----------------------------------------
1. Install CiviCRM on Joomla
1. Navigate to dashboard
Current behaviour
----------------------------------------
The first pageload fails with:
![Screen_Shot_2023-11-01_at_4.20.15_PM](/uploads/bfab953fd770a8c09af0658b11529f04/Screen_Shot_2023-11-01_at_4.20.15_PM.png)
The NACK is cached for a while, so you won't immediately see the problem again. But we should expect it to recur.
Expected behaviour
----------------------------------------
No crash.
Environment information
----------------------------------------
The "hydra sites" (https://test.civicrm.org/view/Sites/job/hydra-sites/) are clean CMS installations. (They have the Civi source code preloaded -- but the installer hasn't run.) The error was observed on the hydra site for Joomla with CiviCRM `5.67.beta2` circa Nov 1, 2023.
* __Browser:__ Firefox
* __CiviCRM:__ 5.67.beta2
* __PHP:__ 7.4
* __CMS:__ Joomla
* __Database:__ 5.7
* __Web Server:__ Apachehttps://lab.civicrm.org/dev/core/-/issues/4452Message Admin doesn't show which message templates have been edited2023-09-18T12:15:28ZlarsssandergreenMessage Admin doesn't show which message templates have been edited~~It looks like Message Admin is now enabled by default, but~~ I've noticed that there is no indication in Message Admin of which templates have been edited or not. This is pretty important info for admins and should be available in the ...~~It looks like Message Admin is now enabled by default, but~~ I've noticed that there is no indication in Message Admin of which templates have been edited or not. This is pretty important info for admins and should be available in the UI.
Compare the old - very clear which has been edited:
![image](/uploads/43963f9cbbf0e08c5f1679056e4a2c35/image.png)
to the new - no indication which has been edited:
![image](/uploads/4a394422a26c4a1536306e96d3c77a7c/image.png)
I can't see anything on the edit page to indicate this either.
Edit: There is also no longer any way to revert a message to the default, other than by manually copying and pasting the template content. I think having the "Revert to default" link is useful, if you made a small change and have decided you no longer need it because there has been an upgrade.
~~Also, I guess the drafting process isn't implemented yet (or not accessible from the UI), so maybe it would make sense to hide the Draft column until that's ready.~~https://lab.civicrm.org/dev/core/-/issues/4287PHP 8 - Undefined variable warnings from Smarty appear in email notifications2023-11-14T01:40:49ZjasonhildebrandPHP 8 - Undefined variable warnings from Smarty appear in email notificationsOverview
----------------------------------------
We recently upgraded Civi to 5.60 and PHP 8 (was previously PHP 7.x). Our site uses Drupal 7.
Since the upgrade, we are seeing errors such as ```Undefined array key "phone_type"``` appe...Overview
----------------------------------------
We recently upgraded Civi to 5.60 and PHP 8 (was previously PHP 7.x). Our site uses Drupal 7.
Since the upgrade, we are seeing errors such as ```Undefined array key "phone_type"``` appearing in our email notifications to event participants.
![screenshot](/uploads/4cee73442124f9c2a3b1158e8925c1e7/screenshot.png)
We have taken action to suppress errors and warnings in Drupal, but this does not appear to help when smarty is used to render email notifications.
Expected behaviour
----------------------------------------
I would expect these warnings not to appear, or to be suppressible with setting, so that they can be turned off in production.
Workaround
-----------
As a workaround, I added the 3 lines marked below to civicrm/CRM/Core/TokenSmarty.php in order to suppress the warnings before rendering, then restore the error_reporting to the original setting after rendering.
Perhaps this kind of approach could be added to Civi with a configuration setting to turn these messages on/off.
```
// Evaluate/render templates
try {
if ($useSmarty) {
$orig_reporting = error_reporting(); // ADDED
error_reporting(0); // ADDED
CRM_Core_Smarty::singleton()->pushScope($smartyAssigns);
}
$tokenProcessor->evaluate();
foreach ($messages as $messageId => $ign) {
foreach ($tokenProcessor->getRows() as $row) {
$result[$messageId] = $row->render($messageId);
}
}
}
finally {
if ($useSmarty) {
CRM_Core_Smarty::singleton()->popScope();
error_reporting($orig_reporting); // ADDED
}
}
```https://lab.civicrm.org/dev/core/-/issues/4191Export with a field that has a small DB size but long labels results in fatal2023-06-15T21:16:14ZbgmExport with a field that has a small DB size but long labels results in fatalTo reproduce:
- Create a new custom field of type=alphanum, widget=select list, size=2 (on dmaster, you can edit "Constituent Information > Marital Status" to have a width of 2)
- Enter some field options that are more than 2 characters...To reproduce:
- Create a new custom field of type=alphanum, widget=select list, size=2 (on dmaster, you can edit "Constituent Information > Marital Status" to have a width of 2)
- Enter some field options that are more than 2 characters
Then go to Advanced Search:
- click submit to search,
- export all results
- select fields to export: marital status (or the field you created)
It will cause CiviCRM to fatal because it creates a temp table with a `varchar(4)` but it tries to store the field labels.
It works on CiviCRM 5.55 but not on CiviCRM 5.60 RC.https://lab.civicrm.org/dev/core/-/issues/3824Possible for historic scheduled reminder to be sent multiple times if cron jo...2022-11-28T08:14:03ZAdam WoodPossible for historic scheduled reminder to be sent multiple times if cron job does not complete properlyWhen the `Send Scheduled Reminders` job runs, the process fails with errors like the following (reported by our Cron Daemon):
```
PHP Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 245760 bytes) in /ho...When the `Send Scheduled Reminders` job runs, the process fails with errors like the following (reported by our Cron Daemon):
```
PHP Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 245760 bytes) in /home/cses_org_uk/public_html/administrator/components/com_civicrm/civicrm/CRM/Utils/Cache/SqlGroup.php on line 184
```
If attempting to invoke the job manually from the scheduled jobs admin page, we get an HTTP 500 error and the following entries in the error_log:
```
[Thu Aug 25 19:51:26.801469 2022] [fcgid:warn] [pid 27274] [client 79.69.229.183:51994] mod_fcgid: read data timeout in 301 seconds, referer: https://cses.org.uk/administrator/?option=com_civicrm&task=civicrm/admin/job&action=view&reset=1&context=joblog&id=9
[Thu Aug 25 19:51:26.819905 2022] [core:error] [pid 27274] [client 79.69.229.183:51994] End of script output before headers: index.php, referer: https://cses.org.uk/administrator/?option=com_civicrm&task=civicrm/admin/job&action=view&reset=1&context=joblog&id=9
```
We can see that the job is starting but never finishing from the log:
![image](/uploads/f30bd5bc2f0df34579eb3fa9247545b9/image.png)
_**The scheduled reminders do seem to be sending successfully, however. Other cron jobs also seem to complete successfully.**_
This issue seemed to start recently with an unplanned, emergency server migration. It's a virtual server so notionally everything is the same, but there may be some other factor at play here (CiviCRM upgrade, change to one of the reminder templates etc). I have double-checked PHP resource limits (256M memory, 300 second timeout i.e. more than enough) and MySQL settings and can't find anything amiss.
The error occurs at the following line in `SQLGroup.php`:
```php
private function reobjectify($value) {
return is_object($value) ? unserialize(serialize($value)) : $value; // This line fails
}
```
It seems as though `serialize()` is failing: whatever value is at fault, it was previously `unserialize()`d successfully to read it out of the cache in the first place. What does this function actually do - why the round trip??
I attempted to debug with some judicious `error_log()` immediately before and after this line to see which cache value was causing the memory leak, but to no avail. No error_log was written before the crash (although many previous successful calls to the function were logged).
This is on CiviCRM 5.50.4. I will attempt an upgrade soon to see if this fixes it, and will continue to investigate / try to narrow down / work out how to reproduce.https://lab.civicrm.org/dev/core/-/issues/3441When generating emails from Search results, activity is recorded as a Print P...2023-03-06T20:39:37ZStoobWhen generating emails from Search results, activity is recorded as a Print PDF DocumentSteps to reproduce:
1. use Search Kit to generate results as _Contributions_
2. choose to send emails receipts
3. emails are sent, but activity is recorded "Print/Merge Document" rather than Type "Email".
#searchkitSteps to reproduce:
1. use Search Kit to generate results as _Contributions_
2. choose to send emails receipts
3. emails are sent, but activity is recorded "Print/Merge Document" rather than Type "Email".
#searchkithttps://lab.civicrm.org/dev/core/-/issues/3440Check for matching contact on contact add form sends hardcoded fields to dupl...2023-07-06T07:25:40ZdarrickCheck for matching contact on contact add form sends hardcoded fields to duplicatecheck api callOverview
----------------------------------------
If a custom Supervised rule is created using any field not in ['first_name', 'last_name', 'nick_name', 'household_name', 'organization_name', 'email'] then clicking on the **Check for Mat...Overview
----------------------------------------
If a custom Supervised rule is created using any field not in ['first_name', 'last_name', 'nick_name', 'household_name', 'organization_name', 'email'] then clicking on the **Check for Matching Contact** button will return no results.
Reproduction steps
----------------------------------------
1. Click on **Contacts -> Find and Merge Duplicate Contacts**.
2. Click on **Add Individual Rule**
3. Add a rule with field phone, weight 10, threshold 10
4. Click on **Change rule** and set to **Supervised**
5. Click on **Contacts -> New Individual**
6. Add a contact with First Name: Bob, Last Name: Dobbs and phone 666.666.6666
7. Save the contact.
8. Click on **Contacts -> New Individual**
9. Add a contact with First Name: Bob, Last Name: Dobbs and phone 666.666.6666
10. Click on **Check for Matching Contact**
Current behaviour
----------------------------------------
A popup displays "Similar contact if found" after entering the First Name and after entering the Last Name in step 9.
After entering the duplicate phone number nothing happens.
After clicking on **Check for Matching Contact** nothing happens.
Expected behavior
----------------------------------------
After entering either First Name or Last Name nothing should happen unless the entered field is included in the Supervised rule.
A popup displaying "Similar contact if found" should happen after the phone number is entered and also after clicking on **Check for Matching Contact**
Comments
----------------------------------------
I ran across this while looking to see if I could fix any other outstanding bugs related dedupe. Was working on this one: (https://lab.civicrm.org/dev/core/-/issues/2966) I wasn't able to reproduce their issue.
It may still be useful to hard code those fields so by default the form always matches on name or email when entering those fields but then the additional fields will also be searched when added using the custom rule. As any fields not needed for the custom rule will just be ignored.https://lab.civicrm.org/dev/core/-/issues/5082CiviCRM 5.70.0, 5.71.0 - With URL tracking enabled, a personalised "View in y...2024-03-28T23:33:13Zjustinfreeman (Agileware)CiviCRM 5.70.0, 5.71.0 - With URL tracking enabled, a personalised "View in your browser" link incorrectly replaces ? with & which causes CiviCRM to respond with error: "You do not have permission to access this page"CiviCRM 5.70.0, 5.71.0 - With URL tracking enabled, a personalised "View in your browser" link incorrectly replaces ? with & which causes CiviCRM to respond with error: "You do not have permission to access this page".
This happens when...CiviCRM 5.70.0, 5.71.0 - With URL tracking enabled, a personalised "View in your browser" link incorrectly replaces ? with & which causes CiviCRM to respond with error: "You do not have permission to access this page".
This happens when using a personalised "View in your browser" URL like this in the mailing, note the use of tokens:
https://goodcause.org.au/civicrm/mailing/view?id={mailing.key}&{contact.checksum}&cid={contact.contact_id}
Which is then incorrectly converted to - this only happens with URL tracking enabled. When URL tracking is disabled, no problems at all.
https://goodcause.org.au/civicrm/mailing/view&id=38&cs=838eae033aa8c2edb56f25b54a1edde5_1709775006_2880&cid=389
And then CiviCRM to respond with error: "You do not have permission to access this page"
The fix and workaround for this issue is to instead just use this token as the URL, which will render correctly.
{mailing.viewUrl}
It's not unreasonable to expect the personalised "View in your browser" URL will work, the first URL parameter should not be converted in this way. This may have implications for other types of URLs too.
Agileware Ref: CIVICRM-2230https://lab.civicrm.org/dev/core/-/issues/4985Custom radio/checkbox fields - maximum options per line - alignment lost2024-03-28T22:04:20ZsamuelsovCustom radio/checkbox fields - maximum options per line - alignment lostRegression following on #1821.
This is what we used to have (html table so everything is aligned):
![screen1](/uploads/afc5f71950f200da120187746e43f222/screen1.png)
This is what we have now:
![screen2](/uploads/c202f5aa0fccf732d96090...Regression following on #1821.
This is what we used to have (html table so everything is aligned):
![screen1](/uploads/afc5f71950f200da120187746e43f222/screen1.png)
This is what we have now:
![screen2](/uploads/c202f5aa0fccf732d96090fd2d385138/screen2.png)
Currently, it's almost impossible to fix it using css.https://lab.civicrm.org/dev/core/-/issues/5116Scheduled Reminders: with multi-lingual, the language filters are empty2024-03-28T21:51:08ZbgmScheduled Reminders: with multi-lingual, the language filters are emptyTo reproduce:
- Enable multi-lingual from Administer > Localization > Languages, the checkbox at the bottom of the screen
- Then go to Administer > Communications > Scheduled Reminders
- Add a new Reminder
Ignore everything, scroll dow...To reproduce:
- Enable multi-lingual from Administer > Localization > Languages, the checkbox at the bottom of the screen
- Then go to Administer > Communications > Scheduled Reminders
- Add a new Reminder
Ignore everything, scroll down to the "Recipients language", and notice that the list is empty:
![image](/uploads/1f83b3ccfd0c755f0609509c4172594a/image.png)
The regression was caused by: https://github.com/civicrm/civicrm-core/commit/de00a2b14f60a7f6fef59b5b3331c17fc1e3e061 - part of CiviCRM 5.66 (Symbiotic was on 5.65 and didn't see this until 5.70).
I don't know what's the best way of fixing it:
- The DAO correctly defines the callback for the `filter_contact_language` field
- QuickForm uses `addField()` to add the field using metadata
- `addField()` calls `ActionSchedule.getfields`, which fetches the metadata from the DAO
- `civicrm_api3_generic_getfields()` has code like this:
```
if (function_exists($helper)) {
// alter
$helper($metadata, $apiRequest);
}
```
which basically calls `_civicrm_api3_action_schedule_create_spec()`, and that then NULLs the callbacks, so the options are hidden in the UI.
@colemanw Any thoughts?
Bug found by @mmyriamcolemanwcolemanwhttps://lab.civicrm.org/dev/core/-/issues/5115a11y errors2024-03-28T20:43:12ZJoeMurraya11y errorsRunning a very vanilla setup we get the following accessibility errors (D10.2.3 / Civi 5.70.2 site, Finsbury Park theme enabled and Backend theme set to Finsbury Park and Aah disabled/alternating with Finsbury Park theme disabled and Aah...Running a very vanilla setup we get the following accessibility errors (D10.2.3 / Civi 5.70.2 site, Finsbury Park theme enabled and Backend theme set to Finsbury Park and Aah disabled/alternating with Finsbury Park theme disabled and Aah enabled and Backend theme set to Aah, Frontend Theme to Automatic. Using WAVE Web Accessibility Evaluation Tool 3.2.5.3 in Chrome browser 123.0.6312.86 on macOS Sonoma 14.4.1).
CiviCRM Home Page Errors:
- [ ] Missing form label on the QuickSearch element (Finsbury Park, Aah)
`<input type="text" id="crm-qsearch-input" name="sort_name" placeholder=" Name/Email" accesskey="q" class="ui-autocomplete-input" autocomplete="off">`
- [ ] Missing form label on Find menu item... (Finsbury Park, Aah)
`<input type="text" id="crm-menubar-drilldown" placeholder="Find menu item...">`
- [ ] Empty link (Finsbury Park, Aah)
```
<a href="#" class="has-submenu" id="sm-17116551805997053-1" aria-haspopup="true" aria-controls="sm-17116551805997053-2" aria-expanded="false">
<form action="/civicrm/contact/search/advanced" name="search_block" method="post">
<div>
AccesskeyMissing form label
<input type="text" id="crm-qsearch-input" name="sort_name" placeholder=" Name/Email" accesskey="q" class="ui-autocomplete-input" autocomplete="off">
<input type="hidden" name="hidden_location" value="1">
<input type="hidden" name="hidden_custom" value="1">
<input type="hidden" name="qfKey" value="CRMContactControllerSearch1nrj4735k2cgk8kgcos44c4800cwc800o8gk00w8so0gko004s_8998">
<input type="hidden" name="_qf_Advanced_refresh" value="Search">
</div>
</form>
<span class="sub-arrow"></span>
</a>
```
- [ ] Empty link (Finsbury Park, Aah)
```
<a accesskey="m" href="#" class="has-submenu" id="sm-17116551805997053-3" aria-haspopup="true" aria-controls="sm-17116551805997053-4" aria-expanded="false">
<i class="crm-logo-sm"></i>
<span class="sub-arrow"></span>
</a>
```
- [ ] Empty link (Finsbury Park, Aah)
```
<a href="#" class="has-submenu" id="sm-17116551805997053-5" aria-haspopup="true" aria-controls="sm-17116551805997053-6" aria-expanded="false">
Missing form label
<input type="text" id="crm-menubar-drilldown" placeholder="Find menu item...">
<span class="sub-arrow"></span>
</a>
```
- [ ] Very low contrast (Aah)
```
<button class="trigger visually-hidden focusable" type="button" aria-pressed="false">
Open configuration options
</button>
```
- [ ] Very low contrast (Finsbury Park, Aah)
```
<label class="crm-menubar-toggle-btn" for="crm-menubar-state">
<span class="crm-menu-logo"></span>
<span class="crm-menubar-toggle-btn-icon"></span>
Toggle main menu
</label>
```
- [ ] Very low contrast (Finsbury Park, Aah)
```
<div id="drupal-live-announce" class="visually-hidden" aria-live="polite" aria-busy="false">
Tray opened.
</div>
```
Simple Search (Search > Find Contacts) Errors not present above:
- [ ] Missing form label
```
<select placeholder="- any group -" multiple="multiple" class="big big crm-select2 crm-form-multiselect" name="group[]" id="group" tabindex="-1" style="display: none;">
<option value="1">
My site group 1
</option>
<option value="2">
My site group 2
</option>
</select>
```
- [ ] Empty form label (see next task for Empty link that contains this)
`<label for="s2id_autogen2" class="select2-offscreen"></label>`
- [ ] Empty link
```
<a href="#" class="has-submenu" id="sm-17116579339791917-1" aria-haspopup="true" aria-controls="sm-17116579339791917-2" aria-expanded="false">
<form action="/civicrm/contact/search/advanced" name="search_block" method="post">
<div>
<input type="text" id="crm-qsearch-input" name="sort_name" placeholder=" Name/Email" accesskey="q" class="ui-autocomplete-input" autocomplete="off">
<input type="hidden" name="hidden_location" value="1">
<input type="hidden" name="hidden_custom" value="1">
<input type="hidden" name="qfKey" value="CRMContactControllerSearch1nrj4735k2cgk8kgcos44c4800cwc800o8gk00w8so0gko004s_4570">
<input type="hidden" name="_qf_Advanced_refresh" value="Search">
</div>
</form>
<span class="sub-arrow"></span>
</a>
```
- [ ] Empty link
```
<a accesskey="m" href="#" class="has-submenu" id="sm-17116579339791917-3" aria-haspopup="true" aria-controls="sm-17116579339791917-4" aria-expanded="false">
<i class="crm-logo-sm"></i>
<span class="sub-arrow"></span>
</a>
```
- [ ] Empty link
```
<a href="#" class="has-submenu" id="sm-17116579339791917-5" aria-haspopup="true" aria-controls="sm-17116579339791917-6" aria-expanded="false">
<input type="text" id="crm-menubar-drilldown" placeholder="Find menu item...">
<span class="sub-arrow"></span>
</a>
```
- [ ] Very low contrast
```
<span class="select2-chosen" id="select2-chosen-1">
- any contact type -
</span>
```
- [ ] Very low contrast
```
<button class="crm-form-submit default validate crm-button crm-button-type-refresh crm-button_qf_Basic_refresh" value="1" type="submit" name="_qf_Basic_refresh" id="_qf_Basic_refresh-bottom">
<i aria-hidden="true" class="crm-i fa-check"></i>
Search
</button>
```Monish DebMonish Deb2024-03-29https://lab.civicrm.org/dev/core/-/issues/5114Managed domain-aware entities with multisite configuration2024-03-28T12:37:16ZJKingsnorthManaged domain-aware entities with multisite configurationWe've come across an edge-case in a multi-site setup.
In our setup, we have a master domain which does not have 'Enable Multi Site Configuration' enabled. And subdomains which do.
This is allowed configuration according to the docs: ht...We've come across an edge-case in a multi-site setup.
In our setup, we have a master domain which does not have 'Enable Multi Site Configuration' enabled. And subdomains which do.
This is allowed configuration according to the docs: https://docs.civicrm.org/installation/en/latest/multisite/drupal/#:~:text=It%20is%20not,or%20website%20administrators.
We also have a managed 'job' entity (provided by https://lab.civicrm.org/extensions/mjwshared/-/blob/master/managed/ProcessPaymentprocessorWebhooks.mgd.php?ref_type=heads)
The managed entity is set to 'always' update.
---
1) We run Managed->Reconcile on domain ID 1 (multisite not enabled)
- The job row is created
- An entry in civicrm_managed is created
```
# id, module, name, entity_type, entity_id, cleanup, entity_modified_date
'1796', 'mjwshared', 'ProcessPaymentProcessorWebhooks', 'Job', '116', 'always', NULL
```
- The job in civicrm_job is created
```
# id, domain_id, run_frequency, last_run, scheduled_run_date, name, description, api_entity, api_action, parameters, is_active
'116', '1', 'Always', NULL, NULL, 'Process PaymentProcessor Webhooks', 'Process incomplete payment processor webhooks', 'Job', 'process_paymentprocessor_webhooks', 'delete_old=-3 month', '1'
```
2) Managed->Reconcile run on domain ID 43 (multisite enabled)
- The entries in civicrm_managed are converted into 'domain-aware' entries:
```
# id, module, name, entity_type, entity_id, cleanup, entity_modified_date
'1803', 'mjwshared', 'ProcessPaymentProcessorWebhooks_32', 'Job', '116', 'always', NULL
'1804', 'mjwshared', 'ProcessPaymentProcessorWebhooks_42', 'Job', '116', 'always', NULL
'1805', 'mjwshared', 'ProcessPaymentProcessorWebhooks_43', 'Job', '116', 'always', NULL
```
- The job in civicrm_job is 'moved' to another domain:
```
# id, domain_id, run_frequency, last_run, scheduled_run_date, name, description, api_entity, api_action, parameters, is_active
'116', '43', 'Always', NULL, NULL, 'Process PaymentProcessor Webhooks', 'Process incomplete payment processor webhooks', 'Job', 'process_paymentprocessor_webhooks', 'delete_old=-3 month', '1'
```
3) Managed->Reconcile run on domain ID 1 again (not multisite enabled)
- The entry in civicrm_job has been deleted - no more essential scheduled job!
- The entry in civicrm_managed changes back to not domain aware, and references a deleted row
```
# id, module, name, entity_type, entity_id, cleanup, entity_modified_date
'1796', 'mjwshared', 'ProcessPaymentProcessorWebhooks', 'Job', '116', 'always', NULL
```
---
So we need to either:
- Update the docs to say that the 'master' domain _does_ need to be multisite aware
- Update the handling of domain-aware managed entities to work correctly when reconciled in either domainhttps://lab.civicrm.org/dev/core/-/issues/5113Change Start Date link broken on open case activity edit2024-03-28T00:59:58ZDaveDChange Start Date link broken on open case activity editThere's a warning Undefined array key "changeStartURL" and clicking the link just reloads the page.There's a warning Undefined array key "changeStartURL" and clicking the link just reloads the page.https://lab.civicrm.org/dev/core/-/issues/5111PHP8.1 Deprecated function: fseek():2024-03-26T21:44:23ZbobisHDPHP8.1 Deprecated function: fseek():Overview
----------------------------------------
On php8.1 the below error will appear:
```Deprecated function: fseek(): Passing null to parameter #2 ($offset) of type int is deprecated in FileReader->seekto() (line 125 of /opt/bitnam...Overview
----------------------------------------
On php8.1 the below error will appear:
```Deprecated function: fseek(): Passing null to parameter #2 ($offset) of type int is deprecated in FileReader->seekto() (line 125 of /opt/bitnami/apps/civicrm/htdocs/sites/all/modules/civicrm/packages/PHPgettext/streams.php)```
The code in this file that causes the error is:
```php
function seekto($pos) {
fseek($this->_fd, $pos);
$this->_pos = ftell($this->_fd);
return $this->_pos;
}
```
After changing this to
```php
function seekto($pos) {
fseek($this->_fd, $this->_pos);
$this->_pos = ftell($this->_fd);
return $this->_pos;
}
```
It seems to make the error go away.
If you have already posted on:
- https://civicrm.stackexchange.com
- https://chat.civicrm.org/civicrm/pl/yfx7e3un4f8nifxq1iknj5amjw
Environment information
----------------------------------------
* __Browser:__ Firefox
* __CiviCRM:__ 5.71.0
* __PHP:__ 8.1
* __CMS:__ Drupal 7.100
* __Database:__ MariaDB 10.6.16
* __Web Server:__ Apache/2.4.52https://lab.civicrm.org/dev/core/-/issues/5110afform: Display option "Remember Filters" not keeping value2024-03-25T15:01:10Zjensschuppeafform: Display option "Remember Filters" not keeping value## Overview
The display option "Remember Filters" in search displays does not retain its value when the configuration form is being reloaded.
## Reproduction steps
1. Create a _SearchKit_ search with a search form
2. Add a form displa...## Overview
The display option "Remember Filters" in search displays does not retain its value when the configuration form is being reloaded.
## Reproduction steps
1. Create a _SearchKit_ search with a search form
2. Add a form display (e.g. _Table_)
3. add some exposed filters
4. Check _Remember Filters_
5. Reload the configuration form for that form display
## Current behaviour
The option seems to be stored and filter values are being stored per user. The option field (checkbox) however is not set when reloading the config form of the form display. Saving the config form without changing that option still seems to retain its value (still storing filter values). So the config form does not reflect the actual option value.
## Expected behaviour
The option should be set when re-visiting the form display config form. Saving the form should respect the value (unchecked: unset the option).
## Environment information
* **Browser:** _Chromium 123.0.6312.58_
* **CiviCRM:** _5.71.0_https://lab.civicrm.org/dev/core/-/issues/5109Smarty 3 causes crash if exception thrown, e.g. by crmAPI2024-03-22T15:10:45ZRichSmarty 3 causes crash if exception thrown, e.g. by crmAPIOverview
----------------------------------------
I think this is a general problem that could occur if a smarty function throws an exception. The page crashes with:
> undefined extension class 'Smarty_Internal_Method_Trigger_Error'
[...Overview
----------------------------------------
I think this is a general problem that could occur if a smarty function throws an exception. The page crashes with:
> undefined extension class 'Smarty_Internal_Method_Trigger_Error'
[chat mention](https://chat.civicrm.org/civicrm/pl/gnqn1rihnprc7er1fcssqd1j6r)
Reproduction steps
----------------------------------------
I edited EventInfo.tpl to put this in:
```
{crmAPI var='local_date_time' entity='Event' action='getvalue' return="custom_115" id=$event.id}
```
Note that I had a custom_115 field defined for all events, but this event did not have a value for that field.
Visit the page that uses that template.
Crash.
Environment information
----------------------------------------
* __CiviCRM:__ 5.70 - 5.71.1
* __PHP:__ 8.1
* __CMS:__ D7
Comments
----------------------------------------
I'm not sure, but from memory api3 getvalue has changed; it now gives an *error* saying:
> "error_message": "field custom_115 unset or not existing"
I'm sure before it just used to return nothing.
Or it could be that before Smarty 3, it was happy to treat nothing as '' and now it's more picky.
I think the main problem seems to be that the exception/error handling is broken in Smarty3. Obviously if there's a bug in the template, it's going not to work, but it oughtn't crash the whole page.
The code that throws the error that causes the crash is CRM/Core/Smarty/plugins/function.crmAPI.php L35:
$smarty->trigger_error('{crmAPI} ' . $e->getMessage());https://lab.civicrm.org/dev/core/-/issues/5108Inconsistent handling of tag name and tag label2024-03-23T14:15:54ZDetlev SieberInconsistent handling of tag name and tag label## Overview
When you change a tag in the tag tree, only the label is changed, the name remains the old entry. So after changing and reloading, in the tag tree the old entry is still shown - despite the previous change.
In the contact s...## Overview
When you change a tag in the tag tree, only the label is changed, the name remains the old entry. So after changing and reloading, in the tag tree the old entry is still shown - despite the previous change.
In the contact summary, the change is not reflected: Because there, the tag name is used, not the tag label. Which also seems, hmm..., interesting...
## Reproduction steps
1. Tag a contact with a specific tag from the tag tree
2. Click on **Contacts -\> Manage Tags**
3. Rename the previously selected tag
4. Reload the tag list -\> again, the old label/name is shown
5. Reload the contact from step 1.: -\> again, the old label/name is shown
## Current behaviour
Renaming the tag in the tag tree only changes the field civicrm_tag.label, not the field civicrm\_tag.name.
This "might" be what we want - however, on several occasions, the tag name is used instead of the tag name.
## Expected behaviour
I would recommend, that both name and label should be changed.
## Environment information
* **CiviCRM:** 5.69.5https://lab.civicrm.org/dev/core/-/issues/5106Admin UI extension breaks contact summary if CiviMember extension is disabled2024-03-27T15:25:42ZKurund JalmiAdmin UI extension breaks contact summary if CiviMember extension is disabledContact summary results in fatal error if Admin UI extension is enabled and CiviMember extension is disabled.
```bash
Civi\API\Exception\NotImplementedException: API (Membership, get) does not exist (or the extension it belongs to is no...Contact summary results in fatal error if Admin UI extension is enabled and CiviMember extension is disabled.
```bash
Civi\API\Exception\NotImplementedException: API (Membership, get) does not exist (or the extension it belongs to is not enabled). in Civi\API\Request::create() (line 51 of /var/www/html/sites/all/modules/civicrm/Civi/API/Request.php).
```