Development issueshttps://lab.civicrm.org/groups/dev/-/issues2023-01-05T02:18:09Zhttps://lab.civicrm.org/dev/core/-/issues/4022PHP 7.4, 8+ TypeError: array_flip(): Argument #1 ($array) must be of type arr...2023-01-05T02:18:09ZeldonthianPHP 7.4, 8+ TypeError: array_flip(): Argument #1 ($array) must be of type array, string givenOverview
----------------------------------------
Fresh install seemed to work, after going through checklist and setting up preferences,
somehow the search preferences page now throws this error. not sure what the exact cause is.
http...Overview
----------------------------------------
Fresh install seemed to work, after going through checklist and setting up preferences,
somehow the search preferences page now throws this error. not sure what the exact cause is.
https://civicrm.stackexchange.com/q/43060/14046
Reproduction steps
----------------------------------------
This seems to come up whenever ANY of the options are changed and attempting to save on search preferences page. i.e., custom fields, search options or quick search fields selection/deselection, reorder, etc.
Current behaviour
----------------------------------------
upon saving any changes on the search preferences page.
go back to the page, all ordering gone, default fields only, and selections.. just click save, and things begin to work as first install. Can not select/deselect any field to be saved. new selections are not saved..
```
TypeError: array_flip(): Argument #1 ($array) must be of type array, string given in /code/vendor/civicrm/civicrm-core/CRM/Admin/Form/SettingTrait.php on line 380 #0 /code/vendor/civicrm/civicrm-core/CRM/Admin/Form/SettingTrait.php(380): array_flip('\x01sort_name\x01cont...')
#1 /code/vendor/civicrm/civicrm-core/CRM/Admin/Form/SettingTrait.php(224): CRM_Admin_Form_Setting::reorderSortableOptions('quicksearch_opt...', Array)
#2 /code/vendor/civicrm/civicrm-core/CRM/Admin/Form/Setting.php(66): CRM_Admin_Form_Setting->addFieldsDefinedInSettingsMetadata()
#3 /code/vendor/civicrm/civicrm-core/CRM/Admin/Form/Setting/Search.php(47): CRM_Admin_Form_Setting->buildQuickForm()
#4 /code/vendor/civicrm/civicrm-core/CRM/Core/Form.php(689): CRM_Admin_Form_Setting_Search->buildQuickForm()
#5 /code/vendor/civicrm/civicrm-core/CRM/Core/QuickForm/Action/Display.php(76): CRM_Core_Form->buildForm()
#6 /code/vendor/civicrm/civicrm-packages/HTML/QuickForm/Controller.php(203): CRM_Core_QuickForm_Action_Display->perform(Object(CRM_Admin_Form_Setting_Search), 'display')
#7 /code/vendor/civicrm/civicrm-packages/HTML/QuickForm/Page.php(103): HTML_QuickForm_Controller->handle(Object(CRM_Admin_Form_Setting_Search), 'display')
#8 /code/vendor/civicrm/civicrm-core/CRM/Core/Controller.php(355): HTML_QuickForm_Page->handle('display')
#9 /code/vendor/civicrm/civicrm-core/CRM/Utils/Wrapper.php(98): CRM_Core_Controller->run()
#10 /code/vendor/civicrm/civicrm-core/CRM/Core/Invoke.php(292): CRM_Utils_Wrapper->run('CRM_Admin_Form_...', 'Search Preferen...', Array)
#11 /code/vendor/civicrm/civicrm-core/CRM/Core/Invoke.php(69): CRM_Core_Invoke::runItem(Array)
#12 /code/vendor/civicrm/civicrm-core/CRM/Core/Invoke.php(36): CRM_Core_Invoke::_invoke(Array)
#13 /code/web/modules/contrib/civicrm/src/Civicrm.php(88): CRM_Core_Invoke::invoke(Array)
#14 /code/web/modules/contrib/civicrm/src/Controller/CivicrmController.php(80): Drupal\civicrm\Civicrm->invoke(Array)
#15 [internal function]: Drupal\civicrm\Controller\CivicrmController->main(Array, '')
#16 /code/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(123): call_user_func_array(Array, Array)
#17 /code/web/core/lib/Drupal/Core/Render/Renderer.php(564): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}()
#18 /code/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(124): Drupal\Core\Render\Renderer->executeInRenderContext(Object(Drupal\Core\Render\RenderContext), Object(Closure))
#19 /code/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(97): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext(Array, Array)
#20 /code/vendor/symfony/http-kernel/HttpKernel.php(169): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}()
#21 /code/vendor/symfony/http-kernel/HttpKernel.php(81): Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object(Symfony\Component\HttpFoundation\Request), 1)
#22 /code/web/core/lib/Drupal/Core/StackMiddleware/Session.php(58): Symfony\Component\HttpKernel\HttpKernel->handle(Object(Symfony\Component\HttpFoundation\Request), 1, true)
#23 /code/web/core/lib/Drupal/Core/StackMiddleware/KernelPreHandle.php(48): Drupal\Core\StackMiddleware\Session->handle(Object(Symfony\Component\HttpFoundation\Request), 1, true)
#24 /code/web/core/modules/page_cache/src/StackMiddleware/PageCache.php(106): Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object(Symfony\Component\HttpFoundation\Request), 1, true)
#25 /code/web/core/modules/page_cache/src/StackMiddleware/PageCache.php(85): Drupal\page_cache\StackMiddleware\PageCache->pass(Object(Symfony\Component\HttpFoundation\Request), 1, true)
#26 /code/web/core/lib/Drupal/Core/StackMiddleware/ReverseProxyMiddleware.php(48): Drupal\page_cache\StackMiddleware\PageCache->handle(Object(Symfony\Component\HttpFoundation\Request), 1, true)
#27 /code/web/core/lib/Drupal/Core/StackMiddleware/NegotiationMiddleware.php(51): Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object(Symfony\Component\HttpFoundation\Request), 1, true)
#28 /code/vendor/stack/builder/src/Stack/StackedHttpKernel.php(23): Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object(Symfony\Component\HttpFoundation\Request), 1, true)
#29 /code/web/core/lib/Drupal/Core/DrupalKernel.php(709): Stack\StackedHttpKernel->handle(Object(Symfony\Component\HttpFoundation\Request), 1, true)
#30 /code/web/index.php(19): Drupal\Core\DrupalKernel->handle(Object(Symfony\Component\HttpFoundation\Request))
#31 {main}
```
Expected behaviour
----------------------------------------
Search preferences should be able to be saved with changes.. and accessible at
civicrm/admin/setting/search?reset=1
Environment information
----------------------------------------
* __CiviCRM: 5.55.2, 5.56
* __PHP: 7.4, 8.0, 8.1
* __CMS: Drupal 9.4.8
* __Database: MariaDB 10.4.25
* __Web Server: nginx/1.21.65.57.0https://lab.civicrm.org/dev/core/-/issues/4018Extension upgrades are not run if there are no core upgrades2022-12-02T12:24:19ZherbdoolExtension upgrades are not run if there are no core upgrades@totten recently did: https://github.com/civicrm/civicrm-core/pull/24030 to include extension upgrades in the core upgrades.
I've noticed a couple times, however, that there seem to be extension upgrades still waiting after upgrading Ci...@totten recently did: https://github.com/civicrm/civicrm-core/pull/24030 to include extension upgrades in the core upgrades.
I've noticed a couple times, however, that there seem to be extension upgrades still waiting after upgrading CiviCRM code base and running `cv upgrade:db`. Could it be that if there are no core upgrade hooks waiting that it won't run the extension upgrades? It does seem likely given my chat with @colemanw https://chat.civicrm.org/civicrm/pl/cfd18cjpofg5iesh7o4zqejcbh.https://lab.civicrm.org/dev/core/-/issues/4004Fatal error in a Scheduled Job should not prevent other jobs runs from happening2022-11-30T08:31:30ZMichael McAndrewFatal error in a Scheduled Job should not prevent other jobs runs from happeningTake the example of a typical site with ~10 cron jobs configured to run every 5 minutes. The jobs are always run in the same order.
If job 3 exits with a fatal error, the following jobs will not run so a single failing job can cause ma...Take the example of a typical site with ~10 cron jobs configured to run every 5 minutes. The jobs are always run in the same order.
If job 3 exits with a fatal error, the following jobs will not run so a single failing job can cause many others to also 'fail' even if there is nothing wrong with them.
I don't think you can catch Fatal errors but wondering if there is another approach we can take (using sub processes or similar?) that will make our cron more resilient to failure within a specific job.https://lab.civicrm.org/dev/core/-/issues/3990force deduplication for event registrations: misleading help text → change su...2022-11-17T07:23:57ZAndreasandreas.howiller@civiservice.deforce deduplication for event registrations: misleading help text → change suggested workaround or add feature to CiviEvent?Sometimes you want to intentionally force duplicates for anonymous registrations for certain events. Some users even want this as their default in CiviEvent.
In the profile configuration there is the following hint how you should do th...Sometimes you want to intentionally force duplicates for anonymous registrations for certain events. Some users even want this as their default in CiviEvent.
In the profile configuration there is the following hint how you should do this:
> If you are using the profile as a contact signup and editing form - this option controls what happens if the data matches an existing contact record. Using this option user can update the matching record or create a duplicate record or otherwise he will get a 'duplicate record' warning, and their input will not be saved. Contact matching is based on your configured 'Strict' rule for identifying duplicate contacts. (Weiterlesen...)
>
> This setting is ignored if the profile is embedded in an online contribution, membership signup or event registration form. In this case a contact match always results in the transaction being linked to the matching contact.
>
> In all cases, the check for an existing matching contact uses the default "Individual Strict Duplicate Matching Rule" (match on email address). If you are concerned with existing contact data being over-written by anonymous visitors, you can modify this rule to make matches less likely (or even impossible). For example, if you NEVER want anonymous input to match (i.e. always create a new contact record) - edit that rule and set the 'weight threshold' higher than 10. You will then need to run Find Duplicates periodically using a different rule, and merge any duplicate records with their associated memberships, contributions, etc.
However, this kind of "suggested workaround" no longer works because you can no longer specify an unreachable threshold in the deduplication rules. In any case, the help text would have to be adapted.
However, the question arises how to deal with the actual requirement and I see at least two possibilities:
**Option A: Replacing the workaround**
Recommend in the help text to create an unachievable deduplication rule by using in the rule a field that is never used in the user's event registrations and advice them to set this rule for registrations when needed.
**Option B: add a feature in CiviEvent**
Add a "no deduplication" feature (like there is an option to deactivate deduplication in profiles) and add this option to the duplicate rule dropdown in the event configuration.
Any (other) ideas?https://lab.civicrm.org/dev/core/-/issues/3980SearchKit displays: be able to add description so end user knows the context2022-11-21T19:39:52ZherbdoolSearchKit displays: be able to add description so end user knows the contextCurrently on SearchKit displays we can set the name which ends up being used for the title and the URL. I've tried to add additional information there for end users so they understand the context of the results. E.g. "Only shows results ...Currently on SearchKit displays we can set the name which ends up being used for the title and the URL. I've tried to add additional information there for end users so they understand the context of the results. E.g. "Only shows results for the current campaign". But that's awkward to stuff that all into the title. And also means one has to be careful that on the first save *not* to add those notes to the name so as to prevent an ungainly URL.
(The other option is to embed the SK into an afform, but that's a lot of extra work for just a bit of description.)
So a separate description field would be ideal.https://lab.civicrm.org/dev/core/-/issues/3972SearchKit: allow custom fields to be used in the JOIN conditions (like they'r...2023-03-29T15:54:36ZherbdoolSearchKit: allow custom fields to be used in the JOIN conditions (like they're available in where)As far as I can tell, the custom fields on the entity that is joined are not available for the JOIN conditions. But they are visible in the WHERE.
Here's a scenario: there's a custom field on a contact. Create a new SearchKit with prima...As far as I can tell, the custom fields on the entity that is joined are not available for the JOIN conditions. But they are visible in the WHERE.
Here's a scenario: there's a custom field on a contact. Create a new SearchKit with primary being Address. Then JOIN the Contact. Add a condition for the join and search the contact's custom field. It's not available. Then check for that same custom field in the WHERE - it should be available.
This is useful when using GROUP BY and cannot use the WHERE. And where it would be inconvenient/impossible to add the field as a column and use HAVING. For example, if the added field has a transformation to COUNT then HAVING won't help.https://lab.civicrm.org/dev/release/-/issues/19ESR Workflow: Post full suite of resources at start of cycle2023-01-13T18:46:04ZtottenESR Workflow: Post full suite of resources at start of cycleBackground / Motivation
-----------------------
Every 6 months, we designate a version for extended security support. When there's a new security release, the ESR version is posted to Gitlab (`esr/core`, `esr/packages`, `esr/drupal-8`, ...Background / Motivation
-----------------------
Every 6 months, we designate a version for extended security support. When there's a new security release, the ESR version is posted to Gitlab (`esr/core`, `esr/packages`, `esr/drupal-8`, and so on -- collectively, the `esr/*` projects).
If you are sysadmin who wants to be _prepared_ for future security updates, then you would look to `esr/*` and do a trial-run. Make sure you have access/credentials. Make sure you can find the spot for the releases. Make sure you're targeting the right version. Make sure your tools (like `composer`) are configured to pull from there.
However, if there hasn't been a security release, then there may not be anything published on `esr/*`. This interim period invites some confusion. On one hand, there's no security-release to publish -- so the regular security-release scripts don't apply. On the other hand, if you want to be ready, then you need something to look at. The result is that we improvise during the interim.
Goal
----
Whenever we start new ESR cycle, immediately publish to `esr/*`. Include sufficient resources that enable the sysadmins to do a "dress rehearsal" (downloading/install using the exact same procedure as for a security fix). For example, suppose we're discussing v5.51 which started its extended support circa Aug 3. Here are some materials that you might expect to find (circa Aug 3):
* In the main repo, the tarballs for the `5.51.x` releases
* In each repo, the branch (`5.51-esr`).
* In each repo, the tags for specific patch releases (`5.51.x` or `5.51.x+esr`).
* In each repo, package-registry entries for each release (`5.51.x` or `5.51.x+esr`).
* In the main repo, links for the documentation interim changes (release announcements/notes for 5.51, 5.50, 5.49, 5.48, 5.47, 5.46)
Questions
----------
Are there other resources that you expect in this period?
If 5.51 starts public-support in July and starts extended-support in August... then... when should 5.51 become available in `esr/*`? Start of July? Start of August?
(If 5.51 is published to `esr/*` in July, then it will overlap with the tail-end of 5.45. Would it be confusing to see both during July?)https://lab.civicrm.org/dev/core/-/issues/3961Proposal: Create stub extensions for civicrm core + all components2023-07-13T10:41:05ZcolemanwProposal: Create stub extensions for civicrm core + all components*Edited to reflect the current state of things, some comments reply to an earlier revision*
**Motivation 1:**
Require SearchKit in core. This has been [solved in a different way](https://github.com/civicrm/civicrm-core/pull/24739) so i...*Edited to reflect the current state of things, some comments reply to an earlier revision*
**Motivation 1:**
Require SearchKit in core. This has been [solved in a different way](https://github.com/civicrm/civicrm-core/pull/24739) so is no longer relevant to this issue.
**Motivation 2**
We are starting to package SearchKit displays as replacements for Smarty/DataTables in the UI. This has worked out great for CiviGrant: now that it's an extension we can easily package Afforms, SavedSearches and other managed entities with it. But other components are not extensions and so have no mechanism for including their own managed entities, afforms, etc. Components are less modular and more monolithic than extensions.
**Motivation 3**
Currently an extension has no way to require a component, e.g. an extension cannot declare a dependency on CiviEvent.
**Motivation 4**
Extensions and Components are similar but not the same, and this is confusing to new users and new developers. In most respects Extensions are better than Components, and it would be great to "some day" have all components simply be extensions.
**Proposal**
Given the experience of converting CiviGrant to an extension was a "harder than expected" undertaking, I think converting all other components to extensions at once is not a realistic goal. It would need to be a slow, iterative process, and I propose this as the first iteration:
1. Create a small stub extension for each component (CiviEvent, CiviContribute, etc).
2. Use hooks to sync between the `civicrm_extension` table and the `civicrm_component` table, so that enabling the "CiviEvent" extension also enables the "CiviEvent" component, and vice-versa.
3. Get rid of the "Manage Components" screen. Admins can enable/disable components via the "Manage Extensions" screen.https://lab.civicrm.org/dev/core/-/issues/3955Add show spaces remaining setting for price set fields2023-05-30T22:23:49ZlarsssandergreenAdd show spaces remaining setting for price set fieldsWith multiple participant registrations and price set options with registration limits, the fact that registrants can't see how many spaces are remaining in a specific option can cause a lot of frustration. What happens is Bob wants to r...With multiple participant registrations and price set options with registration limits, the fact that registrants can't see how many spaces are remaining in a specific option can cause a lot of frustration. What happens is Bob wants to register his family of four for a workshop that only has space remaining for three people. He fills out his details, selects the workshop, fills out his 2nd and 3rd family members' details and selects the workshop for them and only when he arrives on the 4th family members' registration page does he find out there aren't actually enough spaces in the workshop for his family. So he goes back to the start, changes the workshop to another one for each family member one by one, only to find out that the substitute workshop only has space for two... Cue frustration and annoyed emails or, even worse, Bob gives up and doesn't register at all.
To prevent this issue, I propose to add an option to price fields called "Show spaces remaining", which would only be shown when the price set is used for event registration. When this is enabled, each price option will include "(N left)" at the end of the option label, where the (Sold out) text would go, e.g. Identifying pinecones - $ 5.00 (4 left). Of course, this won't be shown for sold out options or options with no limit.
On the backend only, this will also be shown for oversubscribed options (N over limit), replacing (Sold out).
With the recent work I've done to simplify the process of building the [price set option labels](https://github.com/civicrm/civicrm-core/pull/24639), this will be much more easily accomplished.https://lab.civicrm.org/dev/core/-/issues/3950SearchKit: Campaign search doesn't work correctly2022-11-16T20:07:08ZlarsssandergreenSearchKit: Campaign search doesn't work correctlyIf you search for a contribution or a participant by campaign in SK, there are two options: Campaign Campaign Title and Campaign ID. If you search by Campaign Campaign Title, you can enter the campaign title by typing it in manually, but...If you search for a contribution or a participant by campaign in SK, there are two options: Campaign Campaign Title and Campaign ID. If you search by Campaign Campaign Title, you can enter the campaign title by typing it in manually, but there is no autocomplete. If you search by Campaign ID, then there is autocomplete, but the search does not actually work (shows no results because it is doing campaign_id:name when it should be doing campaign_id).
I think there should be just one Campaign search option, with autocomplete that also shows you the most recent active campaigns in the select for quickly picking a recent campaign.
Tested on dmaster (5.56).https://lab.civicrm.org/dev/core/-/issues/3946Improve default email greeting template2022-11-02T00:38:44ZeileenImprove default email greeting templateThe default greeting template that ships with Core is `Dear {contact.first_name}`
For contacts with no first name it looks like this
![image](/uploads/5484e666daa2e9eabb452b7dfb139704/image.png)
I propose changing it to `Dear {if '{...The default greeting template that ships with Core is `Dear {contact.first_name}`
For contacts with no first name it looks like this
![image](/uploads/5484e666daa2e9eabb452b7dfb139704/image.png)
I propose changing it to `Dear {if '{contact.first_name}'}{contact.first_name}{else}Supporter{/if}`
Which winds up like
![image](/uploads/35017aef6768ebc972b66b003e92bf0c/image.png)
Notes
- this is an English only change - but presumably non-English sites will see no change since there is either a customised version they are getting already or they are already getting the inappropriate 'Dear' & hence not using it
- the choice of word 'Supporter' - could be argued (Donor, Friend etc) - but I think if there is 'something' there then it will allow people to pick their own
- in workflow messages we currently use the field in this way
` {assign var="greeting" value="{contact.email_greeting_display}"}{if $greeting}<p>{$greeting},</p>{/if}` - would would result in the offensive 'Dear,'
- We already parse the greetings through Smarty so no change required there & because we use the `parseOneOffStringThroughSmarty` function smarty runs with higher security https://github.com/civicrm/civicrm-core/blob/95649f7c98ae3c384553f9958ebaf9caa03eb4a6/CRM/Core/Smarty.php#L183-L187
![image](/uploads/0d725992033a68ec25728e0e7e1e8814/image.png)
- The outstanding question is the impact on performance - which is what I will be testing next...https://lab.civicrm.org/dev/core/-/issues/3945SearchKit - make reordering columns easier2022-10-26T18:51:05ZsamuelsovSearchKit - make reordering columns easierIn SearchKit, more and more options are made available for fields. This is a good thing but it becomes more difficult to reorder the fields using drag & drop if the fields definition takes most of the screen :
(totally fake example but ...In SearchKit, more and more options are made available for fields. This is a good thing but it becomes more difficult to reorder the fields using drag & drop if the fields definition takes most of the screen :
(totally fake example but I have some real examples that takes a lot of space)
![Screenshot_2022-10-26_at_09-37-38_Contacts_CRM_de_la_Coop_SymbioTIC](/uploads/7a66a72c0fab195450bd0dd04940331c/Screenshot_2022-10-26_at_09-37-38_Contacts_CRM_de_la_Coop_SymbioTIC.png)
I can imagine 2 options to improve this :
1. have the content of the fields definition be a collapsible and add [collapse all] / [open all] buttons
1. make the ordering separate from the columns definitions, i.e. something like :
![Screenshot_2022-10-26_at_09-24-56_Contacts_CRM_de_la_Coop_SymbioTIC](/uploads/3d1a3692bd7cde1db996bea55fe80554/Screenshot_2022-10-26_at_09-24-56_Contacts_CRM_de_la_Coop_SymbioTIC.png)https://lab.civicrm.org/dev/core/-/issues/3943Searching for Current Member = No returns contacts who are current members if...2022-10-28T20:05:12ZlarsssandergreenSearching for Current Member = No returns contacts who are current members if they also have a non-current membershipIf you search in Advanced Search or Find Memberships with Current Member = No, you will get all contacts who have a membership which is not current. This is not the same as saying they aren't a current member, because the contact could h...If you search in Advanced Search or Find Memberships with Current Member = No, you will get all contacts who have a membership which is not current. This is not the same as saying they aren't a current member, because the contact could have another membership which is current. This is probably quite common as many contacts will buy a new membership instead of renewing their past membership.
In the case that a contact has, for example, one expired membership and one current membership, they will be found when searching for Current Member = No and also for Current Member = Yes. Confusing!https://lab.civicrm.org/dev/core/-/issues/3942Fatal Error in PHP 8.0 when passing an empty array to a custom checkboxes/sel...2023-01-29T06:17:46ZherbdoolFatal Error in PHP 8.0 when passing an empty array to a custom checkboxes/select field.When passing an empty array to a custom Checkboxes (or Select) field, under PHP 8.0 it gives a fatal error: `TypeError: mysqli_real_escape_string(): Argument #2 ($string) must be of type string, array given in mysqli_real_escape_string()...When passing an empty array to a custom Checkboxes (or Select) field, under PHP 8.0 it gives a fatal error: `TypeError: mysqli_real_escape_string(): Argument #2 ($string) must be of type string, array given in mysqli_real_escape_string() (line 880 of /app/vendor/pear/db/DB/mysqli.php).` There is no error in PHP 7.4.
Using CiviCRM 5.54.0.
For example:
```
$results = Address::update()
->addValue(Address_status.Fruit, [])
->addWhere('id', '=', 1)
->execture();
```
Where Address_status is the custom field group and Fruit is the checkboxes or select field with options.
I am assuming that either the error should be caught earlier by API4 or DAO and warn that empty arrays cannot be passed to this field type, or that it doesn't complain at all and converts the empty array to a serialized string, much like it does with populated arrays.https://lab.civicrm.org/dev/core/-/issues/3915Event registration sequence weirdness2022-10-20T07:36:12Zaydunsaidan.saunders@squiffle.ukEvent registration sequence weirdnessDocumenting some discussion at the #ManchesterSprint
We have a weird sequence in the event registration workflow whereby customers pay for the event before the total amount is determined. This causes a variety of problems:
- Customers ...Documenting some discussion at the #ManchesterSprint
We have a weird sequence in the event registration workflow whereby customers pay for the event before the total amount is determined. This causes a variety of problems:
- Customers are asked to pay before making choices which is contrary to almost any other payment workflow and therefore confuses customers.
- Payment processors (eg Stripe) need to jump through hoops to make this work which complicates the code and causes more opportunities for failure.
- Customers may be asked by their bank to confirm a payment of zero which is later updated. Those customers who read the amount assume something is broken.
Changing the registration sequence to put payment at the end would resolve all these problems, and nobody (so far) thinks the current arrangement is desirable.
Fyi @mattwirehttps://lab.civicrm.org/dev/wordpress/-/issues/131CIviCRM is incompatible with WordPress "Block Themes" because Javascript is b...2024-01-23T17:05:21ZtcmallocCIviCRM is incompatible with WordPress "Block Themes" because Javascript is broken by `wptexturize()`Certain components (in my case civicrm) embed some inline js into form templates, however some part of wordpress or civicrm picks this up and tries to html escape the content, meaning any code snippet using AND (`&&`) will not work.
The...Certain components (in my case civicrm) embed some inline js into form templates, however some part of wordpress or civicrm picks this up and tries to html escape the content, meaning any code snippet using AND (`&&`) will not work.
The specific bug we ran into was with CiviContribute: when allow other amounts is ticked the code
```js
// Putting these functions directly in template so they are available for standalone forms
function useAmountOther() {
var priceset = 'price_2';
for( i=0; i < document.Main.elements.length; i++ ) {
element = document.Main.elements[i];
if ( element.type == 'radio' && element.name == priceset ) {
```
has the last line turned into `if ( element.type == 'radio' && element.name == priceset ) {`, meaning the whole snippet fails to load and so selecting/clearing the other amount field doesn't work properly.
I cannot recreate this on the wordpress demo site, as it uses caldera forms. Our workaround was to embed the JS snippet to the bottom of the CiviCrm page, however this is not ideal.
Wordpress 6.0.2, CiviCRM 5.53.0https://lab.civicrm.org/dev/core/-/issues/3913[Improvement] Ability to send only one single email confirmation after sign-u...2022-10-20T07:43:32ZJanOnline[Improvement] Ability to send only one single email confirmation after sign-up to several mailing listsOverview
----------------------------------------
CiviCRM allows people to sign up to several mailing lists / groups at once via `civicrm/mailing/subscribe`. Then they receive numerous confirmation emails to double opt-in. In our experie...Overview
----------------------------------------
CiviCRM allows people to sign up to several mailing lists / groups at once via `civicrm/mailing/subscribe`. Then they receive numerous confirmation emails to double opt-in. In our experience, since those emails all look very similar, many people mistake them for being the same; hence they click and confirm in one but not the others. As a result, you end up with many "pending" sign-ups (we have 10,000+ by now).
Example use-case
----------------------------------------
1. Create several mailing list groups
2. Go to `civicrm/mailing/subscribe` and sign up to more than one list
3. Receive several similar looking confirmation emails
4. Confirm only one and find yourself being subscribed to only one of the list you actually wanted to be on
Proposed behaviour
----------------------------------------
To remedy this situation, CiviCRM could give admins the option of whether CiviCRM should send a single double opt-in email for every sign-up event instead of individual ones per mailing list in order to avoid confusing people when signing up.https://lab.civicrm.org/dev/core/-/issues/3907Proposal: When excluding past mailing recipients, exclude past recipient emai...2022-10-21T07:27:20ZlarsssandergreenProposal: When excluding past mailing recipients, exclude past recipient email addresses, not just contactsSometimes, you want to send a few different versions of a mailing, so you segment your list and send different versions to different groups or to search results. Of course, you want to make sure no one receives two different versions of ...Sometimes, you want to send a few different versions of a mailing, so you segment your list and send different versions to different groups or to search results. Of course, you want to make sure no one receives two different versions of the same email, so you make sure to exclude the earlier mailings from the later ones. But if two contacts share an email address, one can receive the first mailing and the other the second mailing. Excluding recipients of the first mailing only excludes contacts who received the first mailing, not email addresses that received the first mailing.
Similarly, you might send a mailing, only to have someone realize a mistake was made when half the emails have been delivered. You cancel the mailing, make a copy and fix the error and then send the mailing to the same group minus the recipients of the first mailing. This doesn't work at all, because the _intended_ recipients of the excluded mailing are excluded, not the _actual_ recipients. But if we get past that problem, we'd also run into the same problem as above.
I propose that to fix this, when the dedupe emails setting is enabled in CiviMail, we do an additional check to see if any of the excluded contacts' primary/bulk email address is also used by a contact in the included list, then exclude those recipients as well. I'll need to look at the details of this to make sure performance isn't an issue. If someone wants multiple emails sent to the same address for multiple contacts, they would have the dedupe setting in Civimail turned off, so this change wouldn't affect them. Otherwise, I think this is line with what users would expect.
Also, when recipients of a mailing are excluded, we should check if the excluded mailing status is cancelled. If it is cancelled, then we should only exclude the actual recipients rather than the intended recipients. I think users would also expect excluding recipients of a mailing would exclude the actual recipients, rather than the intended recipients.https://lab.civicrm.org/dev/core/-/issues/3897Form Builder: 'Show totals in footer' doesn't work with multiple displays on ...2023-12-30T21:10:37ZAndrew WestForm Builder: 'Show totals in footer' doesn't work with multiple displays on a formOverview
----------------------------------------
Total rows don't work when there are multiple displays on a single form, each containing a total row. It seems to calculate a single value and show it for all displays. No console errors....Overview
----------------------------------------
Total rows don't work when there are multiple displays on a single form, each containing a total row. It seems to calculate a single value and show it for all displays. No console errors.
Reproduction steps
----------------------------------------
1. Create 2 search displays with totals ([Example 1](https://wpmaster.demo.civicrm.org/wp-admin/admin.php?page=CiviCRM&q=civicrm%2Fadmin%2Fsearch#/create/Contact?params=%7B%22version%22:4,%22select%22:%5B%22id%22,%22display_name%22%5D,%22orderBy%22:%5B%5D,%22where%22:%5B%5B%22contact_type:name%22,%22%3D%22,%22Individual%22%5D,%5B%22age_years%22,%22IS%20EMPTY%22%5D%5D,%22groupBy%22:%5B%5D,%22join%22:%5B%5D,%22having%22:%5B%5D%7D), [Example 2](https://wpmaster.demo.civicrm.org/wp-admin/admin.php?page=CiviCRM&q=civicrm%2Fadmin%2Fsearch#/create/Contact?params=%7B%22version%22:4,%22select%22:%5B%22id%22,%22display_name%22%5D,%22orderBy%22:%5B%5D,%22where%22:%5B%5B%22age_years%22,%22%3E%22,5%5D%5D,%22groupBy%22:%5B%5D,%22join%22:%5B%5D,%22having%22:%5B%5D%7D)).
2. Create Table displays for them both, making sure to tick 'Show totals in footer'
3. Add them both to a form
[Here's an example](https://wpmaster.demo.civicrm.org/wp-admin/admin.php?page=CiviCRM&q=civicrm%2Ftest%2Ftotals) - at least until the WP database resets.
Environment information
----------------------------------------
Tested on WP master.colemanwcolemanwhttps://lab.civicrm.org/dev/core/-/issues/3891Show ical and Google Calendar links for non-public events2022-10-25T11:50:06ZlarsssandergreenShow ical and Google Calendar links for non-public eventsCurrently, the Download iCalendar entry for this event and Add event to Google Calendar links only appear in event confirmation emails, on the event confirmation page and on the event info page if the event is public.
But if someone has...Currently, the Download iCalendar entry for this event and Add event to Google Calendar links only appear in event confirmation emails, on the event confirmation page and on the event info page if the event is public.
But if someone has registered for an event, they should be able to add that event to their calendar regardless of whether it is public or not. The event info page can also include these links as the calendar links contain the same information as is already found on the page.
For reference, the help text for Public Event says: "When enabled, this event will be included in iCalendar feeds and displayed on your site's "Upcoming Events" block." So there shouldn't be any expectation that we're hiding calendar links for non-public events as this settings controls only calendar _feeds_. Can't see any reason we'd want to hide calendar links, in any case.
Turns out the links fail when the event is non-public, so I'll have to fix that first.