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
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/ExamplePlugin/ExamplePlugin.php')
-rw-r--r--plugins/ExamplePlugin/ExamplePlugin.php18
1 files changed, 18 insertions, 0 deletions
diff --git a/plugins/ExamplePlugin/ExamplePlugin.php b/plugins/ExamplePlugin/ExamplePlugin.php
index 106a6cdbb8..a2cc37bf15 100644
--- a/plugins/ExamplePlugin/ExamplePlugin.php
+++ b/plugins/ExamplePlugin/ExamplePlugin.php
@@ -21,6 +21,24 @@ class Piwik_ExamplePlugin extends Piwik_Plugin
'version' => '0.1',
);
}
+
+ public function getListHooksRegistered()
+ {
+ return array(
+// 'Controller.renderView' => 'addUniqueVisitorsColumnToGivenReport',
+ );
+ }
+
+ function addUniqueVisitorsColumnToGivenReport($notification)
+ {
+ $view = $notification->getNotificationInfo();
+ $view = $view['view'];
+ if($view->getCurrentControllerName() == 'Referers'
+ && $view->getCurrentControllerAction() == 'getWebsites')
+ {
+ $view->addColumnToDisplay('nb_uniq_visitors');
+ }
+ }
}
// we register the widgets so they appear in the "Add a new widget" window in the dashboard