civicrm-core.git
6 years agoMerge pull request #12449 from colemanw/gettree
colemanw [Thu, 12 Jul 2018 23:13:33 +0000 (19:13 -0400)]
Merge pull request #12449 from colemanw/gettree

CustomValue gettree api - More accurate permission check

6 years agoMerge pull request #12436 from mattwire/financial_type_pseudoconstant
Eileen McNaughton [Thu, 12 Jul 2018 23:06:12 +0000 (11:06 +1200)]
Merge pull request #12436 from mattwire/financial_type_pseudoconstant

dev/core#241 Fix Manage Premiums UI

6 years agoMerge pull request #12459 from yashodha/dev-255
Eileen McNaughton [Thu, 12 Jul 2018 23:00:12 +0000 (11:00 +1200)]
Merge pull request #12459 from yashodha/dev-255

(dev/core#255) Changes to copied event location reflects in original …

6 years ago(dev/core#255) Changes to copied event location reflects in original event location
yashodha [Thu, 12 Jul 2018 09:45:20 +0000 (15:15 +0530)]
(dev/core#255) Changes to copied event location reflects in original event location

6 years agoMerge pull request #12458 from mlutfy/pricefield-isset
Eileen McNaughton [Thu, 12 Jul 2018 03:18:08 +0000 (15:18 +1200)]
Merge pull request #12458 from mlutfy/pricefield-isset

PriceField: show pre/post help if not empty, not if isset.

6 years agoPriceField: show pre/post help if not empty, not if isset.
Mathieu Lutfy [Wed, 11 Jul 2018 20:46:37 +0000 (16:46 -0400)]
PriceField: show pre/post help if not empty, not if isset.

6 years agoMerge pull request #12451 from eileenmcnaughton/premiums
colemanw [Wed, 11 Jul 2018 16:47:13 +0000 (12:47 -0400)]
Merge pull request #12451 from eileenmcnaughton/premiums

Deprecate  array on ManagePremiums

6 years agoDon't reset financial type every time product is edited
Matthew Wire [Tue, 10 Jul 2018 16:27:39 +0000 (17:27 +0100)]
Don't reset financial type every time product is edited

6 years agoEnable pseudoconstant for financial_type and use it to display financial type for...
Matthew Wire [Fri, 6 Jul 2018 17:37:20 +0000 (18:37 +0100)]
Enable pseudoconstant for financial_type and use it to display financial type for premiums. Add "cost" column to premium UI and properly format money

6 years agoMerge pull request #12450 from eileenmcnaughton/comments
Seamus Lee [Wed, 11 Jul 2018 04:00:09 +0000 (14:00 +1000)]
Merge pull request #12450 from eileenmcnaughton/comments

[NFC] Comment fixes

6 years agoMerge pull request #12392 from madhavimalgaonkar/issue-221
Eileen McNaughton [Wed, 11 Jul 2018 01:00:32 +0000 (13:00 +1200)]
Merge pull request #12392 from madhavimalgaonkar/issue-221

dev/core#221, check if the grouptree is not empty

6 years agoComment fixes
eileen [Wed, 11 Jul 2018 00:36:11 +0000 (12:36 +1200)]
Comment fixes

6 years agoDeprecate array on ManagePremiums
eileen [Wed, 11 Jul 2018 00:33:53 +0000 (12:33 +1200)]
Deprecate  array on ManagePremiums

6 years agoMerge pull request #12448 from civicrm/5.4
Eileen McNaughton [Wed, 11 Jul 2018 00:20:53 +0000 (12:20 +1200)]
Merge pull request #12448 from civicrm/5.4

5.4

6 years agoMerge pull request #12410 from eileenmcnaughton/option_group
colemanw [Tue, 10 Jul 2018 23:49:31 +0000 (19:49 -0400)]
Merge pull request #12410 from eileenmcnaughton/option_group

dev/core/issues/228 fix OptionGroup create action to not disable on update

6 years agoCustomValue gettree api - More accurate permission check
Coleman Watts [Tue, 10 Jul 2018 22:45:43 +0000 (18:45 -0400)]
CustomValue gettree api - More accurate permission check

6 years agoMerge pull request #12373 from JMAConsulting/access-3-contact-dash
colemanw [Tue, 10 Jul 2018 21:28:56 +0000 (17:28 -0400)]
Merge pull request #12373 from JMAConsulting/access-3-contact-dash

dev/accessibility#3: Add accessible label on Contact Edit form elements and helpicon

6 years agoMerge pull request #12447 from mattwire/allcontactexport_regression
Seamus Lee [Tue, 10 Jul 2018 20:36:35 +0000 (06:36 +1000)]
Merge pull request #12447 from mattwire/allcontactexport_regression

dev/core#249 Fix crash when performing export all contacts from search

6 years agoFix crash when performing export all contacts from search
Matthew Wire [Mon, 9 Jul 2018 22:38:10 +0000 (23:38 +0100)]
Fix crash when performing export all contacts from search

6 years agoMerge pull request #12445 from MiyaNoctem/CRM-21425-make-inbound-emails-editable...
Seamus Lee [Mon, 9 Jul 2018 23:25:01 +0000 (09:25 +1000)]
Merge pull request #12445 from MiyaNoctem/CRM-21425-make-inbound-emails-editable-try-2

CRM-21425: Make Inbound Emails Editable With Permissions

6 years agoMerge pull request #12384 from JMAConsulting/dev-core-218
Eileen McNaughton [Mon, 9 Jul 2018 22:13:09 +0000 (10:13 +1200)]
Merge pull request #12384 from JMAConsulting/dev-core-218

dev/core#218 : On Case Type listing page, for reserved ones the, 'More' link don't show any options

6 years agoMerge pull request #12442 from colemanw/crmeditable.tpl
Eileen McNaughton [Mon, 9 Jul 2018 21:30:42 +0000 (09:30 +1200)]
Merge pull request #12442 from colemanw/crmeditable.tpl

Remove old deprecated crmeditable.tpl

6 years agoMerge pull request #12443 from colemanw/empty
Eileen McNaughton [Mon, 9 Jul 2018 21:29:47 +0000 (09:29 +1200)]
Merge pull request #12443 from colemanw/empty

Fix potential undefined array index

6 years agoMerge pull request #12438 from totten/master-contact-sel
colemanw [Mon, 9 Jul 2018 11:44:07 +0000 (07:44 -0400)]
Merge pull request #12438 from totten/master-contact-sel

(dev/core#217) CRM_Contact_Selector::getRows() - Use generator instead of DAO loop

6 years agoCRM-21425: Fix 'Array' Appearing Insted of Empty Details
Camilo Rodriguez [Thu, 18 Jan 2018 22:19:19 +0000 (22:19 +0000)]
CRM-21425: Fix 'Array' Appearing Insted of Empty Details

When having only basic access to edit inbound e-mails, if the task's details
are null, an message saying 'Array' was being shown, instead of the empty
details.

Fixed by changing null for an empty string.

6 years agoCRM-21425: Allow to Edit Inbound E-mails Within CiviCase
Camilo Rodriguez [Thu, 11 Jan 2018 15:00:50 +0000 (15:00 +0000)]
CRM-21425: Allow to Edit Inbound E-mails Within CiviCase

Civicase used the activity's detail view form to show the detail for the
activity and the edit and delete buttons, but the preprocessing lacked setting
the required flags so the form buttons were shown.

Fixed by setting the required flags and refactoring the new permissions check
into the Activity BAO.

6 years agoCRM-21425: Add Permissions to Edit Inbound E-mails
Camilo Rodriguez [Tue, 14 Nov 2017 19:21:30 +0000 (19:21 +0000)]
CRM-21425: Add Permissions to Edit Inbound E-mails

The following permissions were added to CiviCRM core:

- CiviCRM: edit inbound email basic information
- CiviCRM: edit inbound email basic information and content

Having any of these permissions will alow  user to edit inbound E-mails, but
only the latter will allow users to also change the original email's content.

E-mails downloaded and stored as Inbound Email activities were saving their
details in two formats, as an ezComponents-parsed representation of
a text with alternatives. These alternatives were being stripped on the
Activity Form template, with the side effect of also stripping the textarea
where the wysiwyg editor would be built upon.

Fixed by stripping alternatives when preprocessing the quickform instead,
before the html for the textarea is generated.

6 years agoFix potential undefined array index
Coleman Watts [Sun, 8 Jul 2018 16:23:53 +0000 (12:23 -0400)]
Fix potential undefined array index

6 years agoRemove old deprecated crmeditable.tpl
Coleman Watts [Sun, 8 Jul 2018 16:23:06 +0000 (12:23 -0400)]
Remove old deprecated crmeditable.tpl

6 years agoMerge pull request #12441 from totten/master-sql-del
colemanw [Sun, 8 Jul 2018 15:59:46 +0000 (11:59 -0400)]
Merge pull request #12441 from totten/master-sql-del

Implement CRM_Utils_SQL_Delete

6 years agoImplement CRM_Utils_SQL_Delete
Tim Otten [Sun, 8 Jul 2018 01:48:30 +0000 (18:48 -0700)]
Implement CRM_Utils_SQL_Delete

Before
------
* `CRM_Utils_SQL_Select` and `CRM_Utils_SQL_Insert` are query-building utilities.

After
-----
* `CRM_Utils_SQL_Select`, `CRM_Utils_SQL_Insert`, and `CRM_Utils_SQL_Delete` are query-building utilities.
* `CRM_Utils_SQL_Select` and `CRM_Utils_SQL_Delete` extend a common base-class, which includes parameter-management/interpolation functions.
    * (*Note: Initially tried doing this as a trait, but traits aren't allowed to define constants.*)

6 years ago(dev/core#217) CRM_Contact_Selector::getRows() - Use generator instead of DAO loop
Tim Otten [Fri, 29 Jun 2018 21:35:47 +0000 (14:35 -0700)]
(dev/core#217) CRM_Contact_Selector::getRows() - Use generator instead of DAO loop

Currently, cached data is read from MySQL, so it's OK to treat `$result` as
DAO.  However, eventually, we'll cache in a different data-source, and (when
dealing with multiple backend) it'll be easier to support a
`Generator<Object>` rather than `CRM_Core_DAO`.

See also: http://php.net/manual/en/language.generators.overview.php

6 years ago(dev/core#217) CRM_Core_DAO - Add a helper which returns results in generator format
Tim Otten [Fri, 29 Jun 2018 20:58:11 +0000 (13:58 -0700)]
(dev/core#217) CRM_Core_DAO - Add a helper which returns results in generator format

6 years agodev/core/issues/228 fix OptionGroup create action to not disable on update
eileen [Wed, 4 Jul 2018 04:04:35 +0000 (16:04 +1200)]
dev/core/issues/228 fix OptionGroup create action to not disable on update

6 years agoMerge pull request #12430 from JMAConsulting/dev-core-239
Eileen McNaughton [Fri, 6 Jul 2018 22:08:31 +0000 (10:08 +1200)]
Merge pull request #12430 from JMAConsulting/dev-core-239

dev/core#239 : Fix title dialog box on hovering form element on Event's configuration backend form

6 years agoMerge pull request #12422 from JMAConsulting/dev-core-176
Eileen McNaughton [Fri, 6 Jul 2018 22:03:31 +0000 (10:03 +1200)]
Merge pull request #12422 from JMAConsulting/dev-core-176

dev/core#176 Odd / Even street number sort column missing from Reports

6 years agoMerge pull request #12429 from eileenmcnaughton/comment
Monish Deb [Fri, 6 Jul 2018 09:43:59 +0000 (15:13 +0530)]
Merge pull request #12429 from eileenmcnaughton/comment

[NFC] Update comment link

6 years agodev/core#239 : Huge title dialog box on hovering form element on Event's configuratio...
deb.monish [Fri, 6 Jul 2018 09:38:41 +0000 (15:08 +0530)]
dev/core#239 : Huge title dialog box on hovering form element on Event's configuration backend form

6 years agoUpdate code link
eileen [Fri, 6 Jul 2018 08:17:00 +0000 (20:17 +1200)]
Update code link

6 years agoMerge pull request #12427 from totten/5.4-sqlgroup-ttl-1
Eileen McNaughton [Fri, 6 Jul 2018 08:05:14 +0000 (20:05 +1200)]
Merge pull request #12427 from totten/5.4-sqlgroup-ttl-1

(dev/core#174) CRM_Utils_Cache_SqlGroup - Refine trivial TTL handling to stabilize tests

6 years agoMerge pull request #12428 from civicrm/5.4
Eileen McNaughton [Fri, 6 Jul 2018 07:28:41 +0000 (19:28 +1200)]
Merge pull request #12428 from civicrm/5.4

5.4

6 years agoMerge pull request #12417 from aydun/core_124_template_upgrade
Seamus Lee [Fri, 6 Jul 2018 05:46:41 +0000 (15:46 +1000)]
Merge pull request #12417 from aydun/core_124_template_upgrade

Follow up to PR 12160 to update the DB version of the templates

6 years agoMerge pull request #12426 from totten/master-container-cache
Seamus Lee [Fri, 6 Jul 2018 05:46:13 +0000 (15:46 +1000)]
Merge pull request #12426 from totten/master-container-cache

Change default for CIVICRM_CONTAINER_CACHE to simplify admin/developer experience

6 years agoMerge pull request #12425 from seamuslee001/5_3_alpha1_fix
Seamus Lee [Fri, 6 Jul 2018 01:13:05 +0000 (11:13 +1000)]
Merge pull request #12425 from seamuslee001/5_3_alpha1_fix

Ensure db updates are run for 5.3.alpha1

6 years ago(dev/core#174) CRM_Utils_Cache_SqlGroup - Refine trivial TTL handling to stabilize...
Tim Otten [Fri, 6 Jul 2018 00:21:44 +0000 (17:21 -0700)]
(dev/core#174) CRM_Utils_Cache_SqlGroup - Refine trivial TTL handling to stabilize tests

Since incorporting `E2E_Cache_SqlGroupTest`, we've observed periodic flakiness in some
of the test-runs around code like this:

```php
  $cache->set("key", "value", 1);
  $get = $cache->get("key");
```

This makes the tests more reliable by refining the way `SqlGroup` handles trivially short TTLs.

Before
----------------------------------------
Cache items with `$ttl=1` may be expired before you ever get a chance to read them.

After
----------------------------------------
Cache items with `$ttl=1` may sometimes last slightly longer than a second
(if recorded late in the clock's current second), which improves the odds that
you'll be able to read the cache.

Technical Details
----------------------------------------
To reproduce the problem, run this script a few times via `cv scr`:

```php
<?php
$cache = CRM_Utils_Cache::create([
  'name' => 'tmp-cache',
  'type' => ['SqlGroup']
]);

for ($i = 0; $i < 500; $i++) {
  $cache->set("foo_$i", 'hi', 1);
  $get = $cache->get("foo_$i");
  if ($get !== 'hi') {
    echo "miss! ($i)\n";
  } else {
    echo ".";
  }
}
```

Given that `$cache->set()` and `$cache->get()` are right next to each other,
you would expect (and the test authors did evidently expect) that cache would be valid
long enough to read content. And yet we periodically have a cache-miss (particularly with
`SqlGroup`, which is a bit slower to handle writes).

For example, suppose `microtime()===100.95`.  If you compute expiration as
`$expires=time()+$ttl`, then `$expires===101`.  However, this means that
the cache's effective validity period is more like `~0.05` seconds rather
than a full second.

A more correct solution would be to track expiration times as microseconds.
However, that's a bigger patch, and we don't really need that level of
precision -- typical TTLs for us are more like "a week" or "a day" or "an
hour" or *maybe* "a minute".  The `$ttl=1` is a trivial scenario that only
makes sense for unit-testing.

This patch just rounds up the calculation of `$expires` -- in our
hypothetical at `microtime()===100.95`, that makes `$expires===102` and an
effective validity period of `~1.05` seconds.

6 years agoMerge pull request #12412 from eileenmcnaughton/conformance
Eileen McNaughton [Thu, 5 Jul 2018 23:21:10 +0000 (11:21 +1200)]
Merge pull request #12412 from eileenmcnaughton/conformance

Enable syntaxConformance on entities that now succeed

6 years agoMerge pull request #12406 from jitendrapurohit/core-212
Eileen McNaughton [Thu, 5 Jul 2018 22:57:14 +0000 (10:57 +1200)]
Merge pull request #12406 from jitendrapurohit/core-212

dev/core#212 - Contribution Details report fails when 'Is not one of'…

6 years agoMerge pull request #12414 from eileenmcnaughton/option_value
Seamus Lee [Thu, 5 Jul 2018 22:45:19 +0000 (08:45 +1000)]
Merge pull request #12414 from eileenmcnaughton/option_value

Simplify input params on OptionValue::addOptionValue

6 years agoChange default for CIVICRM_CONTAINER_CACHE to simplify admin/developer experience
Tim Otten [Thu, 5 Jul 2018 21:12:39 +0000 (14:12 -0700)]
Change default for CIVICRM_CONTAINER_CACHE to simplify admin/developer experience

In discussion of cache-related PRs for Civi 5.3, there were a few
reports/issues from developers observing `ServiceNotFoundException`.  This
is because there's not much awareness about how service-definitions are
cached.  It shouldn't be a significant issue for production systems running
vanilla code, but for admins and developers (who juggle patches/branches),
it can cause confusion/support-issues/false-failures.  This PR aims to
reduce those.

(This is a follow-up/substitute for #12401.)

Before
------
* The default value of `CIVICRM_CONTAINER_CACHE` is `always`.

After
-----
* The default value of `CIVICRM_CONTAINER_CACHE` is `auto`.

Technical Details
-----------------
The Symfony container essentially stores a list of "services".  In some
Symfony-based apps, building the list of services can be time consuming, so
it's common to cache this.

In Civi, this cache physically appears as
`files/civicrm/templates_c/CachedCiviContainer.*.php`.  The constant
`CIVICRM_CONTAINER_CACHE` determines how Civi manages the cache.  There are
three available policies:

* `never`: This means we never use the cache.  You never have to worry about
  staleness.  But it means we have to fire `hook_civicrm_container` on every
  page-request, and we go through any container-compilation tasks.
  This would have the fewest support-issues for devs and advanced admins.

* `always`: This means we always use whatever is in the cache.  It never
  (automatically) rebuilds the cache or checks freshness...  if you make
  change, then you must flush the cache explicitly.  This should be the
  fastest in production.

* `auto`: This means we typically use the cache (avoiding
  hooks/recompilation), but it has to `stat()` a half-dozen files to check
  the modification time.  (To wit: if the timestamp on
  `Civi/Core/Container.php` changes, then we discard the cache.)

Since performance is a consideration, I did some light benchmarking on my
laptop (fetching a basic public Civi page 100 times across 3 threads).

https://gist.github.com/totten/ec4bffd723afb7967aec56a3040b9ca3

In these results, the `never` policy appears to be ~15-20ms slower than
`auto` or `always`. `auto` is only ~2ms slower than `always`.

The other consideration is accuracy -- `auto` will usually re-compile if you
make a change, but there are some edge-cases where you must still flush
manually.  (In particular -- when you first implement
`hook_civicrm_container` in a new extension, it might not be aware of the
new extension.  And extensions need to call `$container->addResource()`.)

However, overall, `auto` is a pretty good compromise that's almost as fast
you can get and works out-of-the-box for many dev/admin scenarios.

6 years agoEnsure db updates are run for 5.3.alpha1
Seamus Lee [Thu, 5 Jul 2018 21:24:27 +0000 (07:24 +1000)]
Ensure db updates are run for 5.3.alpha1

6 years agoMerge pull request #12418 from eileenmcnaughton/totten
Tim Otten [Thu, 5 Jul 2018 20:53:16 +0000 (13:53 -0700)]
Merge pull request #12418 from eileenmcnaughton/totten

CRM_Core_BAO_PrevNextCache - Remove unused buildSelectedContactPager()

6 years agodev/core#212 - Contribution Details report fails when 'Is not one of' condition is...
Jitendra Purohit [Tue, 3 Jul 2018 11:59:37 +0000 (17:29 +0530)]
dev/core#212 - Contribution Details report fails when 'Is not one of' condition is used for Groups field

6 years agodev/core#176 Odd / Even street number filter missing from Reports
deb.monish [Thu, 5 Jul 2018 07:02:33 +0000 (12:32 +0530)]
dev/core#176 Odd / Even street number filter missing from Reports

6 years agoCRM_Core_BAO_PrevNextCache - Remove unused buildSelectedContactPager()
Tim Otten [Fri, 29 Jun 2018 21:10:23 +0000 (14:10 -0700)]
CRM_Core_BAO_PrevNextCache - Remove unused buildSelectedContactPager()

This does not appear to be used anywhere (based on grepping universe).

6 years agoFollow up to PR 12160 to update the DB version of the templates
Aidan Saunders [Wed, 4 Jul 2018 14:06:17 +0000 (15:06 +0100)]
Follow up to PR 12160 to update the DB version of the templates

6 years agoEnable syntaxConformance on entities that now succeed
eileen [Wed, 4 Jul 2018 05:00:21 +0000 (17:00 +1200)]
Enable syntaxConformance on entities that now succeed

6 years agoSet version to 5.5.alpha1
CiviCRM [Wed, 4 Jul 2018 20:04:16 +0000 (20:04 +0000)]
Set version to 5.5.alpha1

6 years agoSet version to 5.4.beta1
CiviCRM [Wed, 4 Jul 2018 19:53:35 +0000 (19:53 +0000)]
Set version to 5.4.beta1

6 years agoMerge pull request #11998 from compucorp/PCHR-3410-add-default-assignee-when-creating...
colemanw [Wed, 4 Jul 2018 14:35:37 +0000 (10:35 -0400)]
Merge pull request #11998 from compucorp/PCHR-3410-add-default-assignee-when-creating-cases

dev/core#107: Add default assignee when creating cases

6 years agodev/core#107 Refactor selection of default assignee by relationship type
René Olivo [Tue, 22 May 2018 20:51:23 +0000 (16:51 -0400)]
dev/core#107 Refactor selection of default assignee by relationship type

6 years agodev/core#107 Automatically add default assignees when creating new cases
René Olivo [Thu, 15 Mar 2018 16:00:05 +0000 (12:00 -0400)]
dev/core#107 Automatically add default assignees when creating new cases

This feature allows users to define default assignees for each activity in a case type.
When creating a new case contacts are assigned to activities automatically by following
one of these rules:

* By relationship to case client
* The user creating the case
* A specific contact
* None (default)

6 years agoSimplify input params on OptionValue::addOptionValue
eileen [Wed, 4 Jul 2018 08:09:03 +0000 (20:09 +1200)]
Simplify input params on OptionValue::addOptionValue

The addOptionValue function is one we should probably deprecate/ remove but towards that we should
start to remove it. This commit removes some complexity by passing option_group_name rather than
groupParams - which is a more accurate reflection of usage and removes ambiguity around the passing
by reference

6 years agoMerge pull request #12411 from eileenmcnaughton/matt_opt
Eileen McNaughton [Wed, 4 Jul 2018 07:52:01 +0000 (19:52 +1200)]
Merge pull request #12411 from eileenmcnaughton/matt_opt

Fix sample custom data is_reserved=0

6 years agoMerge pull request #12403 from civicrm/5.3
Eileen McNaughton [Wed, 4 Jul 2018 06:11:11 +0000 (18:11 +1200)]
Merge pull request #12403 from civicrm/5.3

5.3

6 years agoMerge pull request #12409 from eileenmcnaughton/paydata
Eileen McNaughton [Wed, 4 Jul 2018 06:10:52 +0000 (18:10 +1200)]
Merge pull request #12409 from eileenmcnaughton/paydata

dev/core/issues/211 Fix mis-allocation of financial transactions when editing payment method on a completed payment

6 years agoAdd late changes
Eileen McNaughton [Wed, 4 Jul 2018 06:10:35 +0000 (18:10 +1200)]
Add late changes

6 years agoFix mis-allocation of financial transactions
eileen [Tue, 3 Jul 2018 23:52:22 +0000 (11:52 +1200)]
Fix mis-allocation of financial transactions

Per

https://lab.civicrm.org/dev/core/issues/211 there seems to be an issue with assigning entity_financial_trxn
entries the wrong financial_trxn_id - I cannot find any recent change that would have caused this
(unless it's simply the greater use of the payment edit block) - it has been reported as working in
5.0.2.

6 years agoFix sample custom data is_reserved=0
Matthew Wire [Tue, 29 May 2018 21:00:39 +0000 (22:00 +0100)]
Fix sample custom data is_reserved=0

6 years agoMerge pull request #12233 from mattwire/optiongroup_form
Eileen McNaughton [Wed, 4 Jul 2018 04:38:18 +0000 (16:38 +1200)]
Merge pull request #12233 from mattwire/optiongroup_form

dev/core#155 Improve Option Groups form

6 years agoMerge pull request #12296 from eileenmcnaughton/greeting
Seamus Lee [Wed, 4 Jul 2018 02:22:45 +0000 (12:22 +1000)]
Merge pull request #12296 from eileenmcnaughton/greeting

Use email_greeting where possible in receipts

6 years agoMerge pull request #12408 from eileenmcnaughton/location_id
Eileen McNaughton [Wed, 4 Jul 2018 02:14:08 +0000 (14:14 +1200)]
Merge pull request #12408 from eileenmcnaughton/location_id

Add location_id if missing CRM-20711.

6 years agoMerge pull request #12399 from eileenmcnaughton/jamie
Seamus Lee [Tue, 3 Jul 2018 23:15:04 +0000 (09:15 +1000)]
Merge pull request #12399 from eileenmcnaughton/jamie

dev/core/#/229 Fix fatal error on send test mail

6 years agoAdd location_id if missing CRM-20711.
eileen [Tue, 3 Jul 2018 22:29:40 +0000 (10:29 +1200)]
Add location_id if missing CRM-20711.

On a small number of installs it seems location_id is missing from the group_contact table. This adds if missing

6 years agoMerge pull request #12398 from agh1/5.3.0-releasenotes
Eileen McNaughton [Tue, 3 Jul 2018 22:24:06 +0000 (10:24 +1200)]
Merge pull request #12398 from agh1/5.3.0-releasenotes

5.3.0 release notes

6 years agoMerge pull request #12362 from totten/master-cache-session
Eileen McNaughton [Tue, 3 Jul 2018 22:20:13 +0000 (10:20 +1200)]
Merge pull request #12362 from totten/master-cache-session

(dev/core#174) Forms/Sessions - Store state via Civi::cache('session')

6 years agoMerge pull request #12391 from eileenmcnaughton/matt
Eileen McNaughton [Tue, 3 Jul 2018 22:02:58 +0000 (10:02 +1200)]
Merge pull request #12391 from eileenmcnaughton/matt

Revert change to BillingBlock to support hidden fields.

6 years agoFix fatal error on send test mail
eileen [Tue, 3 Jul 2018 02:21:30 +0000 (14:21 +1200)]
Fix fatal error on send test mail

6 years agoMerge pull request #12400 from seamuslee001/dev_core_227
Seamus Lee [Tue, 3 Jul 2018 07:53:27 +0000 (17:53 +1000)]
Merge pull request #12400 from seamuslee001/dev_core_227

dev/core#227 Fix issue where on some extened groups the multiple reco…

6 years agoMerge pull request #12394 from yashodha/dev-223
Eileen McNaughton [Tue, 3 Jul 2018 04:11:53 +0000 (16:11 +1200)]
Merge pull request #12394 from yashodha/dev-223

(dev/core#223) Expose prefix and suffix in reports

6 years agoAdd release notes for 5.2.2
CiviCRM [Wed, 20 Jun 2018 06:00:44 +0000 (06:00 +0000)]
Add release notes for 5.2.2

6 years agoAdd release notes for 5.2.1
Tim Otten [Fri, 8 Jun 2018 23:39:40 +0000 (23:39 +0000)]
Add release notes for 5.2.1

6 years ago5.3.0 release notes: combined, organized, added contributors, boilerplate
Andrew Hunt [Tue, 3 Jul 2018 02:15:20 +0000 (22:15 -0400)]
5.3.0 release notes: combined, organized, added contributors, boilerplate

Also removed redundant issues from 5.2.1 and 5.2.2

6 years ago5.3.0 release notes: my half of the issues
Andrew Hunt [Tue, 3 Jul 2018 01:50:06 +0000 (21:50 -0400)]
5.3.0 release notes: my half of the issues

6 years ago5.3.0 release notes: Alice part of release notes
Alice Frumin [Mon, 2 Jul 2018 20:37:32 +0000 (16:37 -0400)]
5.3.0 release notes: Alice part of release notes

6 years agodev/core#227 Fix issue where on some extened groups the multiple records checkbox...
Seamus Lee [Tue, 3 Jul 2018 02:24:09 +0000 (12:24 +1000)]
dev/core#227 Fix issue where on some extened groups the multiple records checkbox doesn't show this causes empty string to be passed in which was causing problems when working out if we needed to make changes to the custom value table

6 years agoMerge pull request #12393 from scardinius/core-222
Eileen McNaughton [Mon, 2 Jul 2018 20:26:01 +0000 (08:26 +1200)]
Merge pull request #12393 from scardinius/core-222

dev/core#222 - Fix importing contacts with dedupe rule

6 years agoMerge pull request #12389 from totten/master-psr16-xtest
Tim Otten [Mon, 2 Jul 2018 18:58:36 +0000 (11:58 -0700)]
Merge pull request #12389 from totten/master-psr16-xtest

(dev/core#174) Add test to prevent hidden interactions among caches

6 years ago5.3.0 release notes: raw from script
Andrew Hunt [Mon, 2 Jul 2018 17:37:55 +0000 (13:37 -0400)]
5.3.0 release notes: raw from script

6 years ago(dev/core#223) Expose prefix and suffix in reports
yashodha [Mon, 2 Jul 2018 10:47:38 +0000 (16:17 +0530)]
(dev/core#223) Expose prefix and suffix in reports

6 years agoMerge pull request #12340 from eileenmcnaughton/merge_cleanup
Eileen McNaughton [Mon, 2 Jul 2018 09:33:41 +0000 (21:33 +1200)]
Merge pull request #12340 from eileenmcnaughton/merge_cleanup

Move DAO function to DAO class, call it from Merge class

6 years agodev/core#222 - Fix importing contacts with dedupe rule
scardinius [Mon, 2 Jul 2018 08:55:41 +0000 (10:55 +0200)]
dev/core#222 - Fix importing contacts with dedupe rule

6 years agoMerge pull request #12390 from yashodha/dev-220
Eileen McNaughton [Mon, 2 Jul 2018 08:36:49 +0000 (20:36 +1200)]
Merge pull request #12390 from yashodha/dev-220

(dev/core#220) State province/country doesn't show properly in the…

6 years agodev/core#221, check if the grouptree is not empty
madhavimalgaonkar [Mon, 2 Jul 2018 06:52:55 +0000 (12:22 +0530)]
dev/core#221, check if the grouptree is not empty

6 years agoRevert change to BillingBlock to support hidden fields.
eileen [Mon, 2 Jul 2018 05:50:01 +0000 (17:50 +1200)]
Revert change to BillingBlock to support hidden fields.

Per discussion with Matt Wire this is actually unnecessary, if we define 'id' in the payment fields
metadata. This is a bit too much like spooky magic but it ... erm .. works

6 years agocore/issues#220 - State province/country doesn't show properly in the history report
yashodha [Mon, 2 Jul 2018 05:32:51 +0000 (11:02 +0530)]
core/issues#220 - State province/country doesn't show properly in the history report

6 years ago(dev/core#174) Forms/Sessions - Clear in roughly the same ways as before
Tim Otten [Thu, 28 Jun 2018 03:19:58 +0000 (20:19 -0700)]
(dev/core#174) Forms/Sessions - Clear in roughly the same ways as before

In the past, if one clears the `civicrm_cache` table (i.e.  by calling
`CRM_Core_Config::clearDBCache()` ==> `TRUNCATE TABLE civicrm_cache`), then it
has the effect of destroying any active sessions/forms.

Now, in allowing sessions to be stored elsewhere, we lose that side-effect.

If we want strictly equivalent behavior (from a business-logic perspective),
then we'd want the patch to go a bit further -- calling
Civi::cache('session')->clear() at the same time that it does
`clearDBCache()`.

This revision adds `clear()` calls to various spots discussed here:

* https://docs.google.com/spreadsheets/d/1FxuIvr2noelBvhu5eja9_ps3YUWnkmGhqijBO3gH8Po/edit?usp=sharing
* https://github.com/civicrm/civicrm-core/pull/12362#issuecomment-400897782

6 years ago(dev/core#174) Forms/Sessions - Store state via Civi::cache('session')
Tim Otten [Thu, 29 Mar 2018 01:52:57 +0000 (18:52 -0700)]
(dev/core#174) Forms/Sessions - Store state via Civi::cache('session')

Overview
----------------------------------------

When using forms based on CiviQuickForm (specifically `CRM_Core_Controller`), `CRM_Core_Session`
stores form-state via `CRM_Core_BAO_Cache::storeSessionToCache` and `::restoreSessionFromCache`,
which in turn calls `CRM_Core_BAO_Cache::setItem()` and `::getItem()`.

However, using `CRM_Core_BAO_Cache::setItem()` and `::getItem()` means that all session state
**must** be written to MySQL.  For dev/core#174, we seek the **option** to store via
Redis/Memcache.

Before
----------------------------------------

* (a) Form/session state is always stored via `CRM_Core_BAO_Cache::setItem()` and `civicrm_cache` table.
* (b) To ensure that old sessions are periodically purged, there is special purpose logic that accesses `civicrm_cache`
  (roughly `delete where group_name=Sessions and  created_date < now()-ttl`).
* (c) On Memcache/Redis-enabled systems, the cache server functions as an extra tier. The DB provides canonical storage for form/session state.

After
----------------------------------------

* (a) Form/session state is stored via `CRM_Utils_CacheInterface`.
    * On a typical server, this defaults to `CRM_Utils_Cache_SqlGroup` and `civicrm_cache` table.
* (b) To ensure that old sessions are periodically purged, the call to `CRM_Utils_CacheInterface::set()` specifies a TTL.
    * It is the responsibility of the cache driver to handle TTLs. With #12360, TTL's are supported in `ArrayCache`, `SqlGroup`, and `Redis`.
* (c) On Memcache/Redis-enabled systems, the cache server provides canonical storage for form/session state.

6 years ago(dev/core#174) Add test to prevent hidden interactions among caches
Tim Otten [Thu, 28 Jun 2018 17:35:55 +0000 (10:35 -0700)]
(dev/core#174) Add test to prevent hidden interactions among caches

6 years agoMerge pull request #12379 from totten/master-psr16-sqlgroup
Eileen McNaughton [Mon, 2 Jul 2018 03:13:27 +0000 (15:13 +1200)]
Merge pull request #12379 from totten/master-psr16-sqlgroup

(dev/core#174) Full PSR-16 compliance for SqlGroup

6 years agoMerge pull request #12386 from mattwire/IPN_NFC
Eileen McNaughton [Mon, 2 Jul 2018 00:11:58 +0000 (12:11 +1200)]
Merge pull request #12386 from mattwire/IPN_NFC

NFC code cleanup for AuthNet, Paypal, PaypalPro IPNs