__construct() public method

Posts the {@hook ViewDataTable.configure} event which plugins can use to configure the way reports are displayed.
public __construct ( $controllerAction, $apiMethodToRequestDataTable, $overrideParams = [] )
コード例 #1
0
ファイル: Visualization.php プロジェクト: bossrabbit/piwik
 public final function __construct($controllerAction, $apiMethodToRequestDataTable, $params = array())
 {
     $templateFile = static::TEMPLATE_FILE;
     if (empty($templateFile)) {
         throw new \Exception('You have not defined a constant named TEMPLATE_FILE in your visualization class.');
     }
     $this->metricsFormatter = new HtmlFormatter();
     parent::__construct($controllerAction, $apiMethodToRequestDataTable, $params);
     $this->report = Report::factory($this->requestConfig->getApiModuleToRequest(), $this->requestConfig->getApiMethodToRequest());
 }
コード例 #2
0
ファイル: Visualization.php プロジェクト: brienomatty/elmsln
 public final function __construct($controllerAction, $apiMethodToRequestDataTable, $params = array())
 {
     $templateFile = static::TEMPLATE_FILE;
     if (empty($templateFile)) {
         throw new \Exception('You have not defined a constant named TEMPLATE_FILE in your visualization class.');
     }
     parent::__construct($controllerAction, $apiMethodToRequestDataTable, $params);
 }