Development issueshttps://lab.civicrm.org/groups/dev/-/issues2024-02-23T21:33:57Zhttps://lab.civicrm.org/dev/core/-/issues/5012Php 8.3 Calling get_parent_class() without arguments is deprecated2024-02-23T21:33:57ZsadashivPhp 8.3 Calling get_parent_class() without arguments is deprecatedOverview
----------------------------------------
Using civicrm 5.69.3, php 8.3, smarty 3 (using civicrm.settings.php)
Reproduction steps
----------------------------------------
1. Created a code snippet to send a simple simple email u...Overview
----------------------------------------
Using civicrm 5.69.3, php 8.3, smarty 3 (using civicrm.settings.php)
Reproduction steps
----------------------------------------
1. Created a code snippet to send a simple simple email using CRM_Utils_Mail::Send()
2. The html should have some tokens
3. In the received email I see above error
Current behaviour
----------------------------------------
Email has text as
Deprecated: Calling get_parent_class() without arguments is deprecated in /var/www/html/my_site/vendor/civicrm/civicrm-core/CRM/Core/SmartyCompatibility.php on line 148
Expected behaviour
----------------------------------------
No error should be reported in the email sendout.
Environment information
----------------------------------------
* __CiviCRM:__ 5.69.3
* __PHP:__ 8.3
* __CMS:__ Drupal 10.2.2
* __Database:__ _MySQL 8
* __Web Server:__ _Apache 2.45.70.1https://lab.civicrm.org/dev/core/-/issues/5007Membership renewal page not selecting current membership level, but selecting...2024-02-23T21:33:32ZcomposerjkMembership renewal page not selecting current membership level, but selecting default insteadOverview
----------------------------------------
The membership contribution page for a renewal seems to select the default contribution membership level instead of the existing level for the user.
Mattermost [mention](https://chat.civ...Overview
----------------------------------------
The membership contribution page for a renewal seems to select the default contribution membership level instead of the existing level for the user.
Mattermost [mention](https://chat.civicrm.org/civicrm/pl/hinxqhmjofn3id6bu6cygj7dia) (but only that it happened).
Reproduction steps
----------------------------------------
1. Go to a join/renew Membership Contribution page link for an existing membership that has a level different than the default.
2. See that the default is selected even when the existing membership is at a different level.
Current behaviour
----------------------------------------
Here's an example on our site with a current `Full Membership` but seeing that `Contributing Membership` is selected (the current default when joining without a membership).
![civi-5.70.0-renewal-not-selecting-current-membership](/uploads/cbb84f3652f7ca430cbf4f0da97475eb/civi-5.70.0-renewal-not-selecting-current-membership.png)
Expected behaviour
----------------------------------------
The `Full Membership` radio button (in this case, button) should be selected, as that's the sample user's existing membership level.
Environment information
----------------------------------------
* __CiviCRM:__ 5.70.0 (but may have also started earlier)
* __PHP:__ 8.1.27
* __CMS:__ WordPress 6.4.3
* __Database:__ MariaDB 10.6.x5.70.1https://lab.civicrm.org/dev/core/-/issues/5006Regression - Events - Registration Confirmation and Receipt (on-line)2024-02-28T20:30:07ZsamuelsovRegression - Events - Registration Confirmation and Receipt (on-line)When doing an event receipt, we have this fatal error :
```
Message was not parsed due to invalid smarty syntax : Smarty error: [in evaluated template line 467]: syntax error: invalid attribute name: '=' (Smarty_Compiler.class.php, line ...When doing an event receipt, we have this fatal error :
```
Message was not parsed due to invalid smarty syntax : Smarty error: [in evaluated template line 467]: syntax error: invalid attribute name: '=' (Smarty_Compiler.class.php, line 1549)
```
I was able to track down this piece of template :
```
{if {event.allow_selfcancelxfer|boolean}}
<tr>
<td colspan="2" {$valueStyle}>
{ts 1=$selfcancelxfer_time 2=$selfservice_preposition}You may transfer your registration to another participant or cancel your registration up to %1 hours %2 the event.{/ts} {if !empty($totalAmount)}{ts}Cancellations are not refundable.{/ts}{/if}<br/>
{capture assign=selfservice_preposition}{if {event.selfcancelxfer_time} > 0}{ts}before{/ts}{else}{ts}after{/ts}{/if}{/capture}
{ts 1={event.selfcancelxfer_time} 2=$selfservice_preposition}You may transfer your registration to another participant or cancel your registration up to %1 hours %2 the event.{/ts}
{if {contribution.paid_amount|boolean}}{ts}Cancellations are not refundable.{/ts}{/if}<br/>
```
Recursive `{` is not working, at least on our instances so those are faulty :
- `{if {event.allow_selfcancelxfer|boolean}}`
- `{if {event.selfcancelxfer_time} > 0}`
- `{ts 1={event.selfcancelxfer_time} 2=$selfservice_preposition}`
Problem introduced in https://github.com/civicrm/civicrm-core/pull/276855.70.1https://lab.civicrm.org/dev/core/-/issues/5005Error Saving Custom Field Group with Event Name that's disabled2024-03-17T21:17:39ZsavionleeError Saving Custom Field Group with Event Name that's disabledOverview
----------------------------------------
After disabling an event, an error is raised when trying to reuse a custom field group for a new event. It returns a message
```Supplied Sub type is not valid for the specified entity``...Overview
----------------------------------------
After disabling an event, an error is raised when trying to reuse a custom field group for a new event. It returns a message
```Supplied Sub type is not valid for the specified entity```
When trying to save on Civi 5.70 in Wordpress, this box was raised:
![image](/uploads/7ac617b95a1872ae6753b12c69c449fd/image.png)
The error message is presented after clicking through it in the pop up civi alerts.
Reproduction steps
----------------------------------------
1. Create *Event 1* copy it to *Event 1 Copy*
1. Create a Custom Field Set attach **Participant -> Partipants (Event Name)** Pick Event 1
1. Disable *Event 1*
1. Go back and add *Event 1 Copy* to Custom Field Set
1. Got an error "**message: Supplied Sub type is not valid for the specified entity**".
Current behaviour
----------------------------------------
_What happens currently. Please provide error messages, screenshots or gifs ([LICEcap](http://www.cockos.com/licecap/), [SilentCast](https://github.com/colinkeenan/silentcast)) where appropriate._
```
***ERROR***
message: Supplied Sub type is not valid for the specified entity
code:
exception: CRM_Core_Exception Object
(
[message:protected] => Supplied Sub type is not valid for the specified entity
[string:Exception:private] =>
[code:protected] => 0
[file:protected] => /bitnami/wordpress/wp-content/plugins/civicrm/civicrm/api/api.php
[line:protected] => 138
[trace:Exception:private] => Array
(
[0] => Array
(
[file] => /bitnami/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Custom/Form/Group.php
[line] => 293
[function] => civicrm_api3
)
[1] => Array
(
[file] => /bitnami/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/Form.php
[line] => 641
[function] => postProcess
[class] => CRM_Custom_Form_Group
[type] => ->
)
[2] => Array
(
[file] => /bitnami/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/StateMachine.php
[line] => 144
[function] => mainProcess
[class] => CRM_Core_Form
[type] => ->
)
[3] => Array
(
[file] => /bitnami/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/QuickForm/Action/Next.php
[line] => 43
[function] => perform
[class] => CRM_Core_StateMachine
[type] => ->
)
[4] => Array
(
[file] => /bitnami/wordpress/wp-content/plugins/civicrm/civicrm/packages/HTML/QuickForm/Controller.php
[line] => 203
[function] => perform
[class] => CRM_Core_QuickForm_Action_Next
[type] => ->
)
[5] => Array
(
...
```
Expected behaviour
----------------------------------------
_What should happen._
I should be able to add a new event to the custom field group even though the old event is disabled.
Environment information
----------------------------------------
<!-- Some of the items below may not be relevant for every bug - if in doubt please include more information than you think is neccessary. -->
* __Browser:__ _Firefox 122.0.1_
* __CiviCRM:__ _5.70.0/5.72.0..._ <!-- If this problem relates to an upgrade, then specify both old and new versions -->
* __PHP:__ _8.1.1__
* __CMS:__ _Wordpress 6.4.3_
* __Database:__ _MariaDB..._
* __Web Server:__ _Apache..._
Comments
----------------------------------------
_Anything else you would like the reviewer to note._https://lab.civicrm.org/dev/core/-/issues/4997Anonymous visitors cannot access a contribution page with financial type by A...2024-02-12T21:08:46ZandyburnsAnonymous visitors cannot access a contribution page with financial type by ACL enabledOn a vanilla WP 6.4.3 and CiviCRM 5.70 dummy site, enabling `Enable Access Control by Financial Type` results in the contribution page being inaccessible and redirects back to the home page.
The goal of using this feature is for back-e...On a vanilla WP 6.4.3 and CiviCRM 5.70 dummy site, enabling `Enable Access Control by Financial Type` results in the contribution page being inaccessible and redirects back to the home page.
The goal of using this feature is for back-end contribution access for different types of users.
![image.png](/uploads/bea2e67bd300271650dbef7de9267ba7/image.png)
* `add_contributions_of_type_donation` and `view_contributions_of_type_donation` permissions are given to the `anonymous_user` role.
* I've [hit this before](https://chat.civicrm.org/civicrm/pl/5wzfkebnebfutbi1o8orkxsh8c) but that was when these permissions were missing and I updated the [docs to reflect this requirement](https://docs.civicrm.org/user/en/latest/initial-set-up/permissions-and-access-control/#financial-type-permissions).
* Event Registration pages work without issue when the financial types are properly granted to the anonymous_user `add_contributions_of_type_event_fee` and `view_contributions_of_type_event_fee`
* I've reproduced this issue back to at least Civi 5.68. Last worked on 5.65.1. I'm sure others use this feature so odd I'm reporting but there you go.
## Anonymous User Permissions
* access_all_custom_data
* access_civimail_subscribe_unsubscribe_pages
* access_uploaded_files
* add_contributions_of_type_donation
* add_contributions_of_type_event_fee
* add_contributions_of_type_member_dues
* make_online_contributions
* profile_create
* profile_edit
* profile_view
* register_for_events
* sign_civicrm_petition
* view_contributions_of_type_donation
* view_contributions_of_type_event_fee
* view_contributions_of_type_member_dues
* view_event_info
* view_my_invoices
* view_public_civimail_content
## Backtrace error:
```plaintext
2024-02-09 19:16:28+0000 [debug] $API Request Authorization failed = #0 /home/user/example.org/wp-content/plugins/civicrm/civicrm/Civi/API/Kernel.php(151): CRM_Core_Error::backtrace("API Request Authorization failed", TRUE)
#1 /home/user/example.org/wp-content/plugins/civicrm/civicrm/Civi/Api4/Generic/AbstractAction.php(256): Civi\API\Kernel->runRequest(Object(Civi\Api4\Generic\DAOGetAction))
#2 /home/user/example.org/wp-content/plugins/civicrm/civicrm/CRM/Financial/BAO/FinancialType.php(181): Civi\Api4\Generic\AbstractAction->execute()
#3 /home/user/example.org/wp-content/plugins/civicrm/civicrm/CRM/Contribute/BAO/ContributionPage.php(822): CRM_Financial_BAO_FinancialType::getIncomeFinancialType(TRUE)
#4 /home/user/example.org/wp-content/plugins/civicrm/civicrm/Civi/Api4/Utils/FormattingUtil.php(306): CRM_Contribute_BAO_ContributionPage::buildOptions("financial_type_id", "validate", (Array:2))
#5 /home/user/example.org/wp-content/plugins/civicrm/civicrm/Civi/Api4/Utils/FormattingUtil.php(257): Civi\Api4\Utils\FormattingUtil::getPseudoconstantList((Array:37), "financial_type_id:name", (Array:2), "get")
#6 /home/user/example.org/wp-content/plugins/civicrm/civicrm/Civi/Api4/Query/Api4SelectQuery.php(108): Civi\Api4\Utils\FormattingUtil::formatOutputValues((Array:2), (Array:48), "get", (Array:2))
#7 /home/user/example.org/wp-content/plugins/civicrm/civicrm/Civi/Api4/Generic/DAOGetAction.php(107): Civi\Api4\Query\Api4SelectQuery->run()
#8 /home/user/example.org/wp-content/plugins/civicrm/civicrm/Civi/Api4/Generic/DAOGetAction.php(94): Civi\Api4\Generic\DAOGetAction->getObjects(Object(Civi\Api4\Generic\Result))
#9 /home/user/example.org/wp-content/plugins/civicrm/civicrm/Civi/Api4/Provider/ActionObjectProvider.php(72): Civi\Api4\Generic\DAOGetAction->_run(Object(Civi\Api4\Generic\Result))
#10 /home/user/example.org/wp-content/plugins/civicrm/civicrm/Civi/API/Kernel.php(156): Civi\Api4\Provider\ActionObjectProvider->invoke(Object(Civi\Api4\Generic\DAOGetAction))
#11 /home/user/example.org/wp-content/plugins/civicrm/civicrm/Civi/Api4/Generic/AbstractAction.php(256): Civi\API\Kernel->runRequest(Object(Civi\Api4\Generic\DAOGetAction))
#12 /home/user/example.org/wp-content/plugins/civicrm/civicrm/api/api.php(91): Civi\Api4\Generic\AbstractAction->execute()
#13 /home/user/example.org/wp-content/plugins/civicrm/civicrm/Civi/API/EntityLookupTrait.php(111): civicrm_api4("ContributionPage", "get", (Array:3))
#14 /home/user/example.org/wp-content/plugins/civicrm/civicrm/CRM/Contribute/Form/ContributeFormTrait.php(81): CRM_Contribute_Form_ContributionBase->lookup("ContributionPage", "financial_type_id:name")
#15 /home/user/example.org/wp-content/plugins/civicrm/civicrm/ext/financialacls/financialacls.php(431): CRM_Contribute_Form_ContributionBase->getContributionPageValue("financial_type_id:name")
#16 /home/user/example.org/wp-content/plugins/civicrm/civicrm/CRM/Utils/Hook.php(276): financialacls_civicrm_preProcess("CRM_Contribute_Form_Contribution_Main", Object(CRM_Contribute_Form_Contribution_Main))
#17 /home/user/example.org/wp-content/plugins/civicrm/civicrm/CRM/Utils/Hook/WordPress.php(136): CRM_Utils_Hook->runHooks((Array:16), "civicrm_preProcess", 2, "CRM_Contribute_Form_Contribution_Main", Object(CRM_Contribute_Form_Contribution_Main), NULL, NULL, NULL, NULL)
#18 /home/user/example.org/wp-content/plugins/civicrm/civicrm/Civi/Core/CiviEventDispatcher.php(314): CRM_Utils_Hook_WordPress->invokeViaUF(2, "CRM_Contribute_Form_Contribution_Main", Object(CRM_Contribute_Form_Contribution_Main), NULL, NULL, NULL, NULL, "civicrm_preProcess")
#19 /home/user/example.org/wp-content/plugins/civicrm/civicrm/vendor/symfony/event-dispatcher/EventDispatcher.php(251): Civi\Core\CiviEventDispatcher::delegateToUF(Object(Civi\Core\Event\GenericHookEvent), "hook_civicrm_preProcess", Object(Civi\Core\UnoptimizedEventDispatcher))
#20 /home/user/example.org/wp-content/plugins/civicrm/civicrm/vendor/symfony/event-dispatcher/EventDispatcher.php(73): Symfony\Component\EventDispatcher\EventDispatcher->callListeners((Array:1), "hook_civicrm_preProcess", Object(Civi\Core\Event\GenericHookEvent))
#21 /home/user/example.org/wp-content/plugins/civicrm/civicrm/Civi/Core/CiviEventDispatcher.php(263): Symfony\Component\EventDispatcher\EventDispatcher->dispatch(Object(Civi\Core\Event\GenericHookEvent), "hook_civicrm_preProcess")
#22 /home/user/example.org/wp-content/plugins/civicrm/civicrm/CRM/Utils/Hook.php(168): Civi\Core\CiviEventDispatcher->dispatch("hook_civicrm_preProcess", Object(Civi\Core\Event\GenericHookEvent))
#23 /home/user/example.org/wp-content/plugins/civicrm/civicrm/CRM/Utils/Hook.php(476): CRM_Utils_Hook->invoke((Array:2), "CRM_Contribute_Form_Contribution_Main", Object(CRM_Contribute_Form_Contribution_Main), NULL, NULL, NULL, NULL, "civicrm_preProcess")
#24 /home/user/example.org/wp-content/plugins/civicrm/civicrm/CRM/Core/Form.php(733): CRM_Utils_Hook::preProcess("CRM_Contribute_Form_Contribution_Main", Object(CRM_Contribute_Form_Contribution_Main))
#25 /home/user/example.org/wp-content/plugins/civicrm/civicrm/CRM/Core/QuickForm/Action/Display.php(76): CRM_Core_Form->buildForm()
#26 /home/user/example.org/wp-content/plugins/civicrm/civicrm/packages/HTML/QuickForm/Controller.php(203): CRM_Core_QuickForm_Action_Display->perform(Object(CRM_Contribute_Form_Contribution_Main), "display")
#27 /home/user/example.org/wp-content/plugins/civicrm/civicrm/packages/HTML/QuickForm/Page.php(103): HTML_QuickForm_Controller->handle(Object(CRM_Contribute_Form_Contribution_Main), "display")
#28 /home/user/example.org/wp-content/plugins/civicrm/civicrm/CRM/Core/Controller.php(355): HTML_QuickForm_Page->handle("display")
#29 /home/user/example.org/wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php(322): CRM_Core_Controller->run((Array:3), NULL)
#30 /home/user/example.org/wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php(69): CRM_Core_Invoke::runItem((Array:18))
#31 /home/user/example.org/wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php(36): CRM_Core_Invoke::_invoke((Array:3))
#32 /home/user/example.org/wp-content/plugins/civicrm/civicrm.php(1231): CRM_Core_Invoke::invoke((Array:3))
#33 /home/user/example.org/wp-content/plugins/civicrm/includes/civicrm.shortcodes.php(433): CiviCRM_For_WordPress->invoke()
#34 /home/user/example.org/wp-includes/shortcodes.php(433): CiviCRM_For_WordPress_Shortcodes->render_single((Array:5), "", "civicrm")
#35 [internal function](): do_shortcode_tag((Array:7))
#36 /home/user/example.org/wp-includes/shortcodes.php(273): preg_replace_callback("/\[(\[?)(civicrm)(?![\w-])([^\]\/]*(?:\/(?!\])[^\]\/]*)*?)(?:(\/)\]|\](?:([^\...", "do_shortcode_tag", "[civicrm component=\"contribution\" id=\"1\" action=\"transact\" mode=\"live\...")
#37 /home/user/example.org/wp-content/plugins/civicrm/includes/civicrm.shortcodes.php(232): do_shortcode("[civicrm component=\"contribution\" id=\"1\" action=\"transact\" mode=\"live\...")
#38 /home/user/example.org/wp-includes/class-wp-hook.php(324): CiviCRM_For_WordPress_Shortcodes->prerender(Object(WP))
#39 /home/user/example.org/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters(NULL, (Array:1))
#40 /home/user/example.org/wp-includes/plugin.php(565): WP_Hook->do_action((Array:1))
#41 /home/user/example.org/wp-includes/class-wp.php(830): do_action_ref_array("wp", (Array:1))
#42 /home/user/example.org/wp-includes/functions.php(1336): WP->main("")
#43 /home/user/example.org/wp-blog-header.php(16): wp()
#44 /home/user/example.org/index.php(17): require("/home/user/example.org/wp-blog-header.php")
#45 {main}
```
## System Info
PHP version 8.0.30
**Extensions**
* AuthX: Version 5.70.0
* CiviCampaign: Version 5.70.0
* CiviContribute: Version 5.70.0
* CiviEvent: Version 5.70.0
* CiviMail: Version 5.70.0
* CiviMember: Version 5.70.0
* CiviReport: Version 5.70.0
* CKEditor4: Version 5.70.0
* Financial ACLs: Version 5.70.0
* FlexMailer: Version 5.70.0
* Form Core: Version 5.70.0
* reCAPTCHA: Version 5.70.0
* SearchKit: Version 5.70.0
* Sequential credit notes: Version 5.70.0
* Theme: Greenwich: Version 5.70.0
Thoughts? Is there a missing setting or is this an actual bug?5.71.0https://lab.civicrm.org/dev/core/-/issues/49895.69.4>5 regression - Multiple currency issues in contribution page workflow2024-02-13T19:58:40ZJKingsnorth5.69.4>5 regression - Multiple currency issues in contribution page workflowTesting latest master we have multiple issues when setting a contribution page to a non-default currency.
In all the following examples I changed the currency of the contribution page to JPY.
---
1 - 'Confirm' and 'Thank You' pages sh...Testing latest master we have multiple issues when setting a contribution page to a non-default currency.
In all the following examples I changed the currency of the contribution page to JPY.
---
1 - 'Confirm' and 'Thank You' pages show default instead of contribution page set currency
![image](/uploads/cfd5a92065599d8c937b806e1289e508/image.png)
---
2 - 'currency' variable is not being set correctly in ContributionBase, which could be affecting client side payment processors?
![image](/uploads/bb16b6e00884f747dbf18f0f6aaa22eb/image.png)
'currencyID' uses the form _values, 'currency' is using the default site currency.5.70.1https://lab.civicrm.org/dev/core/-/issues/4980Crash on thankyou page when no paymentProcessorObject is set2024-02-08T09:56:27ZBastien HoCrash on thankyou page when no paymentProcessorObject is setSince v5.69, I get this error on contribution pages, on "thank you".
```
PHP Fatal error: Uncaught Error: Call to a member function getText() on null in CRM/Contribute/Form/ContributionBase.php:995
```
In fact, the diff shows that a p...Since v5.69, I get this error on contribution pages, on "thank you".
```
PHP Fatal error: Uncaught Error: Call to a member function getText() on null in CRM/Contribute/Form/ContributionBase.php:995
```
In fact, the diff shows that a previous check has been removed
[-if ($isMonetary && $this->_paymentProcessor['object'] instanceof \CRM_Core_Payment) { -]
[- $paymentProcessorObject = $this->_paymentProcessor['object'];-]
[+if ($isMonetary) {+]
[+ $paymentProcessorObject = $this->getPaymentProcessorObject();+]
I suggest to implement a new check `if($paymentProcessorObject)`
In addition, a checkup should be implemented in _PaymentProcessorFormTrait.php_.5.69.5https://lab.civicrm.org/dev/core/-/issues/4977FormBuilder with relationship and custom field fields to encode correctly (5.70)2024-02-18T13:45:49ZbgmFormBuilder with relationship and custom field fields to encode correctly (5.70)Odd bug on 5.70/RC where it's generating afform markup that looks like:
```
<af-entity security="FBAC" type="Relationship"
name="Relationship2" label="Relation 2"
actions="{create: true, update: true}"
data="{contact_id_a: ['Indiv...Odd bug on 5.70/RC where it's generating afform markup that looks like:
```
<af-entity security="FBAC" type="Relationship"
name="Relationship2" label="Relation 2"
actions="{create: true, update: true}"
data="{contact_id_a: ['Individual1'], relationship_type_id: '13', "MyCustom.MyField": '1'}" />
```
This is a custom field on a relationship, that is used in the form. Because of the double-quotes around the MyCustom field, it's causing an AngualrJS syntax error.
To reproduce:
- Create a custom-group/field for Relationships
- Create a form that adds a relationship, and pre-selects a value for the custom field
![image](/uploads/04aa00dfd4def6189fe404ed6689ce91/image.png)
Save the form, then do a full page reload (sometimes it's not obvious at first). It will fail to load correctly, and JS errors in the console.
I can fix the syntax by manually editing the file, but then it creeps back when we do changes to the form.
For what it's worth, my test site is on PHP 8.0, and dmaster is on PHP 8.2.5.71.0colemanwcolemanwhttps://lab.civicrm.org/dev/core/-/issues/4974Event with no fees shows the fees section with just the word "Total" on the r...2024-02-07T22:37:29ZDaveDEvent with no fees shows the fees section with just the word "Total" on the register pageAnd says Undefined array key "quickConfig".
It doesn't affect registration, but is obviously wrong. In 5.71 caused by https://github.com/civicrm/civicrm-core/pull/29197 (yes the one I just merged 2 minutes ago - I figured it was better ...And says Undefined array key "quickConfig".
It doesn't affect registration, but is obviously wrong. In 5.71 caused by https://github.com/civicrm/civicrm-core/pull/29197 (yes the one I just merged 2 minutes ago - I figured it was better to get the waitlist fix in).5.71.0https://lab.civicrm.org/dev/core/-/issues/4973Credit card info not appearing on event confirm/thankyou page2024-02-08T09:56:27ZDaveDCredit card info not appearing on event confirm/thankyou pageAnd there's undefined array key errors about it.
I'm not sure when this started - it's not working in 5.69. Labelling as regression for now.And there's undefined array key errors about it.
I'm not sure when this started - it's not working in 5.69. Labelling as regression for now.5.69.5https://lab.civicrm.org/dev/core/-/issues/4971Error when attempting to edit CiviEvent scheduled reminders2024-02-20T23:15:44ZrichardsplaygroundError when attempting to edit CiviEvent scheduled remindersOverview
----------------------------------------
A user with tries to edit a scheduled reminder on an event and sees only a blank screen. Logs show errors.
Strangely, they can create new scheduled reminders on events no problem. Bu...Overview
----------------------------------------
A user with tries to edit a scheduled reminder on an event and sees only a blank screen. Logs show errors.
Strangely, they can create new scheduled reminders on events no problem. But they then cannot edit the event scheduled reminder, not even for reminders they themselves created.
This occurs on CiviCRM 5.68 on Drupal 7 as well as on Civi 5.70.alpha1 generated today with buildkit drupal-demo.
** This worked on CiviCRM 5.52. There have been no changes to the user, roles, or permissions between it working on 5.52 and not working on 5.68. **
[Posted on StackExchange](https://civicrm.stackexchange.com/questions/46242/error-when-editing-but-not-creating-event-scheduled-reminder) but did not generate any discussion.
Role & Permissions
----------------------------------------
A user with "administrator" permissions can edit scheduled reminders on an event with no errors or issues.
A user with the following permissions receives an error when attempting to edit scheduled reminders on an event:
* CiviCRM: skip IDS check
* CiviCRM: access CiviCRM backend and API
* CiviEvent: access CiviEvent
* CiviEvent: edit event participants
* CiviEvent: edit all events
* CiviEvent: register for events
* CiviEvent: view event info
Error
----------------------------------------
When a user with the above permissions attempts to edit a scheduled reminder, what they see in the web UI is this:
![view_when_eventhelper_user_tries_to_edit_scheduled_reminder](/uploads/a0bec6e86da1d7bbba18334b5f64cc55/view_when_eventhelper_user_tries_to_edit_scheduled_reminder.png)
What the Javascript Console shows is this:
![console_error_when_eventhelper_tries_to_see_a_scheduled_event](/uploads/cfccaea9fe9336a7ad5bcb26545473a0/console_error_when_eventhelper_tries_to_see_a_scheduled_event.png)
What the logviewer shows is this on Civi 5.70.alpha1 (buildkit drupal-demo):
```
[error]
$Fatal Error Details = array:3 [
"message" => "Authorization failed"
"code" => null
"exception" => Civi\API\Exception\UnauthorizedException {#706
#message: "Authorization failed"
#code: 0
#file: "/buildkit/build/drupal-demo/web/sites/all/modules/civicrm/Civi/API/Kernel.php"
#line: 230
#cause: null
-_trace: null
-errorData: array:1 [
"error_code" => "unauthorized"
]
trace: {
/buildkit/build/drupal-demo/web/sites/all/modules/civicrm/Civi/API/Kernel.php:230 {
Civi\API\Kernel->authorize($apiProvider, $apiRequest)
› if (!$event->isAuthorized()) {
› throw new \Civi\API\Exception\UnauthorizedException("Authorization failed");
› }
}
/buildkit/build/drupal-demo/web/sites/all/modules/civicrm/Civi/API/Kernel.php:147 { …}
/buildkit/build/drupal-demo/web/sites/all/modules/civicrm/Civi/Api4/Generic/AbstractAction.php:256 { …}
/buildkit/build/drupal-demo/web/sites/all/modules/civicrm/api/api.php:91 { …}
/buildkit/build/drupal-demo/web/sites/all/modules/civicrm/CRM/Admin/Form.php:169 { …}
/buildkit/build/drupal-demo/web/sites/all/modules/civicrm/CRM/Admin/Form.php:79 { …}
/buildkit/build/drupal-demo/web/sites/all/modules/civicrm/CRM/Admin/Form/ScheduleReminders.php:50 { …}
/buildkit/build/drupal-demo/web/sites/all/modules/civicrm/CRM/Core/Form.php:731 { …}
/buildkit/build/drupal-demo/web/sites/all/modules/civicrm/CRM/Core/QuickForm/Action/Display.php:76 { …}
/buildkit/build/drupal-demo/web/sites/all/modules/civicrm/packages/HTML/QuickForm/Controller.php:203 { …}
/buildkit/build/drupal-demo/web/sites/all/modules/civicrm/packages/HTML/QuickForm/Page.php:103 { …}
/buildkit/build/drupal-demo/web/sites/all/modules/civicrm/CRM/Core/Controller.php:355 { …}
/buildkit/build/drupal-demo/web/sites/all/modules/civicrm/CRM/Utils/Wrapper.php:98 { …}
/buildkit/build/drupal-demo/web/sites/all/modules/civicrm/CRM/Core/Invoke.php:295 { …}
/buildkit/build/drupal-demo/web/sites/all/modules/civicrm/CRM/Core/Invoke.php:69 { …}
/buildkit/build/drupal-demo/web/sites/all/modules/civicrm/CRM/Core/Invoke.php:36 { …}
/buildkit/build/drupal-demo/web/sites/all/modules/civicrm/drupal/civicrm.module:472 { …}
/buildkit/build/drupal-demo/web/includes/menu.inc:527 { …}
/buildkit/build/drupal-demo/web/index.php:21 { …}
}
}
]
2024-02-06 05:12:58+0000 [debug] $backTrace = #0 /buildkit/build/drupal-demo/web/sites/all/modules/civicrm/CRM/Core/Error.php(443): CRM_Core_Error::backtrace("backTrace", TRUE)
#1 /buildkit/build/drupal-demo/web/sites/all/modules/civicrm/CRM/Core/Invoke.php(39): CRM_Core_Error::handleUnhandledException(Object(Civi\API\Exception\UnauthorizedException))
#2 /buildkit/build/drupal-demo/web/sites/all/modules/civicrm/drupal/civicrm.module(472): CRM_Core_Invoke::invoke((Array:4))
#3 /buildkit/build/drupal-demo/web/includes/menu.inc(527): civicrm_invoke("admin", "scheduleReminders", "edit")
#4 /buildkit/build/drupal-demo/web/index.php(21): menu_execute_active_handler()
#5 {main}
```
and what the logs show on a different system running CiviCRM 5.68 is this:
```
2024-01-15 15:30:56-0800 [debug] $API Request Authorization failed = #0 /var/www/html/sites/all/modules/civicrm/Civi/API/Kernel.php(151): CRM_Core_Error::backtrace("API Request Authorization failed", TRUE)
#1 /var/www/html/sites/all/modules/civicrm/Civi/Api4/Generic/AbstractAction.php(256): Civi\API\Kernel->runRequest(Object(Civi\Api4\Generic\DAOGetAction))
#2 /var/www/html/sites/all/modules/civicrm/api/api.php(91): Civi\Api4\Generic\AbstractAction->execute()
#3 /var/www/html/sites/all/modules/civicrm/CRM/Admin/Form.php(161): civicrm_api4("ActionSchedule", "get", (Array:1))
#4 /var/www/html/sites/all/modules/civicrm/CRM/Admin/Form.php(77): CRM_Admin_Form->retrieveValues()
#5 /var/www/html/sites/all/modules/civicrm/CRM/Admin/Form/ScheduleReminders.php(50): CRM_Admin_Form->preProcess()
#6 /var/www/html/sites/all/modules/civicrm/CRM/Core/Form.php(717): CRM_Admin_Form_ScheduleReminders->preProcess()
#7 /var/www/html/sites/all/modules/civicrm/CRM/Core/QuickForm/Action/Display.php(76): CRM_Core_Form->buildForm()
#8 /var/www/html/sites/all/modules/civicrm/packages/HTML/QuickForm/Controller.php(203): CRM_Core_QuickForm_Action_Display->perform(Object(CRM_Admin_Form_ScheduleReminders), "display")
#9 /var/www/html/sites/all/modules/civicrm/packages/HTML/QuickForm/Page.php(103): HTML_QuickForm_Controller->handle(Object(CRM_Admin_Form_ScheduleReminders), "display")
#10 /var/www/html/sites/all/modules/civicrm/CRM/Core/Controller.php(355): HTML_QuickForm_Page->handle("display")
#11 /var/www/html/sites/all/modules/civicrm/CRM/Utils/Wrapper.php(98): CRM_Core_Controller->run()
#12 /var/www/html/sites/all/modules/civicrm/CRM/Core/Invoke.php(295): CRM_Utils_Wrapper->run("CRM_Admin_Form_ScheduleReminders", "Schedule Reminders", (Array:0))
#13 /var/www/html/sites/all/modules/civicrm/CRM/Core/Invoke.php(69): CRM_Core_Invoke::runItem((Array:17))
#14 /var/www/html/sites/all/modules/civicrm/CRM/Core/Invoke.php(36): CRM_Core_Invoke::_invoke((Array:4))
#15 /var/www/html/sites/all/modules/civicrm/drupal/civicrm.module(472): CRM_Core_Invoke::invoke((Array:4))
#16 /var/www/html/includes/menu.inc(527): civicrm_invoke("admin", "scheduleReminders", "edit")
#17 /var/www/html/index.php(21): menu_execute_active_handler()
#18 {main}
2024-01-15 15:30:56-0800 [error]
$Fatal Error Details = array:3 [
"message" => "Authorization failed"
"code" => null
"exception" => Civi\API\Exception\UnauthorizedException {#2401
-errorData: array:1 [
"error_code" => "unauthorized"
]
#cause: null
-_trace: null
#message: "Authorization failed"
#code: 0
#file: "/var/www/html/sites/all/modules/civicrm/Civi/API/Kernel.php"
#line: 230
trace: {
/var/www/html/sites/all/modules/civicrm/Civi/API/Kernel.php:230 {
Civi\API\Kernel->authorize($apiProvider, $apiRequest)
› if (!$event->isAuthorized()) {
› throw new \Civi\API\Exception\UnauthorizedException("Authorization failed");
› }
}
/var/www/html/sites/all/modules/civicrm/Civi/API/Kernel.php:147 { …}
/var/www/html/sites/all/modules/civicrm/Civi/Api4/Generic/AbstractAction.php:256 { …}
/var/www/html/sites/all/modules/civicrm/api/api.php:91 { …}
/var/www/html/sites/all/modules/civicrm/CRM/Admin/Form.php:161 { …}
/var/www/html/sites/all/modules/civicrm/CRM/Admin/Form.php:77 { …}
/var/www/html/sites/all/modules/civicrm/CRM/Admin/Form/ScheduleReminders.php:50 { …}
/var/www/html/sites/all/modules/civicrm/CRM/Core/Form.php:717 { …}
/var/www/html/sites/all/modules/civicrm/CRM/Core/QuickForm/Action/Display.php:76 { …}
/var/www/html/sites/all/modules/civicrm/packages/HTML/QuickForm/Controller.php:203 { …}
/var/www/html/sites/all/modules/civicrm/packages/HTML/QuickForm/Page.php:103 { …}
/var/www/html/sites/all/modules/civicrm/CRM/Core/Controller.php:355 { …}
/var/www/html/sites/all/modules/civicrm/CRM/Utils/Wrapper.php:98 { …}
/var/www/html/sites/all/modules/civicrm/CRM/Core/Invoke.php:295 { …}
/var/www/html/sites/all/modules/civicrm/CRM/Core/Invoke.php:69 { …}
/var/www/html/sites/all/modules/civicrm/CRM/Core/Invoke.php:36 { …}
/var/www/html/sites/all/modules/civicrm/drupal/civicrm.module:472 { …}
/var/www/html/includes/menu.inc:527 { …}
/var/www/html/index.php:21 { …}
}
}
]
2024-01-15 15:30:56-0800 [debug] $backTrace = #0 /var/www/html/sites/all/modules/civicrm/CRM/Core/Error.php(443): CRM_Core_Error::backtrace("backTrace", TRUE)
#1 /var/www/html/sites/all/modules/civicrm/CRM/Core/Invoke.php(39): CRM_Core_Error::handleUnhandledException(Object(Civi\API\Exception\UnauthorizedException))
#2 /var/www/html/sites/all/modules/civicrm/drupal/civicrm.module(472): CRM_Core_Invoke::invoke((Array:4))
#3 /var/www/html/includes/menu.inc(527): civicrm_invoke("admin", "scheduleReminders", "edit")
#4 /var/www/html/index.php(21): menu_execute_active_handler()
#5 {main}
```
Reproduction steps
----------------------------------------
1. Build a buildkit drupal-demo
2. Log in as administrator, create a new role and give it the permissions noted above.
3. Create a new user ("eventhelper"), assign user this role.
4. (Still as administrator, or any other user) Create an event and create a scheduled reminder for the event.
5. Log out. Log in as eventhelper.
6. Go to the event, edit, go to the scheduled reminders tab, click edit next to the reminder.
Current behaviour
----------------------------------------
As above.
Expected behaviour
----------------------------------------
The user should be able to edit and save the scheduled reminder.
Comments
----------------------------------------
There are no permissions related to scheduled reminders. So although the log output says this is an authorization error, I don't see what authorization to give.
I'd also emphasize this worked in 5.52 with no changes to the user, role, or permissions.
Last, the user can create scheduled reminders on events, just not edit schedule reminders on events, even editing schedule reminders they themselves created. This is inconsistent so suggests a bug.colemanwcolemanwhttps://lab.civicrm.org/dev/core/-/issues/4970(regression) Extra receipt is sent when marking a contribution complete.2024-02-08T10:01:04ZJonGold(regression) Extra receipt is sent when marking a contribution complete.Overview
----------------------------------------
Starting in 5.69, changing a Pending contribution to Completed sends a receipt even if you choose not to.
Reproduction steps
----------------------------------------
1. Create a new pend...Overview
----------------------------------------
Starting in 5.69, changing a Pending contribution to Completed sends a receipt even if you choose not to.
Reproduction steps
----------------------------------------
1. Create a new pending contribution on the backend.
1. Click **Edit**.
1. Change the contribution to complete.
Current behaviour
----------------------------------------
If you don't select "Send Receipt", a receipt is sent.
If you *do* select "Send Receipt", 2 receipts are sent.
Expected behaviour
----------------------------------------
current situation minus 1.
Comments
----------------------------------------
The conversion from `transitionComponents()` to `Payment.create` is what occasioned this.5.69.5JonGoldJonGoldhttps://lab.civicrm.org/dev/core/-/issues/4969Angular manager module caching issue (TypeError in_array)2024-03-18T21:46:01ZJKingsnorthAngular manager module caching issue (TypeError in_array)Related question was raised here: https://civicrm.stackexchange.com/questions/46379/typeerror-in-array-angular-managerresolvedefaultmodules-civicrm-version-5
I think this is a recent change which might have caused the issues (or highlig...Related question was raised here: https://civicrm.stackexchange.com/questions/46379/typeerror-in-array-angular-managerresolvedefaultmodules-civicrm-version-5
I think this is a recent change which might have caused the issues (or highlighted them): https://github.com/civicrm/civicrm-core/commit/604cca726c6a238e0530b5f660ab0e11596da090#diff-b26b657986ef8b8163e79bcaf85afe628f6d5457193253bc6ff4c009cca44bf5
---
We're seeing an intermittent issue where pages fail to load with a fatal error. The only path we've detected it on is /civicrm/transact .
It's caused by `\Civi\Angular\Manager::resolveDefaultModules` looking for the 'basePages' array for a module definition, but it's not there. After some checking, it looks like the value is just null (ie, there's no definition set).
Digging back through \Civi\Angular\Manager::getModules we can see that this checks to see if `$this->cache->get('moduleNames');` is null. If it is, it rebuilds the list of modules and saves it to the cache, and then goes through each module and saves the definition to the cache - using separate cache key entries (I guess because otherwise the cache entry would be too big?)
```
$angularModules = $this->resolvePatterns($angularModules);
$this->cache->set('moduleNames', array_keys($angularModules));
foreach ($angularModules as $moduleName => $moduleInfo) {
$this->cache->set("module $moduleName", $moduleInfo);
}
```
If `moduleNames` is already set, then it rehydrates the data from the cache:
```
// Rehydrate modules from cache
else {
foreach ($moduleNames as $moduleName) {
$angularModules[$moduleName] = $this->cache->get("module $moduleName");
}
```
The problem I think we're seeing intermittently is that `$this->cache->get('moduleNames');` is set but the individual module definitions (or some of them at least) are not set `$this->cache->get("module $moduleName");` . This means the value is set as 'NULL', which is causing the original error.
I'm struggling to find the exact steps to recreate this issue, but I think the related code could do with tightening up in either case?
It doesn't look like we can rely on the 'module ...' cache entries being set if the 'moduleNames' entry is set?
Ping @colemanwhttps://lab.civicrm.org/dev/core/-/issues/4968Can no longer edit status for a participant2024-02-07T18:56:07ZDaveDCan no longer edit status for a participant1. Register a participant. It doesn't happen with demo participants. Make a new participant.
2. Edit the participant and change status to e.g. Attended.
3. `ValueError: mysqli_query(): Argument 2 ($query) cannot be empty in mysqli_query(...1. Register a participant. It doesn't happen with demo participants. Make a new participant.
2. Edit the participant and change status to e.g. Attended.
3. `ValueError: mysqli_query(): Argument 2 ($query) cannot be empty in mysqli_query() (line 411 of /srv/buildkit/build/dmaster/web/sites/all/modules/civicrm/vendor/pear/db/DB/mysqli.php).`5.71.0https://lab.civicrm.org/dev/core/-/issues/4967Can no longer register someone for an event in the backend as pay-later2024-02-04T19:26:18ZDaveDCan no longer register someone for an event in the backend as pay-later1. Register someone in the backend for an event with status Pay-later.
2. Error: Please select at least one option from price set.1. Register someone in the backend for an event with status Pay-later.
2. Error: Please select at least one option from price set.https://lab.civicrm.org/dev/core/-/issues/4963(5.69 regression) Can't pay later on a membership price set2024-02-08T19:14:42ZJonGold(5.69 regression) Can't pay later on a membership price setIn 5.69, you can't select "Pay Later" for a membership price set. You get the warning "You cannot have auto-renewal on if you are paying later.", even when selecting a non-renewal option.
#### Steps to replicate
* On a demo site, chang...In 5.69, you can't select "Pay Later" for a membership price set. You get the warning "You cannot have auto-renewal on if you are paying later.", even when selecting a non-renewal option.
#### Steps to replicate
* On a demo site, change the "General" membership type to Auto-Renew required (reduce its membership term to 1 year also).
* Create a new price set with a single price field of type "Select".
* Provide both the General and Student options.
* Enable the price set on the membership contribution page, and enable "Pay Later".
* Select Student (which is *not* auto-renew), select "Pay Later", and attempt to submit.
I'm going to try to work on a fix, but I suspect #28871 or #28872 (or both) are the proximate cause. @eileen if something jumps out at you, let me know.5.70.0https://lab.civicrm.org/dev/core/-/issues/4962Resource URLs page doesn't load with Smarty32024-02-08T09:56:27ZJonGoldResource URLs page doesn't load with Smarty3Replicable on dmaster (and 5.69) by going to **Administer » System Settings » Resource URLs**.
Screen comes up mostly blank. This shows up in the PHP log.
```
PHP Warning: Undefined property: CRM_Admin_Form_Setting_Url::$_id in /home...Replicable on dmaster (and 5.69) by going to **Administer » System Settings » Resource URLs**.
Screen comes up mostly blank. This shows up in the PHP log.
```
PHP Warning: Undefined property: CRM_Admin_Form_Setting_Url::$_id in /home/jon/local/mysite/web/wp-content/plugins/civicrm/civicrm/CRM/Core/Form.php on line 2087"
PHP message: PHP Fatal error: Type of SmartyCompilerException::$line must be int (as in class Exception) in /home/jon/local/mysite/web/wp-content/plugins/civicrm/civicrm/packages/smarty3/vendor/smarty/smarty/libs/sysplugins/smartycompilerexception.php on line 8"
```5.69.5https://lab.civicrm.org/dev/core/-/issues/4961SearchKit/API4: 'getFieldValue failed' error for group contacts2024-02-02T22:16:09Zaydunsaidan.saunders@squiffle.ukSearchKit/API4: 'getFieldValue failed' error for group contactsOverview
----------------------------------------
SearchKit/API4 fails with 'getFieldValue failed'
Reproduction steps
----------------------------------------
1. Create a new SearchKit search
1. Set 'Search for' to 'Groups'
1. Search a...Overview
----------------------------------------
SearchKit/API4 fails with 'getFieldValue failed'
Reproduction steps
----------------------------------------
1. Create a new SearchKit search
1. Set 'Search for' to 'Groups'
1. Search and confirm groups are shown
2. Add 'With (optional)' 'Group Contacts'
3. Search and observe no results
4. Open browser tools, search again, note '500':
Request is:
{"run":["SearchDisplay","run",{"return":"page:1","savedSearch":{"api_entity":"Group","displays":[],"groups":[],"tag_id":[],"api_params":{"version":4,"select":["id","title","description","is_active","Group_GroupContact_Contact_01.sort_name"],"orderBy":{},"where":[],"groupBy":[],"join":[["Contact+AS+Group_GroupContact_Contact_01","LEFT","GroupContact",["id","=","Group_GroupContact_Contact_01.group_id"]]],"having":[]},"label":"Group+Search+by+demo@example.com"},"sort":[],"limit":50,"seed":1706887602244,"filters":{},"afform":null,"debug":true}]}
Response is:
{
"run": {
"error_code": 0,
"error_message": "getFieldValue failed",
"status": 500
}
}
Environment information
----------------------------------------
* __CiviCRM:__ _Master_
Comments
----------------------------------------
This is currently failing on dmaster but works correctly on 5.65.0
Might be wider issue, but noted on groups.https://lab.civicrm.org/dev/core/-/issues/4960Regression: 5.70 active relationships not loading when Civi Case not enabled2024-02-03T02:54:13ZElliott EgglestonRegression: 5.70 active relationships not loading when Civi Case not enabledDisable CiviCase and navigate to a summary screen contact with relationships. In the tab list the Relationships tab is missing the count that shows up when CiviCase is enabled. If you click onto the tab you see the disabled relationships...Disable CiviCase and navigate to a summary screen contact with relationships. In the tab list the Relationships tab is missing the count that shows up when CiviCase is enabled. If you click onto the tab you see the disabled relationships but no enabled relationships load.
In the browser console you can see the following:
Post to https://dmaster.localhost:32353/civicrm/ajax/api4
with payload '{"run":["SearchDisplay","run",{"return":"page:1","savedSearch":"Contact_Summary_Relationships","display":"Contact_Summary_Relationships_Active","sort":{},"limit":50,"seed":1706885943746,"filters":{"near_contact_id":161,"is_current":true},"afform":"afsearchTabRel"}]}'
Comes back with 500 error
Object { error_code: 0, error_message: "API (Case, getLinks) does not exist (or the extension it belongs to is not enabled).", status: 500 }5.70.0https://lab.civicrm.org/dev/core/-/issues/4959After upgrading from 5.63. to 5.69, two scheduled jobs fail with: Failure, Er...2024-02-20T23:15:44ZjamieAfter upgrading from 5.63. to 5.69, two scheduled jobs fail with: Failure, Error message: Unknown api versionThe two failing jobs are:
- job.update_greeting
- mailing.update_mailing_resetdate
Both of these jobs have parameters entered in the job itself (which may be a clue). And, with both, I "fixed" them by adding:
version=3
To the list of...The two failing jobs are:
- job.update_greeting
- mailing.update_mailing_resetdate
Both of these jobs have parameters entered in the job itself (which may be a clue). And, with both, I "fixed" them by adding:
version=3
To the list of parameters already set.
I flailed around in `CRM/Core/JobManager.php` and found [an unset $temp variable](https://github.com/civicrm/civicrm-core/blob/6b7d77047024f4989d8fb2c9219d5ddf7e7161d0/CRM/Core/JobManager.php#L184) but was otherwise unable to figure out how to fix this problem.
Also, maybe not a bug and I should be adding this parameter? Or should the upgrader warn about adding this parameter? Or did I miss it? Thanks in advance for any clues.colemanwcolemanw