Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/core
diff options
context:
space:
mode:
Diffstat (limited to 'core')
-rw-r--r--core/API/DataTableManipulator/Flattener.php1
-rw-r--r--core/Http.php7
-rw-r--r--core/Measurable/Type/TypeManager.php11
-rw-r--r--core/Settings/FieldConfig.php8
-rw-r--r--core/Settings/Measurable/MeasurableProperty.php2
-rw-r--r--core/Settings/Settings.php4
-rw-r--r--core/Settings/Storage/Factory.php8
-rw-r--r--core/Site.php2
-rw-r--r--core/Version.php2
9 files changed, 39 insertions, 6 deletions
diff --git a/core/API/DataTableManipulator/Flattener.php b/core/API/DataTableManipulator/Flattener.php
index fbcd36d068..1fc5edc359 100644
--- a/core/API/DataTableManipulator/Flattener.php
+++ b/core/API/DataTableManipulator/Flattener.php
@@ -65,6 +65,7 @@ class Flattener extends DataTableManipulator
// this recursive filter will be applied to subtables
$dataTable->filter('ReplaceSummaryRowLabel');
+ $dataTable->filter('ReplaceColumnNames');
$this->flattenDataTableInto($dataTable, $newDataTable);
diff --git a/core/Http.php b/core/Http.php
index 373c4815d9..79ee0d2af3 100644
--- a/core/Http.php
+++ b/core/Http.php
@@ -162,7 +162,7 @@ class Http
$fileLength = 0;
if (!empty($requestBody) && is_array($requestBody)) {
- $requestBody = http_build_query($requestBody);
+ $requestBody = self::buildQuery($requestBody);
}
// Piwik services behave like a proxy, so we should act like one.
@@ -629,6 +629,11 @@ class Http
}
}
+ public static function buildQuery($params)
+ {
+ return http_build_query($params, '', '&');
+ }
+
private static function buildHeadersForPost($requestBody)
{
$postHeader = "Content-Type: application/x-www-form-urlencoded\r\n";
diff --git a/core/Measurable/Type/TypeManager.php b/core/Measurable/Type/TypeManager.php
index a514abbbdc..8a886d29d5 100644
--- a/core/Measurable/Type/TypeManager.php
+++ b/core/Measurable/Type/TypeManager.php
@@ -29,6 +29,17 @@ class TypeManager
return $instances;
}
+ public function isExistingType($typeId)
+ {
+ foreach ($this->getAllTypes() as $type) {
+ if ($type->getId() === $typeId) {
+ return true;
+ }
+ }
+
+ return false;
+ }
+
/**
* @param string $typeId
* @return Type|null
diff --git a/core/Settings/FieldConfig.php b/core/Settings/FieldConfig.php
index f7f6bf97b3..ef8a6155e2 100644
--- a/core/Settings/FieldConfig.php
+++ b/core/Settings/FieldConfig.php
@@ -92,6 +92,14 @@ class FieldConfig
public $uiControl = null;
/**
+ * Defines a custom template file for a UI control. This file should render a UI control and expose the value in a
+ * "formField.value" angular model. For an example see "plugins/CorePluginsAdmin/angularjs/form-field/field-text.html"
+ *
+ * @var string
+ */
+ public $customUiControlTemplateFile = '';
+
+ /**
* Name-value mapping of HTML attributes that will be added HTML form control, eg,
* `array('size' => 3)`. Attributes will be escaped before outputting.
*
diff --git a/core/Settings/Measurable/MeasurableProperty.php b/core/Settings/Measurable/MeasurableProperty.php
index b49ee04698..ebf03635ca 100644
--- a/core/Settings/Measurable/MeasurableProperty.php
+++ b/core/Settings/Measurable/MeasurableProperty.php
@@ -34,7 +34,7 @@ class MeasurableProperty extends \Piwik\Settings\Setting
'ecommerce', 'sitesearch', 'sitesearch_keyword_parameters',
'sitesearch_category_parameters',
'exclude_unknown_urls', 'excluded_ips', 'excluded_parameters',
- 'excluded_user_agents', 'keep_url_fragment', 'urls'
+ 'excluded_user_agents', 'keep_url_fragment', 'urls', 'group'
);
/**
diff --git a/core/Settings/Settings.php b/core/Settings/Settings.php
index 8181502c7b..2ceffb7948 100644
--- a/core/Settings/Settings.php
+++ b/core/Settings/Settings.php
@@ -93,13 +93,13 @@ abstract class Settings
}
/**
- * Makes a new plugin setting available.
+ * Adds a new setting to the settings container.
*
* @param Setting $setting
* @throws \Exception If there is a setting with the same name that already exists.
* If the name contains non-alphanumeric characters.
*/
- protected function addSetting(Setting $setting)
+ public function addSetting(Setting $setting)
{
$name = $setting->getName();
diff --git a/core/Settings/Storage/Factory.php b/core/Settings/Storage/Factory.php
index 2ca3deb17c..8336c58f3e 100644
--- a/core/Settings/Storage/Factory.php
+++ b/core/Settings/Storage/Factory.php
@@ -125,7 +125,13 @@ class Factory
return new Storage(new Backend\NullBackend($key));
}
- private function makeStorage(BackendInterface $backend)
+ /**
+ * Makes a new storage object based on a custom backend interface.
+ *
+ * @param BackendInterface $backend
+ * @return Storage
+ */
+ public function makeStorage(BackendInterface $backend)
{
if (SettingsServer::isTrackerApiRequest()) {
$backend = new Backend\Cache($backend);
diff --git a/core/Site.php b/core/Site.php
index a45a4a5e2e..97381cab04 100644
--- a/core/Site.php
+++ b/core/Site.php
@@ -65,6 +65,8 @@ class Site
$this->id = (int)$idsite;
if (!isset(self::$infoSites[$this->id])) {
$site = API::getInstance()->getSiteFromId($this->id);
+ $sites = array(&$site);
+ self::triggerSetSitesEvent($sites);
self::setSiteFromArray($this->id, $site);
}
}
diff --git a/core/Version.php b/core/Version.php
index ab4135b6b7..a341f70c92 100644
--- a/core/Version.php
+++ b/core/Version.php
@@ -20,7 +20,7 @@ final class Version
* The current Piwik version.
* @var string
*/
- const VERSION = '3.0.0-rc1';
+ const VERSION = '3.0.0-rc2';
public function isStableVersion($version)
{