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:
authorBenaka Moorthi <benaka.moorthi@gmail.com>2013-07-11 02:45:12 +0400
committerBenaka Moorthi <benaka.moorthi@gmail.com>2013-07-11 02:45:12 +0400
commit4ab3f934dd59806fbd44914aada8adc2d11190d5 (patch)
tree096a787d99ade4aa694398c857746ed806e2dd7c /core
parente05325bcb4314d768c02adb90514537f39e045c2 (diff)
Modified _dataTable.twig to use a Piwik_DataTable instance instead of a DataTable converted to an array, allowed HtmlTables to render expanded DataTables, and removed @CoreHome/_dataTableActions_recursive.twig.
Diffstat (limited to 'core')
-rw-r--r--core/ViewDataTable.php2
-rw-r--r--core/ViewDataTable/HtmlTable.php12
2 files changed, 11 insertions, 3 deletions
diff --git a/core/ViewDataTable.php b/core/ViewDataTable.php
index 3a5ce83b74..feee1c7bf3 100644
--- a/core/ViewDataTable.php
+++ b/core/ViewDataTable.php
@@ -1273,7 +1273,7 @@ abstract class Piwik_ViewDataTable
* and should therefore be ran before Sort, Limit, etc.
* @return void
*/
- public function queueFilter($filterName, $parameters, $runBeforeGenericFilters = false)
+ public function queueFilter($filterName, $parameters = array(), $runBeforeGenericFilters = false)
{
if ($runBeforeGenericFilters) {
$this->queuedFiltersPriority[] = array($filterName, $parameters);
diff --git a/core/ViewDataTable/HtmlTable.php b/core/ViewDataTable/HtmlTable.php
index 402355dc53..9b951f392f 100644
--- a/core/ViewDataTable/HtmlTable.php
+++ b/core/ViewDataTable/HtmlTable.php
@@ -104,6 +104,14 @@ class Piwik_ViewDataTable_HtmlTable extends Piwik_ViewDataTable
{
$this->dataTableJsType = $type;
}
+
+ public function showExpanded($subtableTemplate = false)
+ {
+ $this->viewProperties['show_expanded'] = true;
+ if ($subtableTemplate !== false) {
+ $this->viewProperties['subtable_template'] = $subtableTemplate;
+ }
+ }
/**
* @return Piwik_View with all data set
@@ -125,7 +133,7 @@ class Piwik_ViewDataTable_HtmlTable extends Piwik_ViewDataTable
}
if (!$this->isDataAvailable) {
- $view->arrayDataTable = array();
+ $view->dataTable = null;
} else {
$columns = $this->getColumnsToDisplay();
$columnTranslations = $columnDocumentation = array();
@@ -139,7 +147,7 @@ class Piwik_ViewDataTable_HtmlTable extends Piwik_ViewDataTable
$nbColumns = count($this->columnsToDisplay);
}
- $view->arrayDataTable = $this->getPHPArrayFromDataTable();
+ $view->dataTable = $this->dataTable;
$view->dataTableColumns = $columns;
$view->reportDocumentation = $this->getReportDocumentation();
$view->columnTranslations = $columnTranslations;