diff options
author | Matthieu Aubry <mattab@users.noreply.github.com> | 2016-09-29 05:03:02 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-09-29 05:03:02 +0300 |
commit | bd5217287e84d8a2fdc457dd07ce63d78c5835b4 (patch) | |
tree | b0c4121eda233d3bfeeae29a482dc8f5a3d6304b /plugins/CorePluginsAdmin | |
parent | a8f682a6039e9b765e248c6be531cce54a7903d1 (diff) |
2.16.3-rc1 (#10590)2.16.3-rc1
* Fix depraction test: use assertDeprecatedMethodIsRemovedInPiwik3
* Fix Scheduled Reports sent one hour late in daylight saving timezones (#10443)
* convert hour to send report to/from UTC, to ensure it isn't affected by daylight savings
* adds update script to change existing scheduled reports to use utc time
* code improvement
* adds missing param
* Added new event Archiving.makeNewArchiverObject to allow customising plugin archiving (#10366)
* added hook to alllow plugin archiving prevention
* cr code style notes
* reworked PR to fit CR suggestions
* added PHPDoc for hook
* Event description more consistent
* UI tests: minor changes
* Comment out Visitor Log UI tests refs #10536
* Adds test checking if all screenshots are stored in lfs
* removed screenshots not stored in lfs
* readds screenshots to lfs
* 2.16.3-b4
* Issue translation updates against 2.x-dev
* language update
* Fix bug in widget list remove where the JSON object becomes array
* 2.16.3-rc1
* console command custom-piwik-js:update should work when directory is writable and file does not exist yet (#10576)
* followup #10449
* Fix test
(cherry picked from commit fac3d63)
* Prevent chmod(): No such file or directory
* Automatically update all marketplace plugins when updating Piwik (#10527)
* update plugins and piwik at the same time
* make sure plugins are updated with piwik
* use only one try/catch
* reload plugin information once it has been installed
* make sure to clear caches after an update
* fix ui tests
* make sure to use correct php version without any extras
* Additional informations passed in the hook "isExcludedVisit" (issue #10415) (#10564)
* Additional informations passed in the hook "isExcludedVisit" (issue #10415)
* Added better description to the new parameters
* Update VisitExcluded.php
* Remove two parameters not needed as better to use the Request object
* Update VisitExcluded.php
* remove extra two parameters in VisitExcluded constructor to prevent confusion (#10593)
* Update our libs to latest https://github.com/piwik/piwik/issues/10526
* Update composer libraries to latest https://github.com/piwik/piwik/issues/10526
* Update log analytics to latest
* When updating the config file failed (or when any other file is not writable...), the Updater (for core or plugins) will now automatically throw an error and cancel the update (#10423)
* When updating the config file failed (or when any other file is not writable...), the Updater (for core or plugins) will now automatically throw an error and cancel the update
* add integration test to check the correct exception is thrown when config not writabel
* New integration test for updater
* Make test better
* When opening the visitor profile, do not apply the segment (#10533)
* When opening the visitor profile, do not apply the segment
* added ui test for profile but does work for me
* next try to make ui test work
* add expected screenshot
* added missing doc
Diffstat (limited to 'plugins/CorePluginsAdmin')
-rw-r--r-- | plugins/CorePluginsAdmin/MarketplaceApiClient.php | 10 | ||||
-rw-r--r-- | plugins/CorePluginsAdmin/PluginInstaller.php | 9 | ||||
-rw-r--r-- | plugins/CorePluginsAdmin/config/config.php | 7 | ||||
-rw-r--r-- | plugins/CorePluginsAdmin/lang/es.json | 4 |
4 files changed, 29 insertions, 1 deletions
diff --git a/plugins/CorePluginsAdmin/MarketplaceApiClient.php b/plugins/CorePluginsAdmin/MarketplaceApiClient.php index 0423f72600..ee20abc918 100644 --- a/plugins/CorePluginsAdmin/MarketplaceApiClient.php +++ b/plugins/CorePluginsAdmin/MarketplaceApiClient.php @@ -9,6 +9,7 @@ namespace Piwik\Plugins\CorePluginsAdmin; use Piwik\Cache; +use Piwik\Container\StaticContainer; use Piwik\Http; use Piwik\Version; @@ -123,9 +124,16 @@ class MarketplaceApiClient return array(); } + public static function getPiwikVersion() + { + return StaticContainer::get('marketplacePiwikVersion'); + } + private function fetch($action, $params) { ksort($params); + $params['piwik'] = self::getPiwikVersion(); + $params['php'] = PHP_MAJOR_VERSION . '.' . PHP_MINOR_VERSION . '.' . PHP_RELEASE_VERSION; $query = http_build_query($params); $cacheId = $this->getCacheKey($action, $query); @@ -180,7 +188,7 @@ class MarketplaceApiClient $latestVersion = array_pop($plugin['versions']); $downloadUrl = $latestVersion['download']; - return $this->domain . $downloadUrl . '?coreVersion=' . Version::VERSION; + return $this->domain . $downloadUrl . '?coreVersion=' . self::getPiwikVersion(); } } diff --git a/plugins/CorePluginsAdmin/PluginInstaller.php b/plugins/CorePluginsAdmin/PluginInstaller.php index ed140d27bc..ab4f7b8622 100644 --- a/plugins/CorePluginsAdmin/PluginInstaller.php +++ b/plugins/CorePluginsAdmin/PluginInstaller.php @@ -12,6 +12,7 @@ use Piwik\Container\StaticContainer; use Piwik\Filechecks; use Piwik\Filesystem; use Piwik\Piwik; +use Piwik\Plugin\Manager as PluginManager; use Piwik\Plugin\Dependency as PluginDependency; use Piwik\Unzip; @@ -49,6 +50,11 @@ class PluginInstaller Filesystem::deleteAllCacheOnUpdate($this->pluginName); + $plugin = PluginManager::getInstance()->getLoadedPlugin($this->pluginName); + if (!empty($plugin)) { + $plugin->reloadPluginInformation(); + } + } catch (\Exception $e) { $this->removeFileIfExists($tmpPluginZip); @@ -160,7 +166,10 @@ class PluginInstaller $requires = (array) $metadata->require; } + $piwikVersion = MarketplaceApiClient::getPiwikVersion(); + $dependency = new PluginDependency(); + $dependency->setPiwikVersion($piwikVersion); $missingDependencies = $dependency->getMissingDependencies($requires); if (!empty($missingDependencies)) { diff --git a/plugins/CorePluginsAdmin/config/config.php b/plugins/CorePluginsAdmin/config/config.php new file mode 100644 index 0000000000..5d30748a94 --- /dev/null +++ b/plugins/CorePluginsAdmin/config/config.php @@ -0,0 +1,7 @@ +<?php + +return array( + 'marketplacePiwikVersion' => function () { + return \Piwik\Version::VERSION; + } +); diff --git a/plugins/CorePluginsAdmin/lang/es.json b/plugins/CorePluginsAdmin/lang/es.json index b0407c02ae..b4a91d7d0a 100644 --- a/plugins/CorePluginsAdmin/lang/es.json +++ b/plugins/CorePluginsAdmin/lang/es.json @@ -38,6 +38,10 @@ "LastCommitTime": "(último cambio %s)", "LastUpdated": "Última actualización", "LicenseHomepage": "Página de la licencia", + "LikeThisPlugin": "¿Satisfecho con este complemento?", + "ConsiderDonating": "Considere una donación", + "CommunityContributedPlugin": "Este es un complemento basado en la suma de voluntades de una comunidad ofrendada de manera gratuita.", + "ConsiderDonatingCreatorOf": "Por favor considere donar al creador de %s", "PluginsExtendPiwik": "Los complementos extienden y amplían las funcionalidades de Piwik.", "OncePluginIsInstalledYouMayActivateHere": "Una vez que el complemento está instalado, puede activarlo o desactivarlo desde aquí.", "Marketplace": "Mercado", |