Development issueshttps://lab.civicrm.org/groups/dev/-/issues2023-10-26T11:44:33Zhttps://lab.civicrm.org/dev/core/-/issues/4728Form Builder Issue: Filter for "Contact (Near Side) / Contact (Far Side)" not...2023-10-26T11:44:33ZTobias Voigttobias.voigt@civiservice.deForm Builder Issue: Filter for "Contact (Near Side) / Contact (Far Side)" not workingI start with the "contacts" entity in Search Kit, then include "Contact Related Contacts" as an additonal entity and create a form in Form Builder for this composed search.
In Form Builder I then add a filter for both "Contact (Near Sid...I start with the "contacts" entity in Search Kit, then include "Contact Related Contacts" as an additonal entity and create a form in Form Builder for this composed search.
In Form Builder I then add a filter for both "Contact (Near Side)" and "Contact (Far Side)". When I then search for and choose a contact through one "Contact (Near Side)", the results table shows ALL possible results. When I search for and choose a contact through one "Contact (Far Side)", the results table is empty.
I was able to reproduce this behaviour in https://dmaster.demo.civicrm.org.
Side note: When I create a form directly for the composed search (rather than for a Search Kit table), I also get a warning: "Warning: Trying to access array offset on value of type null in Civi\Api4\Action\SearchDisplay\GetDefault->getColumnLabel() (line 418 of /srv/buildkit/build/dmaster/web/sites/all/modules/civicrm/Civi/Api4/Generic/Traits/SavedSearchInspectorTrait.php)."
Not sure if this is related to the issue or not.
If it would work, this filter would be extremely helpful and great to have.https://lab.civicrm.org/dev/core/-/issues/4727Basic/Advanced search and CiviReport filters showing `name` in tag dropdown i...2023-11-01T23:19:57ZDaveDBasic/Advanced search and CiviReport filters showing `name` in tag dropdown instead of `label`![untitled4](/uploads/ea919fe7f1f9257beb0f2c656f3efe2a/untitled4.png)
Also the QILL for the civireport (the QILL for the search is ok).
![untitled3](/uploads/ed24469c7b1110d79340b0f4b3555fb4/untitled3.png)![untitled4](/uploads/ea919fe7f1f9257beb0f2c656f3efe2a/untitled4.png)
Also the QILL for the civireport (the QILL for the search is ok).
![untitled3](/uploads/ed24469c7b1110d79340b0f4b3555fb4/untitled3.png)5.68.0https://lab.civicrm.org/dev/core/-/issues/4726On Import in Non English Mode do not import field in saved field mapping is n...2023-11-29T20:14:33ZseamusleeOn Import in Non English Mode do not import field in saved field mapping is not correctly set as default when re-using importOverview
----------------------------------------
When using import contacts for example with a saved field mapping where one of the fields is set to be marked as `do_not_import` in languages other than English this is not always set cor...Overview
----------------------------------------
When using import contacts for example with a saved field mapping where one of the fields is set to be marked as `do_not_import` in languages other than English this is not always set correctly when the MapField form is loaded as per the screenshot below showing the saving of the saved mapping field with the 2nd field as do not import but then when I go to re-use the saved mapping the mapped column does not match do not import
![save_import_map](/uploads/a652dc803fecadde0d5ec7fe0f202f58/save_import_map.jpg)
![use_import_map](/uploads/a2ae9251dbc67491276567473e4668c7/use_import_map.jpg)
Reproduction steps
----------------------------------------
1. Navigate to Administer -> localisation -> Languages ... and Set current language to be French (France)
1. Go to contacts -> Import contacts and proceed to the map field step. Create a mapping and save it making sure that one of the fields is marked as do not import
1. Repeat step 2 but this time re-use the saved mapping from before and find that the field is not mapped to the selection of do not import
ping @eileen @JoeMurray5.67.0https://lab.civicrm.org/dev/core/-/issues/4725Proposal: Don't include "I am contributing on behalf of an organization" on c...2023-11-23T07:51:08ZlarsssandergreenProposal: Don't include "I am contributing on behalf of an organization" on contribution pages when the current contact is an organizationIf an organization receives a personalized link to a contribution page, the user may not realize they are already using the form as an organization (especially because the billing details will show their first and last name if they used ...If an organization receives a personalized link to a contribution page, the user may not realize they are already using the form as an organization (especially because the billing details will show their first and last name if they used them in the past). If they then select "I am contributing on behalf of an organization", they will get a error: `Payment Processor Error message :Invalid Relationship .`
This is because we are attempting to create a new organization with an employer of relationship to the current contact, which fails when the current contact is an organization as this is not allowed.
I think the simplest and most logical way to fix this is simply to not include the on behalf of option on the contribution page if the current contact is an organization and instead show the organization profile by default. If the user wants to contribute on behalf of the current contact organization, then this is fine. If they are contributing on behalf of a different organization or as an individual, they should click the not you link.https://lab.civicrm.org/dev/core/-/issues/4724Contribution fails mid-donation with geocoding, "on behalf of", and no state/...2023-10-30T02:57:00ZJonGoldContribution fails mid-donation with geocoding, "on behalf of", and no state/provinceOverview
----------------------------------------
The "On Behalf of Organization" code causes a bug in geocoding when a state is not submitted, but other address info is present.
Reproduction steps
-------------------------------------...Overview
----------------------------------------
The "On Behalf of Organization" code causes a bug in geocoding when a state is not submitted, but other address info is present.
Reproduction steps
----------------------------------------
1. Create a contribution page that allows giving "on behalf of an organization". The Organization profile should include state/province and at least one other address field. The state/province must not be required.
2. Submit the form with an organization. Provide at least one part of the address but leave the state blank.
Current behaviour
----------------------------------------
Crashes in geocoding.
Expected behaviour
----------------------------------------
Submits successfully.
Comments
----------------------------------------
This wouldn't be such a big deal but for https://lab.civicrm.org/dev/core/-/issues/2929.
A partial backtrace is below, though there are other ways to reach this code path (e.g. if confirm pages are present/absent).
```
#0 /var/www/connect.mysite.org/vendor/civicrm/civicrm-core/CRM/Core/DAO.php(1419): strtolower()
#1 /var/www/connect.mysite.org/vendor/civicrm/civicrm-core/CRM/Utils/Geocode/Google.php(76): CRM_Core_DAO::getFieldValue()
#2 /var/www/connect.mysite.org/vendor/civicrm/civicrm-core/CRM/Core/BAO/Address.php(1287): CRM_Utils_Geocode_Google::format()
#3 /var/www/connect.mysite.org/vendor/civicrm/civicrm-core/CRM/Core/BAO/Address.php(276): CRM_Core_BAO_Address::addGeocoderData()
#4 /var/www/connect.mysite.org/vendor/civicrm/civicrm-core/CRM/Core/BAO/Address.php(1365): CRM_Core_BAO_Address::fixAddress()
#5 /var/www/connect.mysite.org/vendor/civicrm/civicrm-core/CRM/Core/BAO/Location.php(52): CRM_Core_BAO_Address::legacyCreate()
#6 /var/www/connect.mysite.org/vendor/civicrm/civicrm-core/CRM/Contact/BAO/Contact.php(327): CRM_Core_BAO_Location::create()
#7 /var/www/connect.mysite.org/vendor/civicrm/civicrm-core/CRM/Contact/BAO/Contact.php(1921): CRM_Contact_BAO_Contact::create()
#8 /var/www/connect.mysite.org/vendor/civicrm/civicrm-core/CRM/Contribute/Form/Contribution/Confirm.php(1296): CRM_Contact_BAO_Contact::createProfileContact()
#9 /var/www/connect.mysite.org/vendor/civicrm/civicrm-core/CRM/Contribute/Form/Contribution/Confirm.php(2312): CRM_Contribute_Form_Contribution_Confirm::processOnBehalfOrganization()
#10 /var/www/connect.mysite.org/vendor/civicrm/civicrm-core/CRM/Contribute/Form/Contribution/Confirm.php(836): CRM_Contribute_Form_Contribution_Confirm->processFormSubmission()
#11 /var/www/connect.mysite.org/vendor/civicrm/civicrm-core/CRM/Core/Form.php(617): CRM_Contribute_Form_Contribution_Confirm->postProcess()
#12 /var/www/connect.mysite.org/vendor/civicrm/civicrm-core/CRM/Contribute/Form/Contribution/Main.php(1318): CRM_Core_Form->mainProcess()
#13 /var/www/connect.mysite.org/vendor/civicrm/civicrm-core/CRM/Contribute/Form/Contribution/Main.php(1076): CRM_Contribute_Form_Contribution_Main->skipToThankYouPage()
```5.68.0JonGoldJonGoldhttps://lab.civicrm.org/dev/core/-/issues/4723SearchKit joins to custom fields appear to be broken2023-11-02T20:48:31ZScottMasonSearchKit joins to custom fields appear to be brokenThe latest version of SearchKit allows you to join to custom fields. However, if you try to do this and then add data to a display from the joined entity the data is not shown.
Steps to recreate.
1. Create a contact reference custom fi...The latest version of SearchKit allows you to join to custom fields. However, if you try to do this and then add data to a display from the joined entity the data is not shown.
Steps to recreate.
1. Create a contact reference custom field for activities (for example Activities details > products)
2. Create a new SK search for activities and join to the custom field
![image](/uploads/ebbeb025d909e2df4b8c87d97d7a9ada/image.png)
3. Add info from the linked entity to the display
4. The info is not shown.
![image](/uploads/870046a2cf17c723bfff75917401beb0/image.png)
I have tested this on the lastest demo site and it appears to be an issue there.
fyi @kurundhttps://lab.civicrm.org/dev/core/-/issues/4722[PHP 8.1] fseek deprecation in PHPgettext2023-12-04T21:08:50Zjofranzfranz@systopia.de[PHP 8.1] fseek deprecation in PHPgettextOverview
----------------------------------------
Noisy error on cli
Reproduction steps
----------------------------------------
Performing a cache clear on cli
Current behaviour
----------------------------------------
```[PHP Depre...Overview
----------------------------------------
Noisy error on cli
Reproduction steps
----------------------------------------
Performing a cache clear on cli
Current behaviour
----------------------------------------
```[PHP Deprecation] fseek(): Passing null to parameter #2 ($offset) of type int is deprecated at .../drupal/vendor/civicrm/civicrm-packages/PHPgettext/streams.php:125```
Expected behaviour
----------------------------------------
There should be no deprecation warnings.
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. -->
* __CiviCRM:__ _5.66.0_ <!-- If this problem relates to an upgrade, then specify both old and new versions -->
* __PHP:__ _8.1_
* __CMS:__ _Drupal 9.5.11_https://lab.civicrm.org/dev/core/-/issues/4721Get rid of `civicrm_option_value.domain_id`2023-10-26T11:41:06ZcolemanwGet rid of `civicrm_option_value.domain_id`Background/Motivation
------
Most tables with a `domain_id` column have that field *required* for every record.
`civicrm_option_value` is an outlier; most option groups don't care about domains. In fact there are only two that do:
```p...Background/Motivation
------
Most tables with a `domain_id` column have that field *required* for every record.
`civicrm_option_value` is an outlier; most option groups don't care about domains. In fact there are only two that do:
```php
/**
* $_domainIDGroups array maintains the list of option groups for whom
* domainID is to be considered.
*
* FIXME: Hardcoded list = bad. It would be better to make this a column in the civicrm_option_group table
* @var array
*/
public static $_domainIDGroups = [
'from_email_address',
'grant_type',
];
```
The `civicrm_option_value.domain_id` column and that lovely accompanying hardcoded list were added [in this commit](https://github.com/civicrm/civicrm-svn/commit/406091dc969907753a56fd7fae73320b1b012e67) as part of [this issue](https://issues.civicrm.org/jira/browse/CRM-5546). The assumption at the time seemed to be that the list might grow in the future, but that's proven to not be the case. Instead, we have this extra column making the already overloaded `civicrm_option_value` table even more complex to deal with. It would have been better at the time to move those two option groups into their own tables. It may not be too late to do so.
Proposal
-----------
1. Create a new table `civicrm_grant_type` - manage that table from the `civigrant` extension.
2. Create a new table `civicrm_from_email_address`.
3. Migrate all options into the new tables. Update pseudoconstant metadata in the schema.
4. Add some legacy handling at a few key points like `civicrm_api()` & `CRM_Core_OptionGroup::values()` to fetch options from the new table, for backward compatibility.
5. Deprecate the `civicrm_option_value.domain_id` column and eventually drop it.https://lab.civicrm.org/dev/core/-/issues/4720[PHP 8.1] New Organization: 4x Undefined array key2023-10-27T11:41:07Zjofranzfranz@systopia.de[PHP 8.1] New Organization: 4x Undefined array key## Having
- Drupal 9.5.11
- 5.66.0
## Visiting
...civicrm/contact/add?reset=1&ct=Organization
## Seeing
```
Warning: Undefined array key "contact_sub_type" in include() (line 32 of sites/default/files/civicrm/templates_c/en_US/%%47/4...## Having
- Drupal 9.5.11
- 5.66.0
## Visiting
...civicrm/contact/add?reset=1&ct=Organization
## Seeing
```
Warning: Undefined array key "contact_sub_type" in include() (line 32 of sites/default/files/civicrm/templates_c/en_US/%%47/472/472C7800%%Organization.tpl.php).
Warning: Trying to access array offset on value of type null in include() (line 32 of sites/default/files/civicrm/templates_c/en_US/%%47/472/472C7800%%Organization.tpl.php).
Warning: Undefined array key "contact_sub_type" in include() (line 34 of sites/default/files/civicrm/templates_c/en_US/%%47/472/472C7800%%Organization.tpl.php).
Warning: Trying to access array offset on value of type null in include() (line 34 of sites/default/files/civicrm/templates_c/en_US/%%47/472/472C7800%%Organization.tpl.php).
```https://lab.civicrm.org/dev/core/-/issues/4719[PHP 8.1] New Contribution: 4x Undefined array key2023-12-12T20:43:31Zjofranzfranz@systopia.de[PHP 8.1] New Contribution: 4x Undefined array key## Having
- PHP 8.1
- Drupal 9.5.11
- 5.67.0
## Visiting
.../civicrm/contribute/add?reset=1&action=add&context=standalone
## Seeing
```
Warning: Undefined array key "buildRecurBlock" in include() (line 5 of sites/default/files/civicr...## Having
- PHP 8.1
- Drupal 9.5.11
- 5.67.0
## Visiting
.../civicrm/contribute/add?reset=1&action=add&context=standalone
## Seeing
```
Warning: Undefined array key "buildRecurBlock" in include() (line 5 of sites/default/files/civicrm/templates_c/en_US/%%60/60A/60A6E1C6%%Payment.tpl.php).
Warning: Undefined array key "buildRecurBlock" in include() (line 125 of sites/default/files/civicrm/templates_c/en_US/%%6F/6F7/6F7BB438%%Contribution.tpl.php).
Warning: Undefined array key "urlPathVar" in include() (line 90 of sites/default/files/civicrm/templates_c/en_US/%%51/516/51624B60%%paymentBlock.tpl.php).
Warning: Undefined array key "dataUrl" in include() (line 477 of sites/default/files/civicrm/templates_c/en_US/%%6F/6F7/6F7BB438%%Contribution.tpl.php).
```
---
_Internal ref: sci_https://lab.civicrm.org/dev/core/-/issues/4718[PHP 8.1] Find and Merge Duplicate Contacts: Undefined array key "weight" in...2023-11-03T02:04:37Zjofranzfranz@systopia.de[PHP 8.1] Find and Merge Duplicate Contacts: Undefined array key "weight" in CRM_Core_Action## Having
- Drupal 9.5.11
- 5.66.0
## Visiting
.../civicrm/contact/deduperules?reset=1
## Seeing
22x:
```Warning: Undefined array key "weight" in CRM_Core_Action::{closure}() (line 318 of /var/www/civicrm_env/autophpdrupalextupdate...## Having
- Drupal 9.5.11
- 5.66.0
## Visiting
.../civicrm/contact/deduperules?reset=1
## Seeing
22x:
```Warning: Undefined array key "weight" in CRM_Core_Action::{closure}() (line 318 of /var/www/civicrm_env/autophpdrupalextupdate/drupal/vendor/civicrm/civicrm-core/CRM/Core/Action.php).```5.67.0https://lab.civicrm.org/dev/core/-/issues/4717[PHP 8.1] Organization Address and Contact Info: foreach() argument must be ...2023-12-11T23:15:39Zjofranzfranz@systopia.de[PHP 8.1] Organization Address and Contact Info: foreach() argument must be of type array|object, string given## Having
- Drupal 9.5.11
- 5.66.0
## Visiting
...civicrm/admin/domain?action=update&reset=1
## Seeing
2x:
```Warning: Undefined array key "defaultCurrencySymbol" in include() (line 155 of sites/default/files/civicrm/templates_c/en...## Having
- Drupal 9.5.11
- 5.66.0
## Visiting
...civicrm/admin/domain?action=update&reset=1
## Seeing
2x:
```Warning: Undefined array key "defaultCurrencySymbol" in include() (line 155 of sites/default/files/civicrm/templates_c/en_US/%%24/24E/24E27851%%jsortable.tpl.php).```https://lab.civicrm.org/dev/core/-/issues/4716[PHP 8.1] Registered Templates: Undefined array key "weight"2023-11-01T20:31:11Zjofranzfranz@systopia.de[PHP 8.1] Registered Templates: Undefined array key "weight"## Having
- Drupal 9.5.11
- 5.66.0
## Visiting
.../civicrm/admin/report/options/report_template?reset=1
## Seeing
288x:
`Warning: Undefined array key "weight" in CRM_Core_Action::{closure}() (line 318 of /var/www/civicrm_env/autoph...## Having
- Drupal 9.5.11
- 5.66.0
## Visiting
.../civicrm/admin/report/options/report_template?reset=1
## Seeing
288x:
`Warning: Undefined array key "weight" in CRM_Core_Action::{closure}() (line 318 of /var/www/civicrm_env/autophpdrupalextupdate/drupal/vendor/civicrm/civicrm-core/CRM/Core/Action.php).`5.67.0https://lab.civicrm.org/dev/core/-/issues/4715The Search-UI extension gives a menu item Experimental2023-10-26T11:36:52ZjaapjansmaThe Search-UI extension gives a menu item Experimental**Steps to reproduce**
1. Install a fresh CiviCRM (version 5.66)
2. Enable Search UI extension
**Results**
A new menu item called Experimental appears. See attached screenshot
![Untitled](/uploads/219b7c83f1303681f6afbbc15497eacf/Unt...**Steps to reproduce**
1. Install a fresh CiviCRM (version 5.66)
2. Enable Search UI extension
**Results**
A new menu item called Experimental appears. See attached screenshot
![Untitled](/uploads/219b7c83f1303681f6afbbc15497eacf/Untitled.png)
**Why is this an issue?**
This is an issue because the extension ships with a stable version of CiviCRM Core. And installing this on a production site gives some unexpected menu item.
When I download a stable version of CiviCRM I am not sure whether I would expect a menu item Experimental.
**Possible solution**
1. Move the extension out of core. This also has the benefit it can be installed on other versions of CiviCRM as well.
2. Do not use the menu item experimental but place the items provided in this extension in a more suitable place.
My opinion would be as long as this extension is experimental to not ship it with core.https://lab.civicrm.org/dev/core/-/issues/4714Civi-Import change the description2023-10-26T07:16:29ZjaapjansmaCivi-Import change the descriptionI just installed a CiviCRM version 5.66 fresh for a client and saw a core extension Civi-Import.
The description line reads:
`Core extension for us to start moving import logic into, has more functionalit`
My question is what is this ...I just installed a CiviCRM version 5.66 fresh for a client and saw a core extension Civi-Import.
The description line reads:
`Core extension for us to start moving import logic into, has more functionalit`
My question is what is this extension? And who is the us?
I am bit afraid that the wording us also creates a not me and thus a we vs them mentality. I am not sure whether that is intededed.
So my proposal would be: `This is an extension in development to move core import functionality into an extension. This extension helps people who do development work on CiviCRM core. Feel free to contribute.`5.68.0https://lab.civicrm.org/dev/core/-/issues/4713Move the Elavon Payment Processor extension out of core2023-11-28T23:54:24ZjaapjansmaMove the Elavon Payment Processor extension out of coreI have just installed CiviCRM 5.66 for a client and I see it ships with an Elavon Payment Processor extension.
I have never heard of Elavon and I believe this extension is very usefull but not in the use cases I have seen so far. (They...I have just installed CiviCRM 5.66 for a client and I see it ships with an Elavon Payment Processor extension.
I have never heard of Elavon and I believe this extension is very usefull but not in the use cases I have seen so far. (They use CiviSepa for direct debits and Mollie for online payments both are not shipped with core).
I also believe that an extension which lives outside of core is also easier to install on CiviCRM installations which does not have this extension shipped by default (when needed).https://lab.civicrm.org/dev/core/-/issues/4712Move the PHP Storm extension out of core2023-10-26T11:37:31ZjaapjansmaMove the PHP Storm extension out of coreI have just installed a fresh Civi 5.66 site for production at a client and I see that core now ships a PHP storm extension.
I believe this extension is very useful for developers but probably not for production sites.
So can this exte...I have just installed a fresh Civi 5.66 site for production at a client and I see that core now ships a PHP storm extension.
I believe this extension is very useful for developers but probably not for production sites.
So can this extension moved out of core? That also gives other flexibility to install this extensions on older CiviCRM sites on which I am doing development on.https://lab.civicrm.org/dev/core/-/issues/4711Make it easier for extensions to add Navigation Menu items2023-10-24T14:13:07ZcolemanwMake it easier for extensions to add Navigation Menu itemsBackground
------
Extensions have a few ways of adding to the navigation menu, and none of them are great.
1. `hook_civicrm_navigationMenu()` - brute-forces an item into the menu. It's relatively easy to implement (thanks to some extra...Background
------
Extensions have a few ways of adding to the navigation menu, and none of them are great.
1. `hook_civicrm_navigationMenu()` - brute-forces an item into the menu. It's relatively easy to implement (thanks to some extra fudging that `civix` does for you) but defeats the whole configurability idea; users and administrators have no control over the item.
2. `install`/`uninstall` hooks - this is hard to implement as there are a lot of edge cases to consider (domains, weights, etc) and you have to manage the full lifecycle yourself (install, disable, enable, uninstall).
3. `hook_civicrm_managed()` - this handles the lifecycle for you, but not the domains, and the weights are completely by guesswork. Changes made by the user (e.g. deleting the menu item) might be undone by `Managed::reconcile`.
4. `.aff.php` - Afforms allow you to declare a navigation menu as part of the form - this gets delegated to `hook_civicrm_managed()`, with all the same problems that carries, plus the additional problem that user-changes to the item can lose sync with the Afform settings (see https://lab.civicrm.org/dev/core/-/issues/4364).
IMO items 1 and 2 are unfixable, but item 3 has promise, and item 4 could be deprecated in favor of 3.
Outstanding problems with Managed Navigation Menu Items.
----------
- [x] 1. ManagedEntities cannot be deleted. If a user deletes a managed Navigation item, it will respawn with the next `Managed::reconcile`.
- [x] 2. Navigation BAO doesn't even call hooks, defeating the ManagedEntity `update=unmodified` mode.
- [x] 3. ManagedEntities are not domain-aware; if you want your navigation item to appear on all domains (which you do, since your extension will be enabled globally - there are no per-domain extensions), you have to declare a managed navigation item once per domain (which is [a bit awkward](https://github.com/civicrm/civicrm-core/blob/f04bfacb5ed5131c9d29e8a9c0725c3059caeef0/ext/legacycustomsearches/managed/Navigation.mgd.php#L7)).
- [ ] 4. Picking a `weight` is pure guesswork. You just have to put in an integer and hope it lands in the right spot. Picking `0` will pretty reliably place it at the top; anything else is a roll of the dice.
Proposed Solutions
-------
1. Fixed via [ManagedEntities - Recreate deleted records at discretion of update policy](https://github.com/civicrm/civicrm-core/pull/27844).
2. Fixed via [dev/core#4364 Use writeRecord for Navigations so menu changes for managed entities don't reset](https://github.com/civicrm/civicrm-core/pull/27832).
3. Fixed via [ManagedEntity - Replicate multi-domain entities when multisite is enabled](https://github.com/civicrm/civicrm-core/pull/27876).
4. [Here is a PR](https://github.com/civicrm/civicrm-core/pull/27894) to add a `previous` and `next` join in APIv4 which would allow you to specify the name of the menu item you wish to insert next to. For example, to add a menu item just below the "Find Contacts" menu item, you'd say `['previous.name' => 'Find Contacts']` in your managed declaration (in lieu of `'weight' => 5').
5. To deprecate the Afform navigation handling, we can still support it in the Admin form, but instead of writing to the `.aff.json` file and that getting picked up by `afform_civicrm_managed()` the admin form could just save the navigation item directly. We can also teach the new [`civix export` command](https://github.com/totten/civix/pull/312) to generate a `.mgd.php` for every navigation menu item associated with an Afform.https://lab.civicrm.org/dev/core/-/issues/4710demo data needs updating for tag changes2023-10-19T23:10:37ZDaveDdemo data needs updating for tag changesJust visit the tags admin page on dmaster.demo. Looks pretty blank, which is one way to solve translation issues, but probably not as intended.Just visit the tags admin page on dmaster.demo. Looks pretty blank, which is one way to solve translation issues, but probably not as intended.https://lab.civicrm.org/dev/core/-/issues/4709Custom Field display code assumes option values are numeric2023-10-22T22:13:14ZJonGoldCustom Field display code assumes option values are numericOverview
----------------------------------------
Custom Field display code assumes option values are numeric. This leads to crashing when searching using regex/`LIKE` in Search Builder, and possibly less obsolete parts of Civi as well....Overview
----------------------------------------
Custom Field display code assumes option values are numeric. This leads to crashing when searching using regex/`LIKE` in Search Builder, and possibly less obsolete parts of Civi as well.
Reproduction steps
----------------------------------------
1. Create a new custom field of data type Alphanumeric, HTML type of Select.
1. Go to Search Builder.
1. Search on that field using regex or `LIKE`, with a period in the search term. See attached screenshot.
Current behaviour
----------------------------------------
```
TypeError: round(): Argument #1 ($num) must be of type int|float, string given in round() (line 1332 of /home/jon/local/civicrm-buildkit/build/dmaster/web/sites/all/modules/civicrm/CRM/Core/BAO/CustomField.php).
```
Expected behaviour
----------------------------------------
Search should complete as normal.
Comments
----------------------------------------
This happens because we assume that a select value either has a corresponding label, or it's a number. Which is true when you're searching for a specific value, but fails when the value is a regex or LIKE statement.
This doesn't happen in SearchKit, but it *does* happen when you use a smart group based on the search.
This is a regression in the technical sense, but it's been broken since at least 5.53.
Backtrace is below:
```
#0 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/CRM/Core/BAO/CustomField.php(1278): round()
#1 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/CRM/Core/BAO/CustomField.php(1194): CRM_Core_BAO_CustomField::formatDisplayValue()
#2 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/CRM/Core/BAO/CustomQuery.php(197): CRM_Core_BAO_CustomField::displayValue()
#3 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/CRM/Core/BAO/CustomQuery.php(369): CRM_Core_BAO_CustomQuery->where()
#4 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/CRM/Contact/BAO/Query.php(569): CRM_Core_BAO_CustomQuery->query()
#5 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/CRM/Contact/BAO/Query.php(524): CRM_Contact_BAO_Query->initialize()
#6 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/CRM/Contact/BAO/GroupContactCache.php(585): CRM_Contact_BAO_Query->__construct()
#7 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/CRM/Contact/BAO/GroupContactCache.php(777): CRM_Contact_BAO_GroupContactCache::getQueryObjectSQL()
#8 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/CRM/Contact/BAO/GroupContactCache.php(616): CRM_Contact_BAO_GroupContactCache::insertGroupContactsIntoTempTable()
#9 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/CRM/Contact/BAO/GroupContactCache.php(359): CRM_Contact_BAO_GroupContactCache::buildGroupContactTempTable()
#10 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/CRM/Mailing/BAO/Mailing.php(477): CRM_Contact_BAO_GroupContactCache::load()
#11 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/CRM/Mailing/BAO/Mailing.php(1647): CRM_Mailing_BAO_Mailing::doSubmitActions()
#12 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/api/v3/utils.php(1294): CRM_Mailing_BAO_Mailing::create()
#13 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/api/v3/Mailing.php(55): _civicrm_api3_basic_create()
#14 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/Civi/API/Provider/MagicFunctionProvider.php(89): civicrm_api3_mailing_create()
#15 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/Civi/API/Kernel.php(156): Civi\API\Provider\MagicFunctionProvider->invoke()
#16 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/Civi/API/Kernel.php(79): Civi\API\Kernel->runRequest()
#17 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/api/api.php(136): Civi\API\Kernel->runSafe()
#18 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/api/v3/Mailing.php(307): civicrm_api3()
#19 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/Civi/API/Provider/MagicFunctionProvider.php(89): civicrm_api3_mailing_submit()
#20 /home/members/mysite/sites/crm.mysite.org/web/wp-content/civicrm-custom/extensions/uk.co.vedaconsulting.mosaico/CRM/Mosaico/AbDemux.php(128): Civi\API\Provider\MagicFunctionProvider->invoke()
#21 [internal function]: CRM_Mosaico_AbDemux->onSubmitMailing()
#22 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/Civi/API/Provider/WrappingProvider.php(48): call_user_func()
#23 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/Civi/API/Kernel.php(156): Civi\API\Provider\WrappingProvider->invoke()
#24 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/Civi/API/Kernel.php(79): Civi\API\Kernel->runRequest()
#25 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/api/api.php(28): Civi\API\Kernel->runSafe()
#26 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/CRM/Utils/REST.php(288): civicrm_api()
#27 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/CRM/Utils/REST.php(533): CRM_Utils_REST::process()
#28 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php(288): CRM_Utils_REST::ajax()
#29 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php(69): CRM_Core_Invoke::runItem()
#30 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php(36): CRM_Core_Invoke::_invoke()
#31 /home/members/mysite/sites/crm.mysite.org/web/wp-content/plugins/civicrm/civicrm.php(1199): CRM_Core_Invoke::invoke()
#32 /home/members/mysite/sites/crm.mysite.org/web/wp-includes/class-wp-hook.php(310): CiviCRM_For_WordPress->invoke()
#33 /home/members/mysite/sites/crm.mysite.org/web/wp-includes/class-wp-hook.php(334): WP_Hook->apply_filters()
#34 /home/members/mysite/sites/crm.mysite.org/web/wp-includes/plugin.php(517): WP_Hook->do_action()
#35 /home/members/mysite/sites/crm.mysite.org/web/wp-admin/admin.php(259): do_action()
#36 {main}
```5.68.0JonGoldJonGold