Tim Otten [Wed, 8 Jul 2020 00:10:17 +0000 (17:10 -0700)]
Setup UI - Allow callers to wrap UI in their own page chrome. Clarify response format.
The general idiom for calling SetupController is like this:
```php
$ctrl = \Civi\Setup::instance()->createController()->getCtrl();
$ctrl->setUrls(...);
\Civi\Setup\BasicRunner::run($ctrl);
```
This changes the data exchanged between `BasicRunner` and `SetupController`
to allow more flexible runners. The `BasicRunner` is the only one currently
used by existing installers, so it's drop-in compatible.
Before
------
The `BasicRunner` calls `$ctrl->run(...)` and gets back an array with the response data
(`[0 => $headers, 1 => $body]`).
After
-----
The `BasicRunner` calls `$ctrl->run(...)` and gets back a `SetupResponse`. This
object provides the `[0]` and `[1]` keys (for backward compat), but it's better
to access the object properties (`$headers`, `$body`, etc).
It provides several additional properties - eg `$title`, `$assets`, `$code`.
Technical Details
------------------
This is a drop-in update for anything that uses `BasicRunner`.
Strictly speaking, if one wrote a different runner, it may or may not be
drop-in compatible. But since I don't think there are any others, it's not
really worth spending much energy on verifying.
The bump in `Setup::PROTOCOL` (`1.0` => `1.1`) indicates that old installers
should generally be forward compatible with this protocol. However, if one
writes a new installer and specifically uses the `SetupResponse` type,
then they should assert protocol `1.1`.
Tim Otten [Tue, 7 Jul 2020 21:59:37 +0000 (14:59 -0700)]
setup/ - Fix CSS loading on "finished" page. Split out "page.php".
The various `finished.*.php` files were outtputting the incorrect URL for
`template.css`. The code for outputting `template.css` is duplicated in a few files.
This commit fixes by extracting a helper (`renderPage()` / `page.php`) to encapsulate
that bit and reuse it for each page-view in the Setup UI.
Tim Otten [Tue, 7 Jul 2020 23:07:49 +0000 (16:07 -0700)]
Setup UI - Fix translation of post-install messages
Here's what happens:
- The "Setup" subsystem does its internal/partial bootstrap; it sets `$tsLocale` and uses `CRM_Core_I18n`. Hooray.
- The "Setup" initializes the database/settings and then does a full bootstrap. The full bootstrap step calls `applyLocale()`, which replaces the active `$tsLocale`... with the *unconfigured default*. Ooops.
- This step runs next - and it updates the DB setting. But we've already trampled `$tsLocale`. Calling `applyLocale()` a second time means we use the preferred `$tsLocale` again. Hooray.
Tim Otten [Mon, 6 Jul 2020 08:46:37 +0000 (01:46 -0700)]
Drupal.civi-setup.php - Don't assume that `$language` is available
Tim Otten [Mon, 6 Jul 2020 08:31:35 +0000 (01:31 -0700)]
finished.Drupal.php - Let it work!
Tim Otten [Mon, 6 Jul 2020 08:18:49 +0000 (01:18 -0700)]
FlushDrupal.civi-setup.php - Update to work with setup UI
Tim Otten [Sat, 4 Jul 2020 04:44:14 +0000 (21:44 -0700)]
FlushBackdrop.civi-setup.php - Update to work with setup UI
Tim Otten [Sat, 4 Jul 2020 03:52:18 +0000 (20:52 -0700)]
finished.Backdrop.php - Fix the FIXMEs. Align closer to finished.Drupal.php
Tim Otten [Sat, 4 Jul 2020 05:34:50 +0000 (22:34 -0700)]
setup/res/template.css - Fix "Sample Data" alignment
This rule appears to be targetted at "Components" section, but it actually affects the entire document
Consequently, the "Localization" and "Sample Data" segments bleed together weirdly.
Tim Otten [Sat, 4 Jul 2020 04:03:19 +0000 (21:03 -0700)]
setup/res/template.css - Twiddle column width
The aim is to have 3 columns (each 1/3 of the screen width) and allow for
some padding in between. Unfortunately, the current formulation is futzy.
In my browser, when viewing on Backdrop, the columns are just slightly too
wide (causing them to wrap prematurely).
There must be a better way to do this, but it's not my main issue right now.
Twiddling is better than status quo.
Tim Otten [Sat, 4 Jul 2020 03:54:49 +0000 (20:54 -0700)]
SetupController - Need better bootstrap to support localization
While trying the setup UI on Backdrop, I found that changing the language
led to a crash. The problem: it needed to load the `l10n` files, which led
to more path resolution, which led to failures - because `civicrm.settings.php`
hasn't been loaded. (It doesn't exist yet!)
Fortunately, most of the needful information is available. The
`Setup::init()` should have found the info and put it into `$model`. We
just need to load the configuration into the right globals/constants.
Tim Otten [Sat, 4 Jul 2020 03:51:31 +0000 (20:51 -0700)]
SetupController - If you install and then reload the install screen, re-render the finish message.
Eileen McNaughton [Sun, 5 Jul 2020 22:53:53 +0000 (10:53 +1200)]
Merge pull request #17746 from colemanw/apiExpHaving
APIv4 Explorer: Improve selection of fields for HAVING
Eileen McNaughton [Sun, 5 Jul 2020 22:51:18 +0000 (10:51 +1200)]
Merge pull request #17756 from demeritcowboy/unused-gencode-2
More unused functions in GenCode
Eileen McNaughton [Sun, 5 Jul 2020 22:47:55 +0000 (10:47 +1200)]
Merge pull request #17758 from mattwire/wpaclpermsphpnotice
Fix PHP notice on wordpress permissions form
Eileen McNaughton [Sun, 5 Jul 2020 22:47:04 +0000 (10:47 +1200)]
Merge pull request #17645 from MegaphoneJon/core-1826
core#1826: Ignore location_type_id when deduping postal address
Matthew Wire [Sun, 5 Jul 2020 16:38:00 +0000 (17:38 +0100)]
Fix PHP notice on wordpress ACL permissions form
Seamus Lee [Sun, 5 Jul 2020 08:45:07 +0000 (18:45 +1000)]
Merge pull request #17755 from demeritcowboy/test-activity-tag-search
[Unit Test] dev/core#1173 and dev/core#1827 - Test for activity tag search - PR 17655
Seamus Lee [Sun, 5 Jul 2020 05:02:51 +0000 (15:02 +1000)]
Merge pull request #17757 from colemanw/karmaTime
Convert CRM.utils.formatDate tests to karma
Coleman Watts [Sun, 5 Jul 2020 03:29:57 +0000 (23:29 -0400)]
Convert CRM.utils.formatDate tests to karma
Eileen McNaughton [Sun, 5 Jul 2020 03:11:09 +0000 (15:11 +1200)]
Merge pull request #17655 from samuelsov/lab1827
dev/core#1827 activity search - fixing search by tags
demeritcowboy [Sun, 5 Jul 2020 02:55:57 +0000 (22:55 -0400)]
unused functions
demeritcowboy [Sun, 5 Jul 2020 02:43:39 +0000 (22:43 -0400)]
test for activity tag search
Eileen McNaughton [Sun, 5 Jul 2020 02:33:30 +0000 (14:33 +1200)]
Merge pull request #17753 from demeritcowboy/unused-gencode
Unused functions in GenCode
Eileen McNaughton [Sun, 5 Jul 2020 02:18:48 +0000 (14:18 +1200)]
Merge pull request #17751 from civicrm/5.28
5.28
colemanw [Sun, 5 Jul 2020 01:54:44 +0000 (21:54 -0400)]
Merge pull request #17684 from colemanw/time
Teach CRM.utils.formatDate to also show time
Coleman Watts [Wed, 24 Jun 2020 00:05:56 +0000 (20:05 -0400)]
Teach CRM.utils.formatDate to also show time
demeritcowboy [Sat, 4 Jul 2020 23:52:14 +0000 (19:52 -0400)]
unused functions
colemanw [Sat, 4 Jul 2020 19:45:47 +0000 (15:45 -0400)]
Merge pull request #17748 from demeritcowboy/double-vision
Pre-upgrade message for php-intl shows twice
demeritcowboy [Fri, 3 Jul 2020 23:27:57 +0000 (19:27 -0400)]
only show message once
Seamus Lee [Fri, 3 Jul 2020 22:25:16 +0000 (08:25 +1000)]
Merge pull request #17747 from mlutfy/fixReportGroupbyTpl
Fix typo in templates/CRM/Report/Form/Tabs/GroupBy.tpl
Jon Goldberg [Fri, 3 Jul 2020 22:02:43 +0000 (18:02 -0400)]
test for ignoring location_type_id on import
Jon Goldberg [Fri, 3 Jul 2020 21:56:54 +0000 (17:56 -0400)]
Ignore location_type_id for dedupe on import also
Mathieu Lutfy [Fri, 3 Jul 2020 18:28:04 +0000 (14:28 -0400)]
Fix typo in templates/CRM/Report/Form/Tabs/GroupBy.tpl
Coleman Watts [Fri, 3 Jul 2020 18:12:08 +0000 (14:12 -0400)]
APIv4 Explorer: Improve selection of fields for HAVING
Seamus Lee [Fri, 3 Jul 2020 06:01:43 +0000 (16:01 +1000)]
Merge pull request #17741 from eileenmcnaughton/eventcart
Add eventcart shell
CiviCRM [Fri, 3 Jul 2020 05:55:14 +0000 (05:55 +0000)]
Set version to 5.29.alpha1
CiviCRM [Fri, 3 Jul 2020 05:22:47 +0000 (05:22 +0000)]
Set version to 5.28.beta1
Eileen McNaughton [Fri, 3 Jul 2020 04:04:08 +0000 (16:04 +1200)]
Merge pull request #17733 from eileenmcnaughton/pvv
Set locales for all domains when enabling multilingual
Eileen McNaughton [Fri, 3 Jul 2020 02:48:03 +0000 (14:48 +1200)]
Merge pull request #17721 from colemanw/isDeletedPerm
Add permission metadata to contact is_deleted field
eileen [Thu, 2 Jul 2020 22:14:54 +0000 (10:14 +1200)]
Add eventcart shell
Tim Otten [Fri, 3 Jul 2020 02:01:34 +0000 (19:01 -0700)]
Merge pull request #17738 from colemanw/upgradeLocales
dev/core#1852 Ensure all domains have the same value for locales
Seamus Lee [Fri, 3 Jul 2020 01:57:58 +0000 (11:57 +1000)]
Ensure that we are testing on multiple domains
Co-authored-by: colemanw <coleman@civicrm.org>
Seamus Lee [Thu, 2 Jul 2020 21:58:55 +0000 (07:58 +1000)]
Merge pull request #17739 from colemanw/byeByeWiki
[NFC] Fix some outdated wiki links
Coleman Watts [Thu, 2 Jul 2020 20:42:07 +0000 (16:42 -0400)]
Fix some outdated wiki links
Coleman Watts [Wed, 1 Jul 2020 02:16:49 +0000 (22:16 -0400)]
Add permission metadata to contact is_deleted field
colemanw [Thu, 2 Jul 2020 17:20:49 +0000 (13:20 -0400)]
Merge pull request #17737 from christianwach/lab-core-1851
Fix saving of State/Province Multi-select values
Coleman Watts [Thu, 2 Jul 2020 17:09:20 +0000 (13:09 -0400)]
Ensure all domains have the same value for locales
Christian Wach [Thu, 2 Jul 2020 14:39:24 +0000 (15:39 +0100)]
Fix saving of State/Province Multi-select values
Seamus Lee [Thu, 2 Jul 2020 04:02:24 +0000 (14:02 +1000)]
Merge pull request #17736 from civicrm/5.27
5.27
Seamus Lee [Thu, 2 Jul 2020 03:14:57 +0000 (13:14 +1000)]
Merge pull request #17731 from agh1/5.27.0-releasenotes-final
5.27.0 release notes: final edits
Eileen McNaughton [Thu, 2 Jul 2020 02:52:32 +0000 (14:52 +1200)]
Merge pull request #17735 from totten/master-field-ver
API/DAO Metadata - Retain versioning metadata for possible usage in runtime+tooling
Tim Otten [Thu, 2 Jul 2020 02:17:21 +0000 (19:17 -0700)]
Update 5.27.0.md
Tim Otten [Thu, 2 Jul 2020 02:02:36 +0000 (19:02 -0700)]
Update 5.27.0.md
eileen [Thu, 2 Jul 2020 00:36:13 +0000 (12:36 +1200)]
Set locales for all domains when enabling multilingual
In the process of trying to test a possible wordpress regression I found that enabling
mutlilingual on a domain other than domain 1 breaks the site. The reason is that without
only domain 1 is being updated with the new language and locales. Since I'm on domain
2 when I do this I can no longer load any page as the locales value has not been set
and the queries look for option_value.label not option_value.label_us.
Since 'no locale' is no longer valid the locale needs to be set on all sites. Note the
code change is primarily an extraction inn order to only run the table update part once
Seamus Lee [Thu, 2 Jul 2020 01:50:20 +0000 (11:50 +1000)]
Merge pull request #17732 from civicrm/5.27
5.27
Seamus Lee [Thu, 2 Jul 2020 01:36:48 +0000 (11:36 +1000)]
Merge pull request #17722 from eileenmcnaughton/up
dev/core#1846 Regression (sorta) Hacks to avoid failure on upgrade due to new field not yet being in the DB
Coleman Watts [Wed, 1 Jul 2020 15:12:23 +0000 (11:12 -0400)]
API/DAO Metadata - Retain versioning metadata for possible usage in runtime+tooling
Seamus Lee [Thu, 2 Jul 2020 00:17:50 +0000 (10:17 +1000)]
[NFC] Update Domain version number in tests to be at test v5.27.alpha1
Seamus Lee [Wed, 1 Jul 2020 23:53:50 +0000 (09:53 +1000)]
Merge pull request #17725 from eileenmcnaughton/pvv
Ensure pricefield value label column is not null on upgrade
Seamus Lee [Wed, 1 Jul 2020 23:10:41 +0000 (09:10 +1000)]
Ensure that the unexpected version check doesn't show if the version matches
Seamus Lee [Wed, 1 Jul 2020 22:51:28 +0000 (08:51 +1000)]
Fix logical errors and fix ENV file as well
Eileen McNaughton [Wed, 1 Jul 2020 22:42:55 +0000 (10:42 +1200)]
Merge pull request #17669 from seamuslee001/flexmailer_core
[REF] Ship Flexmailer extension with Core
Seamus Lee [Wed, 1 Jul 2020 22:39:22 +0000 (08:39 +1000)]
Merge pull request #17730 from agh1/moneyformatcheckgrammar
dev/core#1494 System check for moneyvalueformat: grammar & clarity
Seamus Lee [Wed, 1 Jul 2020 22:21:32 +0000 (08:21 +1000)]
Merge pull request #17727 from MegaphoneJon/fix-lcd
[NFC] Fix contributor key for Lighthouse Consulting and Design
Seamus Lee [Wed, 1 Jul 2020 22:21:06 +0000 (08:21 +1000)]
Merge pull request #17728 from agh1/php-intl-upgrade-message
dev/translation#48: fix up system check grammar and add pre-upgrade message.
eileen [Wed, 1 Jul 2020 13:13:52 +0000 (01:13 +1200)]
Ensure pricefield value label column is not null on upgrade
On testing locally I found I did have a null value in a field & this fatalled if I enabled
multilingual
Andrew Hunt [Wed, 1 Jul 2020 22:05:02 +0000 (18:05 -0400)]
5.27.0 release notes: further edits
Andrew Hunt [Wed, 1 Jul 2020 21:23:26 +0000 (17:23 -0400)]
dev/core#1494 System check for moneyvalueformat: grammar & clarity
colemanw [Wed, 1 Jul 2020 17:14:06 +0000 (13:14 -0400)]
Merge pull request #17726 from colemanw/noWiki
Remove obsolete function formatWikiURL
Andrew Hunt [Wed, 1 Jul 2020 15:59:28 +0000 (11:59 -0400)]
PHP-Intl: fix up system check grammar and add pre-upgrade message.
Jon Goldberg [Wed, 1 Jul 2020 14:54:51 +0000 (10:54 -0400)]
Fix contributor key for Lighthouse Consulting and Design
Coleman Watts [Wed, 1 Jul 2020 14:31:29 +0000 (10:31 -0400)]
Fix version check for custom field serialize col
Coleman Watts [Wed, 1 Jul 2020 14:07:06 +0000 (10:07 -0400)]
Mark unused functions as deprecated and update doc link
Coleman Watts [Wed, 1 Jul 2020 13:33:57 +0000 (09:33 -0400)]
Remove obsolete function formatWikiURL
Seamus Lee [Sat, 20 Jun 2020 08:06:25 +0000 (18:06 +1000)]
[REF] Ship Flexmailer extension with Core
eileen [Wed, 1 Jul 2020 05:31:36 +0000 (17:31 +1200)]
Hacks to avoid failure on upgrade due to new field not yet being in the DB
On attempting to upgrade I found I couldn't get to the upgrade screen add the new serialize field as
I got fatal errors in these 2 places (maybe more to come).
The new field is civicrm_custom_field.serialize
Eileen McNaughton [Wed, 1 Jul 2020 04:40:53 +0000 (16:40 +1200)]
Merge pull request #17701 from demeritcowboy/name-label-accountrelationship
dev/wordpress#61 - Financial Account by Relationship lookup is incorrectly using label not name
Eileen McNaughton [Wed, 1 Jul 2020 04:00:52 +0000 (16:00 +1200)]
Merge pull request #17602 from mattwire/supportsrecurring
REF Access the method not the property directly to check if a payment processor supports recurring
Seamus Lee [Wed, 1 Jul 2020 01:26:16 +0000 (11:26 +1000)]
Merge pull request #17719 from civicrm/5.27
5.27
Seamus Lee [Tue, 30 Jun 2020 22:38:03 +0000 (08:38 +1000)]
Merge pull request #17720 from alifrumin/5.27.0-releasenotes
[NFC] 5.27 release notes - first pass
Alice Frumin [Tue, 30 Jun 2020 17:51:31 +0000 (13:51 -0400)]
5.27 release notes first pass
Seamus Lee [Tue, 30 Jun 2020 21:31:56 +0000 (07:31 +1000)]
Merge pull request #17718 from agh1/5.27.0-releasenotes
5.27.0 release notes - initial run
Seamus Lee [Tue, 30 Jun 2020 20:49:02 +0000 (06:49 +1000)]
Merge pull request #17716 from mattwire/setnamesutf8mb4
Connect to database using SET NAMES utf8mb4
Seamus Lee [Tue, 30 Jun 2020 20:45:02 +0000 (06:45 +1000)]
Merge pull request #17717 from colemanw/jsComments
Fix CRM_Utils_JS::dedupeClosures to ignore comments
Samuel Vanhove [Tue, 30 Jun 2020 20:15:54 +0000 (16:15 -0400)]
dev/core#1827 activity search - fixing search by tags - simple and tag set
Andrew Hunt [Tue, 30 Jun 2020 15:47:05 +0000 (11:47 -0400)]
5.27.0 release notes: added boilerplate
Andrew Hunt [Tue, 30 Jun 2020 15:44:23 +0000 (11:44 -0400)]
5.27.0 release notes: raw from script
Coleman Watts [Tue, 30 Jun 2020 15:40:26 +0000 (11:40 -0400)]
Fix CRM_Utils_JS::dedupeClosures to ignore comments
This runs stripComments BEFORE dedupeClosures so that comments don't interfere with the deduping.
Also fixes stripComments to remove the line break as well as the comment line.
Matthew Wire [Tue, 30 Jun 2020 13:18:00 +0000 (14:18 +0100)]
SET NAMES utf8mb4
Seamus Lee [Tue, 30 Jun 2020 01:41:19 +0000 (11:41 +1000)]
Merge pull request #17714 from colemanw/jsDocblocks
NFC cleanup docblocks in CRM_Utils_JS
Seamus Lee [Tue, 30 Jun 2020 01:28:03 +0000 (11:28 +1000)]
Merge pull request #17715 from civicrm/5.27
5.27
colemanw [Tue, 30 Jun 2020 00:46:42 +0000 (20:46 -0400)]
Merge pull request #17713 from MegaphoneJon/multi-record-import-fix-527
Multi record import screen fix
Coleman Watts [Tue, 30 Jun 2020 00:22:58 +0000 (20:22 -0400)]
NFC cleanup docblocks in CRM_Utils_JS
Seamus Lee [Tue, 30 Jun 2020 00:19:43 +0000 (10:19 +1000)]
Merge pull request #17712 from civicrm/5.27
5.27
Seamus Lee [Mon, 29 Jun 2020 23:04:08 +0000 (09:04 +1000)]
Merge pull request #17711 from colemanw/useStrict
CRM_Utils_JS - also dedupe 'use strict' directive when deduping closures
Jon Goldberg [Thu, 25 Jun 2020 16:26:02 +0000 (12:26 -0400)]
Multi record import screen fix
Seamus Lee [Mon, 29 Jun 2020 22:31:51 +0000 (08:31 +1000)]
Merge pull request #17676 from eileenmcnaughton/ct
[REF] Cleanup function for retrieving contact types.
Seamus Lee [Mon, 29 Jun 2020 22:27:38 +0000 (08:27 +1000)]
Merge pull request #17250 from eileenmcnaughton/act_search
Remove slow join from activity search
Seamus Lee [Mon, 29 Jun 2020 22:09:50 +0000 (08:09 +1000)]
Merge pull request #17710 from kcristiano/5.27-api4-joomla-install
dev/joomla/#28 5.27 Upgrade fails