diff options
author | mattab <matthieu.aubry@gmail.com> | 2013-07-31 01:31:17 +0400 |
---|---|---|
committer | mattab <matthieu.aubry@gmail.com> | 2013-07-31 01:31:17 +0400 |
commit | c35e613b7ff66c6c86a712f0fd3250692ed9d8a9 (patch) | |
tree | 4e56d45743fc85f80014518e5c5bd419cc4a8f7b /plugins/DBStats | |
parent | 765be0dc8f92a6d4bb3e678a0c23f2d4b95e0e18 (diff) | |
parent | 13f657ccfa6b58864291a173a0849d7169b031b2 (diff) |
Merge branch 'master' into php-5.3-namespaces
Conflicts:
core/Access.php
core/Config.php
core/EventDispatcher.php
core/JqplotDataGenerator/Evolution.php
core/Piwik.php
core/Plugin/MetadataLoader.php
core/ViewDataTable.php
core/ViewDataTable/Cloud.php
core/ViewDataTable/GenerateGraphHTML.php
core/ViewDataTable/HtmlTable.php
core/ViewDataTable/HtmlTable/AllColumns.php
core/ViewDataTable/HtmlTable/Goals.php
plugins/Actions/Controller.php
plugins/CoreHome/Controller.php
plugins/CoreHome/DataTableRowAction/RowEvolution.php
plugins/CoreHome/templates/_dataTable.twig
plugins/CustomVariables/Controller.php
plugins/DBStats/Controller.php
plugins/DevicesDetection/Controller.php
plugins/ExampleUI/Controller.php
plugins/Goals/Controller.php
plugins/Live/Controller.php
plugins/Provider/Controller.php
plugins/Referers/Controller.php
plugins/UserCountry/Controller.php
plugins/UserCountryMap/Controller.php
plugins/UserSettings/Archiver.php
plugins/UserSettings/Controller.php
plugins/VisitTime/Controller.php
plugins/VisitTime/VisitTime.php
plugins/VisitorInterest/Controller.php
plugins/VisitsSummary/Controller.php
tests/PHPUnit/proxy/index.php
Diffstat (limited to 'plugins/DBStats')
-rw-r--r-- | plugins/DBStats/Controller.php | 215 | ||||
-rw-r--r-- | plugins/DBStats/DBStats.php | 284 |
2 files changed, 290 insertions, 209 deletions
diff --git a/plugins/DBStats/Controller.php b/plugins/DBStats/Controller.php index 8194c29cc4..51f2a00ae6 100644 --- a/plugins/DBStats/Controller.php +++ b/plugins/DBStats/Controller.php @@ -57,21 +57,7 @@ class Piwik_DBStats_Controller extends Admin public function getDatabaseUsageSummary($fetch = false) { Piwik::checkUserIsSuperUser(); - - $view = $this->getDataTableView(__FUNCTION__, $viewType = 'graphPie', $orderDir = 'desc', - $addPercentColumn = true); - $view->disableOffsetInformationAndPaginationControls(); - - if ($view instanceof Piwik_ViewDataTable_GenerateGraphHTML) { - $view->showAllTicks(); - } - - // translate the labels themselves - $translateSummaryLabel = array($this, 'translateSummarylabel'); - $view->queueFilter('ColumnCallbackReplace', array(array('label'), $translateSummaryLabel), - $runBeforeGenericFilters = true); - - return $this->renderView($view, $fetch); + return ViewDataTable::renderReport($this->pluginName, __FUNCTION__, $fetch); } /** @@ -85,10 +71,7 @@ class Piwik_DBStats_Controller extends Admin public function getTrackerDataSummary($fetch = false) { Piwik::checkUserIsSuperUser(); - - $view = $this->getDataTableView(__FUNCTION__); - $view->disableOffsetInformationAndPaginationControls(); - return $this->renderView($view, $fetch); + return ViewDataTable::renderReport($this->pluginName, __FUNCTION__, $fetch); } /** @@ -102,11 +85,7 @@ class Piwik_DBStats_Controller extends Admin public function getMetricDataSummary($fetch = false) { Piwik::checkUserIsSuperUser(); - $view = $this->getDataTableView(__FUNCTION__, $viewType = 'table', $orderDir = 'desc'); - $view->addRelatedReports(Piwik_Translate('DBStats_MetricTables'), array( - 'DBStats.getMetricDataSummaryByYear' => Piwik_Translate('DBStats_MetricDataByYear') - )); - return $this->renderView($view, $fetch); + return ViewDataTable::renderReport($this->pluginName, __FUNCTION__, $fetch); } /** @@ -120,12 +99,7 @@ class Piwik_DBStats_Controller extends Admin public function getMetricDataSummaryByYear($fetch = false) { Piwik::checkUserIsSuperUser(); - $view = $this->getDataTableView(__FUNCTION__, $viewType = 'table', $orderDir = 'desc', - $addPercentColumn = false, $labelKey = 'CoreHome_PeriodYear'); - $view->addRelatedReports(Piwik_Translate('DBStats_MetricDataByYear'), array( - 'DBStats.getMetricDataSummary' => Piwik_Translate('DBStats_MetricTables') - )); - return $this->renderView($view, $fetch); + return ViewDataTable::renderReport($this->pluginName, __FUNCTION__, $fetch); } /** @@ -139,11 +113,7 @@ class Piwik_DBStats_Controller extends Admin public function getReportDataSummary($fetch = false) { Piwik::checkUserIsSuperUser(); - $view = $this->getDataTableView(__FUNCTION__, $viewType = 'table', $orderDir = 'desc'); - $view->addRelatedReports(Piwik_Translate('DBStats_ReportTables'), array( - 'DBStats.getReportDataSummaryByYear' => Piwik_Translate('DBStats_ReportDataByYear') - )); - return $this->renderView($view, $fetch); + return ViewDataTable::renderReport($this->pluginName, __FUNCTION__, $fetch); } /** @@ -157,12 +127,7 @@ class Piwik_DBStats_Controller extends Admin public function getReportDataSummaryByYear($fetch = false) { Piwik::checkUserIsSuperUser(); - $view = $this->getDataTableView(__FUNCTION__, $viewType = 'table', $orderDir = 'desc', - $addPercentColumn = false, $labelKey = 'CoreHome_PeriodYear'); - $view->addRelatedReports(Piwik_Translate('DBStats_ReportDataByYear'), array( - 'DBStats.getReportDataSummary' => Piwik_Translate('DBStats_ReportTables') - )); - return $this->renderView($view, $fetch); + return ViewDataTable::renderReport($this->pluginName, __FUNCTION__, $fetch); } /** @@ -178,18 +143,7 @@ class Piwik_DBStats_Controller extends Admin public function getIndividualReportsSummary($fetch = false) { Piwik::checkUserIsSuperUser(); - $view = $this->getDataTableView(__FUNCTION__, $viewType = 'table', $orderDir = 'asc', - $addPercentColumn = false, $labelKey = 'General_Report', - $sizeColumns = array('estimated_size')); - - // this report table has some extra columns that shouldn't be shown - if ($view instanceof Piwik_ViewDataTable_HtmlTable) { - $view->setColumnsToDisplay(array('label', 'row_count', 'estimated_size')); - } - - $this->setIndividualSummaryFooterMessage($view); - - return $this->renderView($view, $fetch); + return ViewDataTable::renderReport($this->pluginName, __FUNCTION__, $fetch); } /** @@ -205,13 +159,7 @@ class Piwik_DBStats_Controller extends Admin public function getIndividualMetricsSummary($fetch = false) { Piwik::checkUserIsSuperUser(); - $view = $this->getDataTableView(__FUNCTION__, $viewType = 'table', $orderDir = 'asc', - $addPercentColumn = false, $labelKey = 'General_Metric', - $sizeColumns = array('estimated_size')); - - $this->setIndividualSummaryFooterMessage($view); - - return $this->renderView($view, $fetch); + return ViewDataTable::renderReport($this->pluginName, __FUNCTION__, $fetch); } /** @@ -228,151 +176,6 @@ class Piwik_DBStats_Controller extends Admin public function getAdminDataSummary($fetch = false) { Piwik::checkUserIsSuperUser(); - $view = $this->getDataTableView(__FUNCTION__, $viewType = 'table'); - $view->disableOffsetInformationAndPaginationControls(); - return $this->renderView($view, $fetch); - } - - /** - * Utility function that creates and prepares a ViewDataTable for this plugin. - */ - private function getDataTableView($function, $viewType = 'table', $orderDir = 'asc', $addPercentColumn = false, - $labelKey = 'DBStats_Table', $sizeColumns = array('data_size', 'index_size'), - $limit = 25) - { - $columnTranslations = array( - 'label' => Piwik_Translate($labelKey), - 'year' => Piwik_Translate('CoreHome_PeriodYear'), - 'data_size' => Piwik_Translate('DBStats_DataSize'), - 'index_size' => Piwik_Translate('DBStats_IndexSize'), - 'total_size' => Piwik_Translate('DBStats_TotalSize'), - 'row_count' => Piwik_Translate('DBStats_RowCount'), - 'percent_total' => '% ' . Piwik_Translate('DBStats_DBSize'), - 'estimated_size' => Piwik_Translate('DBStats_EstimatedSize') - ); - - $view = ViewDataTable::factory($viewType); - $view->init($this->pluginName, $function, "DBStats.$function"); - $view->setSortedColumn('label', $orderDir); - $view->setLimit($limit); - $view->setHighlightSummaryRow(true); - $view->disableSearchBox(); - $view->disableExcludeLowPopulation(); - $view->disableTagCloud(); - $view->disableShowAllColumns(); - $view->alwaysShowSummaryRow(); - - // translate columns - foreach ($columnTranslations as $columnName => $translation) { - $view->setColumnTranslation($columnName, $translation); - } - - // add total_size column (if necessary columns are present) - if (in_array('data_size', $sizeColumns) && in_array('index_size', $sizeColumns)) { - $getTotalTableSize = array($this, 'getTotalTableSize'); - $view->queueFilter('ColumnCallbackAddColumn', - array(array('data_size', 'index_size'), 'total_size', $getTotalTableSize), - $runBeforeGenericFilters = true); - - $sizeColumns[] = 'total_size'; - } - - $runPrettySizeFilterBeforeGeneric = false; - $fixedMemoryUnit = false; - if ($view instanceof Piwik_ViewDataTable_HtmlTable) { // if displaying a table - $view->disableRowEvolution(); - - // add summary row only if displaying a table - $view->queueFilter('AddSummaryRow', array(0, Piwik_Translate('General_Total'), 'label', false), - $runBeforeGenericFilters = true); - - // add other filters - if ($addPercentColumn && in_array('total_size', $sizeColumns)) { - $view->queueFilter('ColumnCallbackAddColumnPercentage', - array('percent_total', 'total_size', 'total_size', $quotientPrecision = 0, $shouldSkipRows = false, - $getDivisorFromSummaryRow = true), - $runBeforeGenericFilters = true); - $view->setSortedColumn('percent_total', $orderDir); - } - } else if ($view instanceof Piwik_ViewDataTable_GenerateGraphHtml) { // if displaying a graph - if (in_array('total_size', $sizeColumns)) { - $view->setColumnsToDisplay(array('label', 'total_size')); - - // when displaying a graph, we force sizes to be shown as the same unit so axis labels - // will be readable. NOTE: The unit should depend on the smallest value of the data table, - // however there's no way to know this information, short of creating a custom filter. For - // now, just assume KB. - $fixedMemoryUnit = 'K'; - $view->setAxisYUnit(' K'); - - $view->setSortedColumn('total_size', 'desc'); - - $runPrettySizeFilterBeforeGeneric = true; - } else { - $view->setColumnsToDisplay(array('label', 'row_count')); - $view->setAxisYUnit(' ' . Piwik_Translate('General_Rows')); - - $view->setSortedColumn('row_count', 'desc'); - } - } - - $getPrettySize = '\Piwik\Piwik::getPrettySizeFromBytes'; - $params = $fixedMemoryUnit === false ? array() : array($fixedMemoryUnit); - $view->queueFilter( - 'ColumnCallbackReplace', array($sizeColumns, $getPrettySize, $params), $runPrettySizeFilterBeforeGeneric); - - // jqPlot will display as, well, ' ', so don't replace the spaces when rendering as a graph - if (!($view instanceof Piwik_ViewDataTable_GenerateGraphHtml)) { - $replaceSpaces = array($this, 'replaceColumnSpaces'); - $view->queueFilter('ColumnCallbackReplace', array($sizeColumns, $replaceSpaces)); - } - - $view->queueFilter('ColumnCallbackReplace', array(array('row_count'), '\Piwik\Piwik::getPrettyNumber')); - - return $view; - } - - /** - * Replaces spaces w/ for correct HTML output. - */ - public function replaceColumnSpaces($value) - { - return str_replace(' ', ' ', $value); - } - - /** - * Row callback function that calculates a tables total size. - */ - public function getTotalTableSize($dataSize, $indexSize) - { - return $dataSize + $indexSize; - } - - /** - * Column callback used to translate the column values in the database usage summary table. - */ - public function translateSummarylabel($value) - { - static $valueToTranslationStr = array( - 'tracker_data' => 'DBStats_TrackerTables', - 'report_data' => 'DBStats_ReportTables', - 'metric_data' => 'DBStats_MetricTables', - 'other_data' => 'DBStats_OtherTables' - ); - - return isset($valueToTranslationStr[$value]) - ? Piwik_Translate($valueToTranslationStr[$value]) - : $value; - } - - /** - * Sets the footer message for the Individual...Summary reports. - */ - private function setIndividualSummaryFooterMessage($view) - { - $lastGenerated = Piwik_DBStats::getDateOfLastCachingRun(); - if ($lastGenerated !== false) { - $view->setFooterMessage(Piwik_Translate('Mobile_LastUpdated', $lastGenerated)); - } + return ViewDataTable::renderReport($this->pluginName, __FUNCTION__, $fetch); } } diff --git a/plugins/DBStats/DBStats.php b/plugins/DBStats/DBStats.php index 955c0b6812..467933d1e3 100644 --- a/plugins/DBStats/DBStats.php +++ b/plugins/DBStats/DBStats.php @@ -27,9 +27,10 @@ class Piwik_DBStats extends Plugin public function getListHooksRegistered() { return array( - 'AssetManager.getCssFiles' => 'getCssFiles', - 'AdminMenu.add' => 'addMenu', - 'TaskScheduler.getScheduledTasks' => 'getScheduledTasks', + 'AssetManager.getCssFiles' => 'getCssFiles', + 'AdminMenu.add' => 'addMenu', + 'TaskScheduler.getScheduledTasks' => 'getScheduledTasks', + 'ViewDataTable.getReportDisplayProperties' => 'getReportDisplayProperties', ); } @@ -80,4 +81,281 @@ class Piwik_DBStats extends Plugin { return Piwik_GetOption(self::TIME_OF_LAST_TASK_RUN_OPTION); } + + public function getReportDisplayProperties(&$properties) + { + $properties['DBStats.getDatabaseUsageSummary'] = $this->getDisplayPropertiesForGetDatabaseUsageSummary(); + $properties['DBStats.getTrackerDataSummary'] = $this->getDisplayPropertiesForGetTrackerDataSummary(); + $properties['DBStats.getMetricDataSummary'] = $this->getDisplayPropertiesForGetMetricDataSummary(); + $properties['DBStats.getMetricDataSummaryByYear'] = $this->getDisplayPropertiesForGetMetricDataSummaryByYear(); + $properties['DBStats.getReportDataSummary'] = $this->getDisplayPropertiesForGetReportDataSummary(); + $properties['DBStats.getReportDataSummaryByYear'] = $this->getDisplayPropertiesForGetReportDataSummaryByYear(); + $properties['DBStats.getIndividualReportsSummary'] = $this->getDisplayPropertiesForGetIndividualReportsSummary(); + $properties['DBStats.getIndividualMetricsSummary'] = $this->getDisplayPropertiesForGetIndividualMetricsSummary(); + $properties['DBStats.getAdminDataSummary'] = $this->getDisplayPropertiesForGetAdminDataSummary(); + } + + private function getDisplayPropertiesForGetDatabaseUsageSummary() + { + $result = array('default_view_type' => 'graphPie'); + $this->addBaseDisplayProperties($result); + $this->addPresentationFilters($result, $addTotalSizeColumn = true, $addPercentColumn = true); + + $result['show_offset_information'] = false; + $result['show_pagination_control'] = false; + $result['show_all_ticks'] = true; + + // translate the labels themselves + $valueToTranslationStr = array( + 'tracker_data' => 'DBStats_TrackerTables', + 'report_data' => 'DBStats_ReportTables', + 'metric_data' => 'DBStats_MetricTables', + 'other_data' => 'DBStats_OtherTables' + ); + + $translateSummaryLabel = function ($value) use ($valueToTranslationStr) { + return isset($valueToTranslationStr[$value]) + ? Piwik_Translate($valueToTranslationStr[$value]) + : $value; + }; + + $result['filters'][] = array('ColumnCallbackReplace', array('label', $translateSummaryLabel), $isPriority = true); + + return $result; + } + + private function getDisplayPropertiesForGetTrackerDataSummary() + { + $result = array(); + $this->addBaseDisplayProperties($result); + $this->addPresentationFilters($result); + + $result['filter_sort_order'] = 'asc'; + $result['show_offset_information'] = false; + $result['show_pagination_control'] = false; + + return $result; + } + + private function getDisplayPropertiesForGetMetricDataSummary() + { + $result = array(); + $this->addBaseDisplayProperties($result); + $this->addPresentationFilters($result); + + $result['title'] = Piwik_Translate('DBStats_MetricTables'); + $result['relatedReports'] = array( + 'DBStats.getMetricDataSummaryByYear' => Piwik_Translate('DBStats_MetricDataByYear') + ); + + return $result; + } + + private function getDisplayPropertiesForGetMetricDataSummaryByYear() + { + $result = array(); + $this->addBaseDisplayProperties($result); + $this->addPresentationFilters($result); + + $result['translations']['label'] = Piwik_Translate('CoreHome_PeriodYear'); + $result['title'] = Piwik_Translate('DBStats_MetricDataByYear'); + $result['relatedReports'] = array( + 'DBStats.getMetricDataSummary' => Piwik_Translate('DBStats_MetricTables') + ); + + return $result; + } + + private function getDisplayPropertiesForGetReportDataSummary() + { + $result = array(); + $this->addBaseDisplayProperties($result); + $this->addPresentationFilters($result); + + $result['title'] = Piwik_Translate('DBStats_ReportTables'); + $result['relatedReports'] = array( + 'DBStats.getReportDataSummaryByYear' => Piwik_Translate('DBStats_ReportDataByYear') + ); + + return $result; + } + + private function getDisplayPropertiesForGetReportDataSummaryByYear() + { + $result = array(); + $this->addBaseDisplayProperties($result); + $this->addPresentationFilters($result); + + $result['translations']['label'] = Piwik_Translate('CoreHome_PeriodYear'); + $result['title'] = Piwik_Translate('DBStats_ReportDataByYear'); + $result['relatedReports'] = array( + 'DBStats.getReportDataSummary' => Piwik_Translate('DBStats_ReportTables') + ); + + return $result; + } + + private function getDisplayPropertiesForGetIndividualReportsSummary() + { + $result = array(); + $this->addBaseDisplayProperties($result); + $viewDataTable = $this->addPresentationFilters($result, $addTotalSizeColumn = false, $addPercentColumn = false, + $sizeColumns = array('estimated_size')); + + $result['filter_sort_order'] = 'asc'; + $result['translations']['label'] = Piwik_Translate('General_Report'); + + // this report table has some extra columns that shouldn't be shown + if ($viewDataTable == 'table') { + $result['columns_to_display'] = array('label', 'row_count', 'estimated_size'); + } + + $this->setIndividualSummaryFooterMessage($result); + + return $result; + } + + private function getDisplayPropertiesForGetIndividualMetricsSummary() + { + $result = array(); + $this->addBaseDisplayProperties($result); + $this->addPresentationFilters($result, $addTotalSizeColumn = false, $addPercentColumn = false, + $sizeColumns = array('estimated_size')); + + $result['filter_sort_order'] = 'asc'; + $result['translations']['label'] = Piwik_Translate('General_Metric'); + + $this->setIndividualSummaryFooterMessage($result); + + return $result; + } + + private function getDisplayPropertiesForGetAdminDataSummary() + { + $result = array(); + $this->addBaseDisplayProperties($result); + $this->addPresentationFilters($result); + + $result['filter_sort_order'] = 'asc'; + $result['show_offset_information'] = false; + $result['show_pagination_control'] = false; + + return $result; + } + + private function addBaseDisplayProperties(&$properties) + { + $properties['filter_sort_column'] = 'label'; + $properties['filter_sort_order'] = 'desc'; + $properties['filter_limit'] = 25; + $properties['highlight_summary_row'] = true; + $properties['show_search'] = false; + $properties['show_exclude_low_population'] = false; + $properties['show_tag_cloud'] = false; + $properties['show_table_all_columns'] = false; + $properties['keep_summary_row'] = true; + $properties['disable_row_evolution'] = true; + $properties['translations'] = array( + 'label' => Piwik_Translate('DBStats_Table'), + 'year' => Piwik_Translate('CoreHome_PeriodYear'), + 'data_size' => Piwik_Translate('DBStats_DataSize'), + 'index_size' => Piwik_Translate('DBStats_IndexSize'), + 'total_size' => Piwik_Translate('DBStats_TotalSize'), + 'row_count' => Piwik_Translate('DBStats_RowCount'), + 'percent_total' => '% ' . Piwik_Translate('DBStats_DBSize'), + 'estimated_size' => Piwik_Translate('DBStats_EstimatedSize') + ); + } + + private function addPresentationFilters(&$properties, $addTotalSizeColumn = true, $addPercentColumn = false, + $sizeColumns = array('data_size', 'index_size')) + { + // add total_size column + if ($addTotalSizeColumn) { + $getTotalTableSize = function ($dataSize, $indexSize) { + return $dataSize + $indexSize; + }; + + $properties['filters'][] = array('ColumnCallbackAddColumn', + array(array('data_size', 'index_size'), 'total_size', $getTotalTableSize), $isPriority = true); + + $sizeColumns[] = 'total_size'; + } + + $runPrettySizeFilterBeforeGeneric = false; + + $viewDataTable = empty($properties['default_view_type']) ? 'table' : $properties['default_view_type']; + $viewDataTable = Piwik_Common::getRequestVar('viewDataTable', $viewDataTable); + + if ($viewDataTable == 'table') { + // add summary row only if displaying a table + $properties['filters'][] = array( + 'AddSummaryRow', array(0, Piwik_Translate('General_Total'), 'label', false), $isPriority = true); + + // add percentage column if desired + if ($addPercentColumn + && $addTotalSizeColumn + ) { + $properties['filters'][] = array('ColumnCallbackAddColumnPercentage', + array('percent_total', 'total_size', 'total_size', $quotientPrecision = 0, + $shouldSkipRows = false, $getDivisorFromSummaryRow = true), + $isPriority = true + ); + + $properties['filter_sort_column'] = 'percent_total'; + } + } else if (strpos($viewDataTable, 'graph') === 0) { + if ($addTotalSizeColumn) { + $properties['columns_to_display'] = array('label', 'total_size'); + + // when displaying a graph, we force sizes to be shown as the same unit so axis labels + // will be readable. NOTE: The unit should depend on the smallest value of the data table, + // however there's no way to know this information, short of creating a custom filter. For + // now, just assume KB. + $fixedMemoryUnit = 'K'; + $properties['y_axis_unit'] = ' K'; + + $properties['filter_sort_column'] = 'total_size'; + $properties['filter_sort_order'] = 'desc'; + + $runPrettySizeFilterBeforeGeneric = true; + } else { + $properties['columns_to_display'] = array('label', 'row_count'); + $properties['y_axis_unit'] = ' ' . Piwik_Translate('General_Rows'); + + $properties['filter_sort_column'] = 'row_count'; + $properties['filter_sort_order'] = 'desc'; + } + } + + $getPrettySize = array('Piwik', 'getPrettySizeFromBytes'); + $params = !isset($fixedMemoryUnit) ? array() : array($fixedMemoryUnit); + $properties['filters'][] = array( + 'ColumnCallbackReplace', array($sizeColumns, $getPrettySize, $params), $runPrettySizeFilterBeforeGeneric); + + // jqPlot will display as, well, ' ', so don't replace the spaces when rendering as a graph + if ($viewDataTable == 'table') { + $replaceSpaces = function ($value) { + return str_replace(' ', ' ', $value); + }; + + $properties['filters'][] = array('ColumnCallbackReplace', array($sizeColumns, $replaceSpaces)); + } + + $getPrettyNumber = array('Piwik', 'getPrettyNumber'); + $properties['filters'][] = array('ColumnCallbackReplace', array('row_count', $getPrettyNumber)); + + return $viewDataTable; + } + + /** + * Sets the footer message for the Individual...Summary reports. + */ + private function setIndividualSummaryFooterMessage($result) + { + $lastGenerated = self::getDateOfLastCachingRun(); + if ($lastGenerated !== false) { + $result['show_footer_message'] = Piwik_Translate('Mobile_LastUpdated', $lastGenerated); + } + } } |