Development issueshttps://lab.civicrm.org/groups/dev/-/issues2019-08-19T11:33:28Zhttps://lab.civicrm.org/dev/core/-/issues/947PCP honour roll hide amount2019-08-19T11:33:28ZMartinPCP honour roll hide amountA feature request - When filling out a PCP contribution page, the donor has the option to be shown on the honor roll or not (with some additional options). Could we add an extra option here to ask if the donor would like to hide the dona...A feature request - When filling out a PCP contribution page, the donor has the option to be shown on the honor roll or not (with some additional options). Could we add an extra option here to ask if the donor would like to hide the donation amount or not?
If this request is accepted I may be able to provide the code changes for it.kcristianokcristianohttps://lab.civicrm.org/dev/core/-/issues/1192ENOTICE when creating activity from contact search results / aka Repeat Activ...2019-08-20T01:12:34ZDaveDENOTICE when creating activity from contact search results / aka Repeat Activity accordion section missing when using Add Activity from contact search resultsI'm not sure which one is the actual bug: Is it intentional that you can't create a repeating activity in this situation, in which case the bug is just the ENOTICE, or is it that it was an oversight and you are supposed to be able to cre...I'm not sure which one is the actual bug: Is it intentional that you can't create a repeating activity in this situation, in which case the bug is just the ENOTICE, or is it that it was an oversight and you are supposed to be able to create repeat activities?
The first one is easier/safer to fix, and is just [here](https://github.com/civicrm/civicrm-core/blob/5.16.2/CRM/Core/Form/RecurringEntity.php#L346). The second one seems to be coming from [here](https://github.com/civicrm/civicrm-core/blob/5.16.2/CRM/Activity/Form/Activity.php#L679), because `$this->_action` is actually `CRM_Core_Action::BASIC` in this situation, but might be more complex than just updating that line because recurring activities can be tricky, so might have been left out on purpose.
To clarify what I'm talking about:
1. Do a contact search.
1. Select a couple contacts or all.
1. From the actions dropdown choose "Add Activity".
1. On the resulting activity form there isn't the usual "Repeat Activity" section.
1. If you keep going and save you get the notice `Undefined index: allowRepeatConfigToSubmit in CRM_Core_Form_RecurringEntity::postProcess() (line 346 of /.../web/sites/all/modules/civicrm/CRM/Core/Form/RecurringEntity.php`5.18.0https://lab.civicrm.org/dev/core/-/issues/1181Navigation Menu disappears on update to 5.16.02019-08-20T13:40:50ZsbyrneNavigation Menu disappears on update to 5.16.0On updating to 5.16.0 our Navigation Menu disappeared from the top of the screen. Was still able to access other screens e.g. contacts via the dashboard and the civicrm/admin menu. Some screens (such as "Configure your dashboard") brough...On updating to 5.16.0 our Navigation Menu disappeared from the top of the screen. Was still able to access other screens e.g. contacts via the dashboard and the civicrm/admin menu. Some screens (such as "Configure your dashboard") brought up an error saying "couldn't connect to network". When viewing a contact a white space where the navigation menu would normally live was at the top of screen. Other than that all I could see was the normal Drupal 7 Admin menu (normally hidden when viewing Civi). I've managed to roll back to 5.15.1 for now. Not sure if anyone else has experienced similar.https://lab.civicrm.org/dev/core/-/issues/1196CRM_Utils_Array::crmInArray() should recurse properly2019-08-21T16:39:07ZhaystackCRM_Utils_Array::crmInArray() should recurse properlySeems that there's a minor error in `CRM_Utils_Array::crmInArray()` where the method is [called in global scope](https://lab.civicrm.org/dev/core/blob/master/CRM/Utils/Array.php#L378) instead of with `self::crmInArray()`. PR to follow.Seems that there's a minor error in `CRM_Utils_Array::crmInArray()` where the method is [called in global scope](https://lab.civicrm.org/dev/core/blob/master/CRM/Utils/Array.php#L378) instead of with `self::crmInArray()`. PR to follow.haystackhaystackhttps://lab.civicrm.org/dev/core/-/issues/1061Bad popup on update recurring screen2019-08-21T16:48:10ZeileenBad popup on update recurring screenWe are seeing a popup when checksum users attempt to update a recurring contribution.
![Screenshot_2019-06-12_at_18.50.39](/uploads/85512b40438dcd0e198fddc51dd64c00/Screenshot_2019-06-12_at_18.50.39.png)
This appears to date back to M...We are seeing a popup when checksum users attempt to update a recurring contribution.
![Screenshot_2019-06-12_at_18.50.39](/uploads/85512b40438dcd0e198fddc51dd64c00/Screenshot_2019-06-12_at_18.50.39.png)
This appears to date back to March 2018 when custom data was added to this form (by @mattwire ) - which means we don't need to target the rc & I'm inclined to focus on 'the right fix' on master.
Fundamentally we have a backoffice form that is being exposed for front end users. I have personally proposed doing similar to the 'Add Payment' form recently so it probably bares a little thought. In this case the custom data is not accessible to checksum accessors of the page & superficially the problem is not that it is not available but that it is noisily not available.
I feel like at a conceptual level we probably want to either
1) say front end forms are front end forms and back end forms are back end forms and never the twain shall meet or
2) set the front end form flag whenever a both-use-form is accessed with a checksum
In terms of the custom data I feel the safest option is just to say 'don't expose custom data on both-use forms to users without Access CiviCRM'. If people want to this might not be the right form approach for them - they can actually probably intervene by hook but the risk of exposing inappropriate custom data fields seems real.
This probably also impacts on theming & provides an obvious way not to present un-themed versions of these pages (@seamuslee @totten )5.17.0https://lab.civicrm.org/dev/core/-/issues/1037Hashed mailing URLs do not work with view mailing links2019-08-21T20:45:56ZJKingsnorthHashed mailing URLs do not work with view mailing linksCiviMail has a setting for 'Hashed Mailing URL's'
However, if this setting is enabled it is impossible to view the mailing.
Clicking 'View complete mailing' results in a server error:
![image](/uploads/a0a390d00cea3d19b3347897cdb2852e...CiviMail has a setting for 'Hashed Mailing URL's'
However, if this setting is enabled it is impossible to view the mailing.
Clicking 'View complete mailing' results in a server error:
![image](/uploads/a0a390d00cea3d19b3347897cdb2852e/image.png)
We are working on a fix for this.
Possibly related to https://lab.civicrm.org/dev/core/issues/911 ?https://lab.civicrm.org/dev/core/-/issues/1198Unable to view completed mailing if mailing hash enabled2019-08-22T01:00:07ZlcdwebUnable to view completed mailing if mailing hash enabledTo reproduce:
1. go to CiviMail > CiviMail Component Settings
2. select option for Hashed Mailing URL's
3. create and send a mailing
4. go to a contact who has received the mailing, click the Mailings tab, and View the mailing
The prev...To reproduce:
1. go to CiviMail > CiviMail Component Settings
2. select option for Hashed Mailing URL's
3. create and send a mailing
4. go to a contact who has received the mailing, click the Mailings tab, and View the mailing
The preview is handled through the API and expects the Mailing ID to be the actual mailing table ID. If hashed ID's is enabled, it fails the variable type validation check.lcdweblcdwebhttps://lab.civicrm.org/dev/core/-/issues/1186Datatables error when viewing contact multiple record custom field tab contai...2019-08-23T01:14:29ZAndrew ThompsonDatatables error when viewing contact multiple record custom field tab containing a file fieldWhen clicking on a tab for a contact custom field group (multiple record, tab with table) if the custom group contains a file field and a record exists with a file attached, the following error is displayed and the DataTable does not dis...When clicking on a tab for a contact custom field group (multiple record, tab with table) if the custom group contains a file field and a record exists with a file attached, the following error is displayed and the DataTable does not display:
`DataTables warning: table id=records-6 - Ajax error. For more information about this error, please see http://datatables.net/tn/7`
I am on CiviCRM 5.16.1 on Joomla 3.9.11. This is reproducible on dmaster. I am pretty sure that this was working recently, no more than 1-2 months ago.
Steps to reproduce:
1. Create a custom group for contacts, multiple records, tab with table
2. Add fields to the new group:
- Field1 Alphanumeric - text
- Field2 Integer - text
- File File - select
3. Go to a contact and open the tab for the custom field group
4. Add a record, enter "asdf", "123" and upload a file.
5. Error will be seen: `DataTables warning: table id=records-6 - Ajax error. For more information about this error, please see http://datatables.net/tn/7`
Firefox Network Monitor shows 500 Internal Server Error:
```
Request URL:https://dmaster.demo.civicrm.org/civicrm/ajax/multirecordfieldlist?snippet=4&cid=59&cgid=8&draw=1&columns%5B0%5D%5Bdata%5D=field1_14&columns%5B0%5D%5Bname%5D=&columns%5B0%5D%5Bsearchable%5D=true&columns%5B0%5D%5Borderable%5D=true&columns%5B0%5D%5Bsearch%5D%5Bvalue%5D=&columns%5B0%5D%5Bsearch%5D%5Bregex%5D=false&columns%5B1%5D%5Bdata%5D=field2_15&columns%5B1%5D%5Bname%5D=&columns%5B1%5D%5Bsearchable%5D=true&columns%5B1%5D%5Borderable%5D=true&columns%5B1%5D%5Bsearch%5D%5Bvalue%5D=&columns%5B1%5D%5Bsearch%5D%5Bregex%5D=false&columns%5B2%5D%5Bdata%5D=record_type_16&columns%5B2%5D%5Bname%5D=&columns%5B2%5D%5Bsearchable%5D=true&columns%5B2%5D%5Borderable%5D=true&columns%5B2%5D%5Bsearch%5D%5Bvalue%5D=&columns%5B2%5D%5Bsearch%5D%5Bregex%5D=false&columns%5B3%5D%5Bdata%5D=file_19&columns%5B3%5D%5Bname%5D=&columns%5B3%5D%5Bsearchable%5D=true&columns%5B3%5D%5Borderable%5D=true&columns%5B3%5D%5Bsearch%5D%5Bvalue%5D=&columns%5B3%5D%5Bsearch%5D%5Bregex%5D=false&columns%5B4%5D%5Bdata%5D=action&columns%5B4%5D%5Bname%5D=&columns%5B4%5D%5Bsearchable%5D=true&columns%5B4%5D%5Borderable%5D=false&columns%5B4%5D%5Bsearch%5D%5Bvalue%5D=&columns%5B4%5D%5Bsearch%5D%5Bregex%5D=false&start=0&length=25&search%5Bvalue%5D=&search%5Bregex%5D=false&_=1565849608494
Request method:GET
Remote address:192.95.2.129:443
Status code:
500
Version:HTTP/1.1
Referrer Policy:no-referrer-when-downgrade
```5.16.3https://lab.civicrm.org/dev/core/-/issues/1183Unable to merge Contacts and Cases with Case custom data , raises error - DB ...2019-08-23T01:17:15Zjustinfreeman (Agileware)Unable to merge Contacts and Cases with Case custom data , raises error - DB Error: already exists (applies to CiviCRM 5.16.0 - CiviCRM 5.18.alpha1)Unable to merge Contacts and Cases, raises error - DB Error: already exists (applies to CiviCRM 5.16.0 - CiviCRM 5.18.alpha1)
Screenshots below of the configuration.
Steps to reproduce:
1. Create Contact A and Contact B
1. Create custo...Unable to merge Contacts and Cases, raises error - DB Error: already exists (applies to CiviCRM 5.16.0 - CiviCRM 5.18.alpha1)
Screenshots below of the configuration.
Steps to reproduce:
1. Create Contact A and Contact B
1. Create custom fields for the Case Type
1. Create a Case for Contact A
1. Select the Case Type with the custom fields. Populate the custom fields.
1. Create a Case for Contact B
1. Select the Case Type with the custom fields. Populate the custom fields.
1. Search for Contact A/B
1. Merge Contact A/B
1. Observe the DB Error: already exists and merge fails to complete
Agileware ref: CIVICRM-1290
CiviCRM error log outputs the following.
Aug 13 13:20:51 [info] $Fatal Error Details = Array ( [callback] => Array ( [0] => CRM_Core_Error [1] => handle ) [code] => -5 [message] => DB Error: already exists [mode] => 16 [debug_info] => INSERT INTO civicrm_value_product_information_2 (entity_id, product_information_sought_10, product_notes_11, product_information_sent_12) SELECT 32679, product_information_sought_10, product_notes_11, product_information_sent_12 FROM civicrm_value_product_information_2 WHERE civicrm_value_product_information_2.entity_id = 32390 [nativecode=1062 ** Duplicate entry '32679' for key 'unique_entity_id'] [type] => DB_Error [user_info] => INSERT INTO civicrm_value_product_information_2 (entity_id, product_information_sought_10, product_notes_11, product_information_sent_12) SELECT 32679, product_information_sought_10, product_notes_11, product_information_sent_12 FROM civicrm_value_product_information_2 WHERE civicrm_value_product_information_2.entity_id = 32390 [nativecode=1062 ** Duplicate entry '32679' for key 'unique_entity_id'] [to_string] => [db_error: message="DB Error: already exists" code=-5 mode=callback callback=CRM_Core_Error::handle prefix="" info="INSERT INTO civicrm_value_product_information_2 (entity_id, product_information_sought_10, product_notes_11, product_information_sent_12) SELECT 32679, product_information_sought_10, product_notes_11, product_information_sent_12 FROM civicrm_value_product_information_2 WHERE civicrm_value_product_information_2.entity_id = 32390 [nativecode=1062 ** Duplicate entry '32679' for key 'unique_entity_id']"] )
Aug 13 13:20:51 [info] $backTrace = #0 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/CRM/Core/Error.php(236): CRM_Core_Error::backtrace("backTrace", TRUE) #1 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/vendor/pear/pear-core-minimal/src/PEAR.php(922): CRM_Core_Error::handle(Object(DB_Error)) #2 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/packages/DB.php(985): PEAR_Error->__construct("DB Error: already exists", -5, 16, (Array:2), "INSERT INTO civicrm_value_product_information_2 (entity_id, product_informati...") #3 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/vendor/pear/pear-core-minimal/src/PEAR.php(575): DB_Error->__construct(-5, 16, (Array:2), "INSERT INTO civicrm_value_product_information_2 (entity_id, product_informati...") #4 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/vendor/pear/pear-core-minimal/src/PEAR.php(223): PEAR->_raiseError(Object(DB_mysqli), NULL, -5, 16, (Array:2), "INSERT INTO civicrm_value_product_information_2 (entity_id, product_informati...", "DB_Error", TRUE) #5 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/packages/DB/common.php(1907): PEAR->__call("raiseError", (Array:7)) #6 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/packages/DB/mysqli.php(933): DB_common->raiseError(-5, NULL, NULL, "INSERT INTO civicrm_value_product_information_2 (entity_id, product_informati...", "1062 ** Duplicate entry '32679' for key 'unique_entity_id'") #7 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/packages/DB/mysqli.php(403): DB_mysqli->mysqliRaiseError() #8 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/packages/DB/common.php(1216): DB_mysqli->simpleQuery("INSERT INTO civicrm_value_product_information_2 (entity_id, product_informati...") #9 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/packages/DB/DataObject.php(2415): DB_common->query("INSERT INTO civicrm_value_product_information_2 (entity_id, product_informati...") #10 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/packages/DB/DataObject.php(1607): DB_DataObject->_query("INSERT INTO civicrm_value_product_information_2 (entity_id, product_informati...") #11 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/CRM/Core/DAO.php(439): DB_DataObject->query("INSERT INTO civicrm_value_product_information_2 (entity_id, product_informati...") #12 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/CRM/Core/DAO.php(1414): CRM_Core_DAO->query("INSERT INTO civicrm_value_product_information_2 (entity_id, product_informati...", TRUE) #13 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/CRM/Case/BAO/Case.php(2105): CRM_Core_DAO::executeQuery("INSERT INTO civicrm_value_product_information_2 (entity_id, product_informati...") #14 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/CRM/Case/BAO/Case.php(2006): CRM_Case_BAO_Case::mergeCases(39121, 32679, 39158) #15 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/CRM/Dedupe/Merger.php(539): CRM_Case_BAO_Case::mergeContacts(39121, 39158, (Array:91), (Array:5), (Array:0)) #16 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/CRM/Dedupe/Merger.php(1547): CRM_Dedupe_Merger::moveContactBelongings(39121, 39158, (Array:5), (Array:0), (Array:0)) #17 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/CRM/Contact/Form/Merge.php(314): CRM_Dedupe_Merger::moveAllBelongings("39121", "39158", (Array:19)) #18 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/CRM/Core/Form.php(495): CRM_Contact_Form_Merge->postProcess() #19 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/CRM/Core/StateMachine.php(160): CRM_Core_Form->mainProcess() #20 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/CRM/Core/QuickForm/Action/Next.php(61): CRM_Core_StateMachine->perform(Object(CRM_Contact_Form_Merge), "next", "Next") #21 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/packages/HTML/QuickForm/Controller.php(203): CRM_Core_QuickForm_Action_Next->perform(Object(CRM_Contact_Form_Merge), "next") #22 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/packages/HTML/QuickForm/Page.php(103): HTML_QuickForm_Controller->handle(Object(CRM_Contact_Form_Merge), "next") #23 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/CRM/Core/Controller.php(351): HTML_QuickForm_Page->handle("next") #24 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/CRM/Utils/Wrapper.php(114): CRM_Core_Controller->run() #25 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/CRM/Core/Invoke.php(284): CRM_Utils_Wrapper->run("CRM_Contact_Form_Merge", "Merge Contact", (Array:0)) #26 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/CRM/Core/Invoke.php(85): CRM_Core_Invoke::runItem((Array:13)) #27 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/CRM/Core/Invoke.php(52): CRM_Core_Invoke::_invoke((Array:3)) #28 /var/www/vhosts/somesite.org.au/sites/all/modules/civicrm/drupal/civicrm.module(444): CRM_Core_Invoke::invoke((Array:3)) #29 /var/www/vhosts/somesite.org.au/includes/menu.inc(527): civicrm_invoke("contact", "merge") #30 /var/www/vhosts/somesite.org.au/index.php(21): menu_execute_active_handler() #31 {main}
![2mP02ZAdHT](/uploads/b48366d8c8295ec49c9e7749f0ce8fed/2mP02ZAdHT.png)
![chrome_Nts2q2Q2Je](/uploads/20f7795ecda5540e0b6c8d2e6b4cbdd4/chrome_Nts2q2Q2Je.png)
![chrome_qB8axmDkum](/uploads/0db499b218504e5c884a37b6dd33662d/chrome_qB8axmDkum.png)
![chrome_SEJayeeYOR](/uploads/5593a0fb267f7a02bfbfd9c37b64e9a1/chrome_SEJayeeYOR.png)
![chrome_y2bcL4Au7h](/uploads/cbeb37a47ae5bcccd08d5e98d50583d4/chrome_y2bcL4Au7h.png)
![chrome_WDcccWB4c5](/uploads/a11fdf036e68ed9469183d1411b0ff20/chrome_WDcccWB4c5.png)5.16.3justinfreeman (Agileware)justinfreeman (Agileware)https://lab.civicrm.org/dev/core/-/issues/1203Add `hook_civicrm_pre` and `hook_civicrm_post` to Domain create and edit oper...2019-08-23T01:51:02ZhaystackAdd `hook_civicrm_pre` and `hook_civicrm_post` to Domain create and edit operationsCreating or editing most CiviCRM entities triggers both the `hook_civicrm_pre` and `hook_civicrm_post` hooks. Domains seem to have been overlooked - which means that one cannot detect when a new Domain has been created or when a Domain h...Creating or editing most CiviCRM entities triggers both the `hook_civicrm_pre` and `hook_civicrm_post` hooks. Domains seem to have been overlooked - which means that one cannot detect when a new Domain has been created or when a Domain has been edited. PR to follow.5.18.0haystackhaystackhttps://lab.civicrm.org/dev/core/-/issues/690Support more entities in Attachment API by short-circuiting permission check2019-08-23T07:06:15ZPatrick Figelpfigel@greenpeace.orgSupport more entities in Attachment API by short-circuiting permission checkWe recently tried to use the `Attachment` API to upload files to a custom file field attached to memberships. This works for a number of entities, but for `Membership` and a couple of others, `Civi\API\Subscriber\DynamicFKAuthorization::...We recently tried to use the `Attachment` API to upload files to a custom file field attached to memberships. This works for a number of entities, but for `Membership` and a couple of others, `Civi\API\Subscriber\DynamicFKAuthorization::authorizeDelegate` fails with `Failed to run permission check: Unrecognized target entity table ($entityTable)`.
This makes sense for API requests with `check_permissions` enabled, where you need an entity that supports permission checks, but for trusted API calls, I don't think we need to check whether the entity is an allowed delegate first. The actual permission check is not performed on trusted API calls, so it's just the check against `DynamicFKAuthorization::$allowedDelegates` that's causing this behaviour.
I have a preliminary patch for this [here](https://github.com/civicrm/civicrm-core/commit/7c548d31d8b3a2f5969ac9b5f9b2830172a05f28) (haven't checked whether we need any additional tests, `DynamicFKAuthorizationTest` passes). Wanted to check if my understanding of this is correct and whether there's interest in picking up a change like this.
Related discussion on chat: https://chat.civicrm.org/civicrm/pl/m8exdax5oi899gqtehtygt4aahhttps://lab.civicrm.org/dev/core/-/issues/502DB error "no such field" when executing actions on a sorted contact search re...2019-08-23T07:53:16ZjensschuppeDB error "no such field" when executing actions on a sorted contact search result with search profileSteps to reproduce:
- Create a profile with e.g. the postal code field of the primary address
- Perform a contact search using this profile for displaying the results
- Sort the result by the postal code field
- Tick the "all # records"...Steps to reproduce:
- Create a profile with e.g. the postal code field of the primary address
- Perform a contact search using this profile for displaying the results
- Sort the result by the postal code field
- Tick the "all # records" radio button
- Choose any action to perform on the result (e.g. "Print PDF document")
The result is a "DB error: no such field" for the "1-postal_code" field. Error details:
```
Array
(
[callback] => Array
(
[0] => CRM_Core_Error
[1] => handle
)
[code] => -19
[message] => DB Error: no such field
[mode] => 16
[debug_info] => SELECT contact_a.id as contact_id FROM civicrm_contact contact_a WHERE (contact_a.is_deleted = 0) ORDER BY `1-postal_code` asc, `contact_a`.`id` [nativecode=1054 ** Unknown column '1-postal_code' in 'order clause']
[type] => DB_Error
[user_info] => SELECT contact_a.id as contact_id FROM civicrm_contact contact_a WHERE (contact_a.is_deleted = 0) ORDER BY `1-postal_code` asc, `contact_a`.`id` [nativecode=1054 ** Unknown column '1-postal_code' in 'order clause']
[to_string] => [db_error: message="DB Error: no such field" code=-19 mode=callback callback=CRM_Core_Error::handle prefix="" info="SELECT contact_a.id as contact_id FROM civicrm_contact contact_a WHERE (contact_a.is_deleted = 0) ORDER BY `1-postal_code` asc, `contact_a`.`id` [nativecode=1054 ** Unknown column '1-postal_code' in 'order clause']"]
)
```
The generated query is missing the JOINs for the `civicrm_address` table, resulting in the postal_code field not being part of the result set to be ordered by. The JOIN is not being added to the query in `CRM_Contact_BAO_Query::prepareOrderBy()` due to the field being named `1-postal_code` and the code expects the field being named `postal_code` for adding relationships to the `civicrm_address` table.
The exception is being raised in [`CRM_Contact_BAO_Query::searchQuery`](https://lab.civicrm.org/dev/core/blob/master/CRM/Contact/BAO/Query.php#L4958).
Stepping through the code, this seems to also happen when ordering the search result, but the exception is then being caught in [`CRM_Contact_Selector::fillupPrevNextCache()`](https://lab.civicrm.org/dev/core/blob/master/CRM/Contact/Selector.php#L1048), following a `$this->rebuildPreNextCache()` call to re-create the query.5.13.0https://lab.civicrm.org/dev/drupal/-/issues/34Drupal8: Missing Date format in views configuration2019-08-23T13:10:14Zmagnolia61Drupal8: Missing Date format in views configurationIn the views configuration for events, using CiviCRM 5.5.2 on Drupal 8 the date format cannot be configured. Not sure what causes this, but thought it would be good to report.
**In CiviCRM/Drupal7 ** <br>
![Screenshot_from_2018-10-22_13...In the views configuration for events, using CiviCRM 5.5.2 on Drupal 8 the date format cannot be configured. Not sure what causes this, but thought it would be good to report.
**In CiviCRM/Drupal7 ** <br>
![Screenshot_from_2018-10-22_13-38-49](/uploads/8e33c20c5252ab9a9efcd9f073059f4a/Screenshot_from_2018-10-22_13-38-49.png)
**In CiviCRM/Drupal8** <br>
![Screenshot_from_2018-10-22_13-38-50](/uploads/de3dc32c9cc66f4d5caea15d73552ea6/Screenshot_from_2018-10-22_13-38-50.png)https://lab.civicrm.org/dev/drupal/-/issues/38Drupal8: Can't call CRM_Utils_System::url() from CLI with absolute URL2019-08-23T14:30:53ZJonGoldDrupal8: Can't call CRM_Utils_System::url() from CLI with absolute URLThis is easy to replicate. Run the following command on a D8 site and compare it to a non-D8 site:
```shell
cv ev 'return CRM_Utils_System::url("civicrm", NULL, TRUE)'
```
On D7 etc., you'll get something like:
```
"http://dmaster.local...This is easy to replicate. Run the following command on a D8 site and compare it to a non-D8 site:
```shell
cv ev 'return CRM_Utils_System::url("civicrm", NULL, TRUE)'
```
On D7 etc., you'll get something like:
```
"http://dmaster.localhost/civicrm"
```
On D8, you'll get:
```
"http://:/civicrm"
```
`CRM_Utils_System_Drupal8::url()` calls a [Drupal-specific method](https://github.com/civicrm/civicrm-core/blob/master/CRM/Utils/System/Drupal8.php#L307-L311) to construct the URL. Ultimately, this calls Symfony's [getHost()](https://github.com/symfony/http-foundation/blob/2.8/Request.php#L1202) method, which populates the URL from PHP superglobals which aren't populated when running from CLI.
After digging, I found that there's no way D8 can auto-detect the correct base when run from the CLI, so I'm submitting a PR to pre-set the base when an absolute URL is needed.JonGoldJonGoldhttps://lab.civicrm.org/dev/financial/-/issues/58Batch payment page breaks when an exported activity has no file to download2019-08-23T22:27:09ZJonGoldBatch payment page breaks when an exported activity has no file to downloadI had a batch export fail because `max_execution_time` failed. This left me with an exported batch without an export file - which causes the View Batches page to fail with the backtrace below.
My patch will prevent the page from crashi...I had a batch export fail because `max_execution_time` failed. This left me with an exported batch without an export file - which causes the View Batches page to fail with the backtrace below.
My patch will prevent the page from crashing so it's possible to view the batch page,
```
May 28 20:13:12 [info] $backTrace = #0 /home/jon/local/agbud8/htdocs/vendor/civicrm/civicrm-core/CRM/Core/Error.php(385): CRM_Core_Error::backtrace("backTrace", TRUE)
#1 /home/jon/local/agbud8/htdocs/vendor/civicrm/civicrm-core/CRM/Core/DAO.php(1196): CRM_Core_Error::fatal()
#2 /home/jon/local/agbud8/htdocs/vendor/civicrm/civicrm-core/CRM/Batch/BAO/Batch.php(337): CRM_Core_DAO::getFieldValue("CRM_Core_DAO_EntityFile", NULL, "file_id", "entity_id")
#3 /home/jon/local/agbud8/htdocs/vendor/civicrm/civicrm-core/CRM/Batch/BAO/Batch.php(172): CRM_Batch_BAO_Batch::getBatchList((Array:31))
#4 /home/jon/local/agbud8/htdocs/vendor/civicrm/civicrm-core/CRM/Batch/Page/AJAX.php(100): CRM_Batch_BAO_Batch::getBatchListSelector((Array:31))
#5 /home/jon/local/agbud8/htdocs/vendor/civicrm/civicrm-core/CRM/Core/Invoke.php(277): CRM_Batch_Page_AJAX::getBatchList()
#6 /home/jon/local/agbud8/htdocs/vendor/civicrm/civicrm-core/CRM/Core/Invoke.php(85): CRM_Core_Invoke::runItem((Array:12))
#7 /home/jon/local/agbud8/htdocs/vendor/civicrm/civicrm-core/CRM/Core/Invoke.php(52): CRM_Core_Invoke::_invoke((Array:3))
#8 /home/jon/local/agbud8/htdocs/web/modules/contrib/civicrm/src/Civicrm.php(88): CRM_Core_Invoke::invoke((Array:3))
#9 /home/jon/local/agbud8/htdocs/web/modules/contrib/civicrm/src/Controller/CivicrmController.php(75): Drupal\civicrm\Civicrm->invoke((Array:3))
#10 [internal function](): Drupal\civicrm\Controller\CivicrmController->main((Array:3), "")
#11 /home/jon/local/agbud8/htdocs/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(123): call_user_func_array((Array:2), (Array:2))
#12 /home/jon/local/agbud8/htdocs/web/core/lib/Drupal/Core/Render/Renderer.php(582): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}()
#13 /home/jon/local/agbud8/htdocs/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(124): Drupal\Core\Render\Renderer->executeInRenderContext(Object(Drupal\Core\Render\RenderContext), Object(Closure))
#14 /home/jon/local/agbud8/htdocs/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(97): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext((Array:2), (Array:2))
#15 /home/jon/local/agbud8/htdocs/vendor/symfony/http-kernel/HttpKernel.php(151): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}()
#16 /home/jon/local/agbud8/htdocs/vendor/symfony/http-kernel/HttpKernel.php(68): Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object(Symfony\Component\HttpFoundation\Request), 1)
#17 /home/jon/local/agbud8/htdocs/web/core/lib/Drupal/Core/StackMiddleware/Session.php(57): Symfony\Component\HttpKernel\HttpKernel->handle(Object(Symfony\Component\HttpFoundation\Request), 1, TRUE)
#18 /home/jon/local/agbud8/htdocs/web/core/lib/Drupal/Core/StackMiddleware/KernelPreHandle.php(47): Drupal\Core\StackMiddleware\Session->handle(Object(Symfony\Component\HttpFoundation\Request), 1, TRUE)
#19 /home/jon/local/agbud8/htdocs/web/core/modules/page_cache/src/StackMiddleware/PageCache.php(106): Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object(Symfony\Component\HttpFoundation\Request), 1, TRUE)
#20 /home/jon/local/agbud8/htdocs/web/core/modules/page_cache/src/StackMiddleware/PageCache.php(85): Drupal\page_cache\StackMiddleware\PageCache->pass(Object(Symfony\Component\HttpFoundation\Request), 1, TRUE)
#21 /home/jon/local/agbud8/htdocs/web/core/lib/Drupal/Core/StackMiddleware/ReverseProxyMiddleware.php(47): Drupal\page_cache\StackMiddleware\PageCache->handle(Object(Symfony\Component\HttpFoundation\Request), 1, TRUE)
#22 /home/jon/local/agbud8/htdocs/web/core/lib/Drupal/Core/StackMiddleware/NegotiationMiddleware.php(52): Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object(Symfony\Component\HttpFoundation\Request), 1, TRUE)
#23 /home/jon/local/agbud8/htdocs/vendor/stack/builder/src/Stack/StackedHttpKernel.php(23): Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object(Symfony\Component\HttpFoundation\Request), 1, TRUE)
#24 /home/jon/local/agbud8/htdocs/web/core/lib/Drupal/Core/DrupalKernel.php(693): Stack\StackedHttpKernel->handle(Object(Symfony\Component\HttpFoundation\Request), 1, TRUE)
#25 /home/jon/local/agbud8/htdocs/web/index.php(19): Drupal\Core\DrupalKernel->handle(Object(Symfony\Component\HttpFoundation\Request))
#26 {main}
```5.18.0https://lab.civicrm.org/dev/joomla/-/issues/15PHP 7.2 countable warning after installation2019-08-25T12:56:11ZAndrew ThompsonPHP 7.2 countable warning after installationPHP 7.2 Warning: count(): Parameter must be an array or an object that implements Countable in <directory>/com_civicrm/script.civicrm.php on line 196
```
( ! ) Warning: count(): Parameter must be an array or an object that implements Cou...PHP 7.2 Warning: count(): Parameter must be an array or an object that implements Countable in <directory>/com_civicrm/script.civicrm.php on line 196
```
( ! ) Warning: count(): Parameter must be an array or an object that implements Countable in /var/www/html/j4/tmp/install_5d60cbd7ce50c/com_civicrm/script.civicrm.php on line 196
Call Stack
# Time Memory Function Location
1 0.0000 403864 {main}( ) .../index.php:0
2 0.0001 404472 require_once( '/var/www/html/j4/administrator/includes/app.php' ) .../index.php:36
3 0.0077 1563680 Joomla\CMS\Application\AdministratorApplication->execute( ) .../app.php:63
4 0.0322 2418728 Joomla\CMS\Application\AdministratorApplication->doExecute( ) .../CMSApplication.php:241
5 0.0364 2787576 Joomla\CMS\Application\AdministratorApplication->dispatch( ) .../AdministratorApplication.php:159
6 0.0389 2892928 Joomla\CMS\Component\ComponentHelper::renderComponent( ) .../AdministratorApplication.php:116
7 0.0403 3107360 Joomla\CMS\Dispatcher\ComponentDispatcher->dispatch( ) .../ComponentHelper.php:383
8 0.0412 3122736 Joomla\Component\Installer\Administrator\Controller\InstallController->execute( ) .../ComponentDispatcher.php:146
9 0.0412 3122736 Joomla\Component\Installer\Administrator\Controller\InstallController->install( ) .../BaseController.php:728
10 0.0418 3134944 Joomla\Component\Installer\Administrator\Model\InstallModel->install( ) .../InstallController.php:42
11 1.0990 3302576 Joomla\CMS\Installer\Installer->install( ) .../InstallModel.php:200
12 1.1119 3413200 Joomla\CMS\Installer\Adapter\ComponentAdapter->install( ) .../Installer.php:514
13 7.2639 22404896 Joomla\CMS\Installer\Adapter\ComponentAdapter->triggerManifestScript( ) .../InstallerAdapter.php:870
14 7.2639 22421408 Com_CiviCRMInstallerScript->postflight( ) .../InstallerAdapter.php:1082
15 7.2639 22421408 Com_CiviCRMInstallerScript->setDefaultPermissions( ) .../script.civicrm.php:184
```
This warning is only visible on a fresh installation, not an upgrade.5.18.0https://lab.civicrm.org/dev/core/-/issues/1199No permission to add cases because permission check will always return 0 when...2019-08-25T13:14:48ZErikHommelNo permission to add cases because permission check will always return 0 when I have no casesI have enabled the CiviCase component. When trying to add a case I get the message "You do not have permission to access this case." Correct, I remember....I have to add the Case permissions in my CMS. After doing this, I continue to get...I have enabled the CiviCase component. When trying to add a case I get the message "You do not have permission to access this case." Correct, I remember....I have to add the Case permissions in my CMS. After doing this, I continue to get the message "You do not have permission to access this case." even though I also get the message "Case succesfully added".
Inspecting the code the permission is checked in CRM_Case_Form_CaseView:
```` php
// Access check.
if (!CRM_Case_BAO_Case::accessCase($this->_caseID, FALSE)) {
CRM_Core_Error::statusBounce(ts('You do not have permission to access this case.'));
}
````
The called function CRM_Case_BAO_Case::accessCase will always return 0 (meaning FALSE) whenever I have no cases in my database yet:
```` php
try {
return (bool) civicrm_api3('Case', 'getcount', $params);
}
catch (CiviCRM_API3_Exception $e) {
// Lack of permissions will throw an exception
return FALSE;
}
````
So it seems that I can never add a case if I have no cases yet, or am I missing something?
This is on CiviCRM 5.16.2https://lab.civicrm.org/dev/core/-/issues/1001Warnings on CRM_Contribute_Import_Parser re countable2019-08-25T14:07:22ZJoeMurrayWarnings on CRM_Contribute_Import_Parser re countableon 5.15.alpha1 on dmaster May 29, testing an import of contributions on step 2 of 4 I get:
Warning: count(): Parameter must be an array or an object that implements Countable in CRM_Contribute_Import_Parser->setActiveFieldSoftCredit() (...on 5.15.alpha1 on dmaster May 29, testing an import of contributions on step 2 of 4 I get:
Warning: count(): Parameter must be an array or an object that implements Countable in CRM_Contribute_Import_Parser->setActiveFieldSoftCredit() (line 433 of /srv/buildkit/build/dmaster/sites/all/modules/civicrm/CRM/Contribute/Import/Parser.php).
Warning: count(): Parameter must be an array or an object that implements Countable in CRM_Contribute_Import_Parser->setActiveFieldSoftCreditType() (line 442 of /srv/buildkit/build/dmaster/sites/all/modules/civicrm/CRM/Contribute/Import/Parser.php).5.18.0EdselopezEdselopezhttps://lab.civicrm.org/dev/financial/-/issues/66[regression] Thank-you date is lost on editing contributions2019-08-28T05:12:40ZJonGold[regression] Thank-you date is lost on editing contributionsA rather serious regression which IMO merits an out-of-band release.
**To replicate**
* Open a contribution for editing that has a thank-you date.
That's it. The page loads without the contribution date, and so it's lost on save.
Thi...A rather serious regression which IMO merits an out-of-band release.
**To replicate**
* Open a contribution for editing that has a thank-you date.
That's it. The page loads without the contribution date, and so it's lost on save.
This was introduced by https://github.com/civicrm/civicrm-core/commit/b4e8c2b4c3f3730a7193824dfb6452b86d5e31d7 which shipped with 5.16.0.
My quick fix is just to revert it, but others, particularly @pfigel, may want to chime in.5.16.3JonGoldJonGoldhttps://lab.civicrm.org/dev/core/-/issues/469Error on action "Email - schedule/send via CiviMail" with multiple event name...2019-08-29T08:33:46ZfrancescbassasError on action "Email - schedule/send via CiviMail" with multiple event names filterOriginal issue: https://issues.civicrm.org/jira/browse/CRM-21767
Affected versions: at least from 4.7.31
---
**Steps to reproduce**
1. Go to **Search > Advanced Search**
2. Select two events on **Event Name** field and click to **Sea...Original issue: https://issues.civicrm.org/jira/browse/CRM-21767
Affected versions: at least from 4.7.31
---
**Steps to reproduce**
1. Go to **Search > Advanced Search**
2. Select two events on **Event Name** field and click to **Search** button
3. Select **All records** and click **Actions** button
4. Click on **Email - schedule/send via CiviMail**
5. An error screen appears with a message like
`3,2 is not of the type Int`5.12.0