diff options
author | Thomas Steur <tsteur@users.noreply.github.com> | 2017-04-14 02:26:19 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-04-14 02:26:19 +0300 |
commit | 4de1d0812604c37b4bb484d535f03757d182ebea (patch) | |
tree | e3b6f9317263e02c8f29a06d689fd14d1fcee19a /core/Plugin/Dimension | |
parent | 024799a7bd7e6cc49bfcaebc1bf8de82cb46450c (diff) |
New JS Tracker methods to retrieve current URL and piwik URL (#11616)
* api tweaks
* added tests
* added docs and minified piwik
* fix tests
Diffstat (limited to 'core/Plugin/Dimension')
-rw-r--r-- | core/Plugin/Dimension/DimensionMetadataProvider.php | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/core/Plugin/Dimension/DimensionMetadataProvider.php b/core/Plugin/Dimension/DimensionMetadataProvider.php index 089c60c0a6..119063ba2d 100644 --- a/core/Plugin/Dimension/DimensionMetadataProvider.php +++ b/core/Plugin/Dimension/DimensionMetadataProvider.php @@ -7,6 +7,7 @@ */ namespace Piwik\Plugin\Dimension; +use Piwik\Piwik; /** * Provides metadata about dimensions for the LogDataPurger class. @@ -73,6 +74,22 @@ class DimensionMetadataProvider } } + /** + * Triggered when detecting which log_action entries to keep. Any log tables that use the log_action + * table to reference text via an ID should add their table info so no actions that are still in use + * will be accidentally deleted. + * + * **Example** + * + * Piwik::addAction('Db.getActionReferenceColumnsByTable', function(&$result) { + * $tableNameUnprefixed = 'log_example'; + * $columnNameThatReferencesIdActionInLogActionTable = 'idaction_example'; + * $result[$tableNameUnprefixed] = array($columnNameThatReferencesIdActionInLogActionTable); + * }); + * @param array $result + */ + Piwik::postEvent('Db.getActionReferenceColumnsByTable', array(&$result)); + return $result; } |