Development issueshttps://lab.civicrm.org/groups/dev/-/issues2024-03-15T13:24:20Zhttps://lab.civicrm.org/dev/core/-/issues/4858Contact id quicksearch broken2024-03-15T13:24:20ZAndy ClarkContact id quicksearch brokenContact id quicksearch has broken in 5.67.3, albeit occasionally. User cannot locate any contacts by id at all, and using Drupal 'masquerade I verified this to be the case. The fix was to run the 'Cleanup Caches' option. What may be a...Contact id quicksearch has broken in 5.67.3, albeit occasionally. User cannot locate any contacts by id at all, and using Drupal 'masquerade I verified this to be the case. The fix was to run the 'Cleanup Caches' option. What may be a clue is that this system uses ACLs and although this user would have been restricted by ACLs she would have had access to the contacts she was searching for. As an administrator I could see the contacts when she couldn't which does seem to point to ACLs as the problem.https://lab.civicrm.org/dev/core/-/issues/4847Activity-based SearchKit results for 'restricted' users (via the Related Perm...2024-02-08T21:01:05ZpetednzActivity-based SearchKit results for 'restricted' users (via the Related Permissions Module) are no longer restricting results to only Activities of Contacts the user has access tohttps://chat.civicrm.org/civicrm/pl/wj4t3rrh7ir5uyz7t88c7fuj8o
We are using the "Related Permissions Module" https://civicrm.org/extensions/relationship-permissions-acls
Beyond that all we are doing is
- use relationship A to join X (...https://chat.civicrm.org/civicrm/pl/wj4t3rrh7ir5uyz7t88c7fuj8o
We are using the "Related Permissions Module" https://civicrm.org/extensions/relationship-permissions-acls
Beyond that all we are doing is
- use relationship A to join X (teacher) to Y (school)
- use relationship B to join Y (school) to Z (student)
- give X necessary permissions to see All Activities but not see All Contacts.
This means that in pure civicrm when X logs in they only see their Students and the relevant Activities.
- Add an SK to show My Contacts and confirm that X only sees their Students - PASS
- Add an SK to show My Activities (I can export but it is super simple) and confirm that X only sees Activities where their Students are the Target - FAIL - they now see all Students with specified Activity
This was the query from the above which worked up till last week when we ran a civi upgrade.
```
SELECT a.id AS id, a.subject AS subject, a.activity_type_id AS activity_type_id:label, Activity_ActivityContact_Contact_01.sort_name AS Activity_ActivityContact_Contact_01.sort_name, Activity_ActivityContact_Contact_01.id AS Activity_ActivityContact_Contact_01.id
FROM civicrm_activity a
INNER JOIN (civicrm_activity_contact Activity_ActivityContact_Contact_01_via_activitycontact INNER JOIN civicrm_contact Activity_ActivityContact_Contact_01 ON (Activity_ActivityContact_Contact_01_via_activitycontact.contact_id = Activity_ActivityContact_Contact_01.id)) ON Activity_ActivityContact_Contact_01_via_activitycontact.record_type_id = "3" AND Activity_ActivityContact_Contact_01_via_activitycontact.activity_id = a.id
LEFT JOIN civicrm_value_attendance_record_15 Attendance_record_1 ON a.id = Attendance_record_1.entity_id
WHERE (a.activity_type_id = "51")
AND (Attendance_record_1.week_commencing_124 BETWEEN "20231203" AND "20231209")
AND (a.is_test = "0")
AND (a.is_deleted = "0")
```colemanwcolemanwhttps://lab.civicrm.org/dev/core/-/issues/4625Inconsistent search result when "Modified By" field and apply an action2023-09-26T12:28:52Zthomas_SYSTOPIAInconsistent search result when "Modified By" field and apply an action**Description:**
When apply an action (like "Tag - add to contacts") on a search result using "Change Log->Modified By" field the result scope is lost. Instead the action would be applied to all contacts.
**Steps to reproduce** (tested...**Description:**
When apply an action (like "Tag - add to contacts") on a search result using "Change Log->Modified By" field the result scope is lost. Instead the action would be applied to all contacts.
**Steps to reproduce** (tested on https://d9-master.demo.civicrm.org/):
1. Use the advanced search form with "Change Log->Modified By" = _admin_. The result includes exactly one contact.
2. Choose "Tag - add to contacts" from the action menu.
3. You'll see "Number of selected contacts: 204" (204 are the sum of all contacts.)https://lab.civicrm.org/dev/core/-/issues/4440SearchUI: Find Contributions issues2023-07-21T09:54:27Zaydunsaidan.saunders@squiffle.ukSearchUI: Find Contributions issuesIssues that need addressing for the SearchUI Find Contributions page to match core:
- [ ] Figure out how to handle payments:
- In current version, clicking on amount expands to show payment details and buttons
- [ ] Figure out ho...Issues that need addressing for the SearchUI Find Contributions page to match core:
- [ ] Figure out how to handle payments:
- In current version, clicking on amount expands to show payment details and buttons
- [ ] Figure out how to handle Soft Credits
- Current version has several filter options
- [ ] Figure out how to handle Recurring Contributions
- Current version also searches for these. Maybe better as a separate search?
- [ ] Figure out how to handle PCPs
- (Does anyone use PCPs? If so, what is useful in this search?) Not showing correctly.
- [x] Add contribution totals
- [ ] Some actions missing
- [x] Filters - convert some to Yes/No ([#4415](https://lab.civicrm.org/dev/core/-/issues/4415))
- done by adding 'is null' fields to search. Would be nice to rework if/when 4415 is implemented.
- but this doesn't interact properly with 'Group by' used in the Summary section
- [ ] Filter layout
- Current labels and groupings are for dev purposes, need improvement
- [ ] Add more here ...https://lab.civicrm.org/dev/core/-/issues/4432Permission system can be bypassed from the search results action menu2023-07-21T09:59:05ZschorschiiPermission system can be bypassed from the search results action menuOverview
----------------------------------------
I created a simple permission structure where a group of CiviCRM users ("Group A") has write access to a group of contacts ("Group B"). (Every logged in user can read all contacts in our ...Overview
----------------------------------------
I created a simple permission structure where a group of CiviCRM users ("Group A") has write access to a group of contacts ("Group B"). (Every logged in user can read all contacts in our system.)
When a contact is now added to "Group B", users of "Group A" see the edit button on the contact and can add/remove the contact to/from groups on the contact detail page. When removing the contact from "Group B", the edit button disappears. So far, everything as expected.
But when using the actions menu from the search results, users can add/remove group assignments of a contact which is not in "Group B".
Isn't this an inconsistency in the permission system? Or am I missing something? How to avoid group membership changes of contacts which are not in "Group B" by users which are in "Group A"?
Reproduction steps
----------------------------------------
1. Create a role, assign it to "Group A" and create ACL "edit" for "Group B".
2. Log in with a non-admin user which is member of "Group A".
3. Search a contact which is not member of "Group B". Select it in the search results and choose "Group - add contact" or "Group - remove contact".
Current behaviour
----------------------------------------
I can change the group membership of this contact from within the action menu of the search result list.
Expected behaviour
----------------------------------------
Group membership changes should be refused since the contact is not member of "Group B".
When opening the contact's detail view, it works as expected, which means I'm not able to change the group memberships there.
Environment information
----------------------------------------
CiviCRM version 5.63.1 under WordPress
[Corresponding question on StackExchange](https://civicrm.stackexchange.com/questions/45266/permission-system-not-working-as-expected)https://lab.civicrm.org/dev/core/-/issues/4075Profile used for search results: contact type field shows internal name inste...2023-01-12T10:01:14Zaydunsaidan.saunders@squiffle.ukProfile used for search results: contact type field shows internal name instead of labelOverview
----------------------------------------
If you create a profile to use for search results from simple or advanced search and include the contact subtype, the value shown is the internal name, not the label.
Reproduction steps...Overview
----------------------------------------
If you create a profile to use for search results from simple or advanced search and include the contact subtype, the value shown is the internal name, not the label.
Reproduction steps
----------------------------------------
1. At `Administer > Customise Data and Screens > Contact Types` create a type as 'My new type'
1. Edit the name to be 'My changed type'
1. Create/Update a contact to use the type just created
1. At `Administer > Customise Data and Screens > Profiles` create a profile, tick 'Search Views', add `Contact > Contact Subtype` as a field
1. Go to `Search > Advanced Search, set 'Views for Display Contacts' to the profile just created. Do a search that includes the contact you created/updated
Current behaviour
----------------------------------------
The type shows as `My_new_type`
Expected behaviour
----------------------------------------
The type should show as `My changed type`
Environment information
----------------------------------------
* __CiviCRM:__ _5.57.0_ ... but maybe much earlier too.
Comments
----------------------------------------
Note that renaming the type shows the problem more clearly, but even without that, if the subtype was created with a name including a space it will show with an underscore instead of the space.https://lab.civicrm.org/dev/core/-/issues/3872Search on pledge payments on Find contributions screen2022-09-26T20:24:23ZyashodhaSearch on pledge payments on Find contributions screenIn _Find contributions_, if _CiviPledge_ is enabled, add search on pledge payments.
![se](/uploads/37de92cf4ea25288db09be94e60df203/se.png)
We do have bunch of options for search on contributions that are recurring or not, pay later o...In _Find contributions_, if _CiviPledge_ is enabled, add search on pledge payments.
![se](/uploads/37de92cf4ea25288db09be94e60df203/se.png)
We do have bunch of options for search on contributions that are recurring or not, pay later or not, would be helpful to check if the contribution is a pledge payment or not.
And based on the components enabled, we can have for event/membership as well.yashodhayashodhahttps://lab.civicrm.org/dev/core/-/issues/3835Proposal: Deprecate profile standalone listing mode2023-11-30T17:03:40ZJonGoldProposal: Deprecate profile standalone listing modeProfile standalone listing code is deeply entangled with the query BAOs, and produces weird and wonderful bugs like #3834.
I don't think they're widely used in modern CiviCRM, they seem to have been a stopgap before Views integration, a...Profile standalone listing code is deeply entangled with the query BAOs, and produces weird and wonderful bugs like #3834.
I don't think they're widely used in modern CiviCRM, they seem to have been a stopgap before Views integration, and later for non-Drupal users to get a Views-esque experience. But Search Kit has effectively replaced them - they have feature parity and then some.
I think we can improve the query code if we no longer needed to worry about standalone listing mode.
Proposal:
* Remove the ability to create standalone listings on new installations of CiviCRM.
* Create a check for profiles using standalone listing mode, warning admins if they use it.
We can deprecate this over a long period of time, so the impact should be gentle.
If this proposal is approved, we may also want to consider a function that converts profile listings to SK searches. This will have added utility as we deprecate other uses of profiles (e.g. once SK replaces Advanced Search, Search Profiles will go away).https://lab.civicrm.org/dev/financial/-/issues/177Batch Transactions: Search cannot filter by Soft-Credit2023-07-21T17:13:51ZmhowisonBatch Transactions: Search cannot filter by Soft-CreditI'm trying to create a batch of existing contacts who have all made a contribution via Donor-Advised Fund (DAF).
When I use the Find Contributions search feature, I'm able to produce a list of contacts who gave through Donor-Advised Fun...I'm trying to create a batch of existing contacts who have all made a contribution via Donor-Advised Fund (DAF).
When I use the Find Contributions search feature, I'm able to produce a list of contacts who gave through Donor-Advised Funds in FY21 (Date Received=Previous Fiscal Year, Contributions AND Their Soft Credits, Soft Credit Type=Donor-Advised Fund).
However, when I run this same query through the search feature in the 'add existing transactions to a batch' screen, the results are incorrect. It filters for previous fiscal year contributions, but it returns all contributions rather than just contributions with a soft credit type of DAF.
The Soft Credit Type criteria doesn't seem to be registering. This shows you the 'add existing transactions to a batch' screen I'm referring to: (https://docs.civicrm.org/user/en/latest/contributions/accounting-integration/#create-a-new-batch-from-existing-transactions.)https://lab.civicrm.org/dev/core/-/issues/2630Improve performance of queries in CRM_Contact_Form_Search_Custom_Base2023-02-06T04:12:42ZErikHommelImprove performance of queries in CRM_Contact_Form_Search_Custom_BaseSee this SE post: https://civicrm.stackexchange.com/questions/39636/slow-query-fixes-msp-custom-searches
It might be worth implementing the suggested improvements?See this SE post: https://civicrm.stackexchange.com/questions/39636/slow-query-fixes-msp-custom-searches
It might be worth implementing the suggested improvements?https://lab.civicrm.org/dev/core/-/issues/2342Search builder (NOT search kit) - Contribution search uses deprecated functio...2023-06-19T14:08:48ZDaveDSearch builder (NOT search kit) - Contribution search uses deprecated function CRM_Core_BAO_Query::getFieldName1. Search - Search Builder (not Search kit)
1. Do a contribution search. Let's say for Financial Type = Donation.
1. User deprecated function: Deprecated function CRM_Core_BAO_Query::getFieldName, use These parameters should be standardi...1. Search - Search Builder (not Search kit)
1. Do a contribution search. Let's say for Financial Type = Donation.
1. User deprecated function: Deprecated function CRM_Core_BAO_Query::getFieldName, use These parameters should be standardised before we get here. in CRM_Core_Error::deprecatedWarning() (line 1053 of /srv/buildkit/build/dmaster/web/sites/all/modules/civicrm/CRM/Core/Error.php).
1. The way deprecatedWarning works it loses the backtrace, but if you trace it it looks like this:
```
2 ...\CRM\Core\BAO\Query.php(97): CRM_Core_Error::deprecatedFunctionWarning("These parameters should be standardised before we get here")
3 ...\CRM\Contribute\BAO\Query.php(140): CRM_Core_BAO_Query::getFieldName((Array:5))
4 ...\CRM\Contribute\BAO\Query.php(114): CRM_Contribute_BAO_Query::whereClauseSingle((Array:5), Object(CRM_Contact_BAO_Query))
5 ...\CRM\Core\Component.php(284): CRM_Contribute_BAO_Query::where(Object(CRM_Contact_BAO_Query))
6 ...\CRM\Contact\BAO\Query.php(2061): CRM_Core_Component::alterQuery(Object(CRM_Contact_BAO_Query), "where")
7 \CRM\Contact\BAO\Query.php(574): CRM_Contact_BAO_Query->whereClause(FALSE)
8 ...\CRM\Contact\BAO\Query.php(523): CRM_Contact_BAO_Query->initialize(NULL)
9 ...\CRM\Contact\Selector.php(218): CRM_Contact_BAO_Query->__construct((Array:1), (Array:4), (Array:114), FALSE, FALSE, 1, FALSE, FALSE, FALSE, NULL, (Array:3))
10 ...\CRM\Contact\Form\Search.php(829): CRM_Contact_Selector->__construct(NULL, (Array:8), (Array:1), (Array:4), 8192, FALSE, FALSE, "builder", (Array:11))
11 ...\CRM\Contact\Form\Search\Builder.php(399): CRM_Contact_Form_Search->postProcess()
12 ...\CRM\Core\Form.php(513): CRM_Contact_Form_Search_Builder->postProcess()
```https://lab.civicrm.org/dev/user-interface/-/issues/31Clicking the browser's back button on Profile search results page removes sel...2020-10-01T13:24:02Zdarren.woodsClicking the browser's back button on Profile search results page removes selected Option from Select listCiviCRM 5.29.0 Wordpress 5.5.1
Steps to recreate:-
1) Open a Profile Page in "Search" mode (The Profile should contain a Select type field).
2) Select an Option from the list and click Search button.
3) Click browser's back button when ...CiviCRM 5.29.0 Wordpress 5.5.1
Steps to recreate:-
1) Open a Profile Page in "Search" mode (The Profile should contain a Select type field).
2) Select an Option from the list and click Search button.
3) Click browser's back button when results shown.
Expected result: All the Select list Options should be in the drop down list.
Actual result: The selected Option is not shown in the list.
Workaround: Rather than clicking the browsers' back button, users can click the "Edit search criteria" from the Profile search results page. This will show all the drop down list options as expected.
Appreciate this is a low priority bug, with a logical workaround, but would be nice to fix if it's not too much effort.https://lab.civicrm.org/dev/core/-/issues/1770Pagination in Smart Group Alphabetic listings2023-03-15T09:15:59ZmarcusjwilsonPagination in Smart Group Alphabetic listingsOverview
----------------------------------------
When creating a Smart Group (in this case, via the Search Builder) and displaying Contacts within the Smart Group, if we choose to view the Contacts by Alphabet letter, and then paginate ...Overview
----------------------------------------
When creating a Smart Group (in this case, via the Search Builder) and displaying Contacts within the Smart Group, if we choose to view the Contacts by Alphabet letter, and then paginate through that letter (i.e. viewing page 2 of the contacts with surnames starting "H"), then, at the end of the list, the contacts from the start of the "H"s are repeated.
For instance, on page 2 of the "H"s in my smart group, I see that it's displaying "Contact 51 - 67 of 67". But after Contact number 67 it starts to display the "H"s from the start again, in positions 68 to 100 (which shouldn't exist in the view).
Reproduction steps
----------------------------------------
1. Create a Smart Group using Search Builder
2. Navigate to Contacts > Manage Groups. Find the Smart Group and view "Contacts"
3. Navigate to a letter of the alphabet for Contacts where the number of results returned > 50, and view the last page of listings.
Current behaviour
----------------------------------------
Smart Groups Contacts filtered by Letter repeating contacts on last page of listings.
Expected behaviour
----------------------------------------
Smart Groups Contacts filtered by Letter only display each contact once.
Environment information
----------------------------------------
CiviCRM 5.24.3
WordPress 5.4.1
Comments
----------------------------------------
I couldn't test this on the demo sites, as there aren't enough contacts in the demo site databases to display > 50 contacts per letter of the alphabet. Can contact data on demo sites be expanded?https://lab.civicrm.org/dev/core/-/issues/1542Force urls for case tagset searches don't fill in the field on the search form2023-04-08T19:12:10ZDaveDForce urls for case tagset searches don't fill in the field on the search formI'm not sure this ever worked since I think it was part of the slew of changes for force url searches. The search itself works, but the field on the form doesn't get filled in. It works as expected for bare case tags, just not case tagse...I'm not sure this ever worked since I think it was part of the slew of changes for force url searches. The search itself works, but the field on the form doesn't get filled in. It works as expected for bare case tags, just not case tagsets.
1. Add a tagset for cases with some tags in it. (Not a bare tag, but a tag set.)
2. Create some cases that use it. Or not - it doesn't really matter to show what's wrong on the form, just if you wanted to see that the search itself is working.
3. Visit a url like https://dmaster.demo.civicrm.org/civicrm/case/search?reset=1&force=1&case_tags=4, where 4 is the id of one of the tags you created.
4. On the search form, you'd expect to see the tagset field filled in with the search parameter value but it's blank. The wordy output and results are correct.https://lab.civicrm.org/dev/financial/-/issues/37Can't search by check number for checks entered with "Record Payment"2021-10-19T05:02:37ZJonGoldCan't search by check number for checks entered with "Record Payment"Someone reported this [on Stack Exchange](https://civicrm.stackexchange.com/q/27989/12), and it's pretty easy to replicate with their steps: "when you edit a pending pay later contribution, add a check number, change status to complete a...Someone reported this [on Stack Exchange](https://civicrm.stackexchange.com/q/27989/12), and it's pretty easy to replicate with their steps: "when you edit a pending pay later contribution, add a check number, change status to complete and then i go to search contributions, enter the payment method and search by check number i get no result."
`check_number` is a field both in `civicrm_contribution` and `civicrm_financial_trxn`. I suspect this is for historical reasons rather than anything anyone considers correct in 2019.
* To solve the immediate issue, "Find Contributions" should search the check number field of related financial transactions rather than the contribution itself.
* I think there's a strong argument that `civicrm_contribution.check_number` should be deprecated altogether, but that's a much larger issue.