diff options
Diffstat (limited to 'core/API/DataTableGenericFilter.php')
-rw-r--r-- | core/API/DataTableGenericFilter.php | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/core/API/DataTableGenericFilter.php b/core/API/DataTableGenericFilter.php index 22f691c505..fec5bb7e94 100644 --- a/core/API/DataTableGenericFilter.php +++ b/core/API/DataTableGenericFilter.php @@ -9,6 +9,8 @@ * @package Piwik */ use Piwik\Common; +use Piwik\DataTable; +use Piwik\DataTable\Filter\AddColumnsProcessedMetricsGoal; /** * @package Piwik @@ -31,7 +33,7 @@ class Piwik_API_DataTableGenericFilter /** * Filters the given data table * - * @param Piwik_DataTable $table + * @param DataTable $table */ public function filter($table) { @@ -39,7 +41,7 @@ class Piwik_API_DataTableGenericFilter } /** - * Returns an array containing the information of the generic Piwik_DataTable_Filter + * Returns an array containing the information of the generic Filter * to be applied automatically to the data resulting from the API calls. * * Order to apply the filters: @@ -71,7 +73,7 @@ class Piwik_API_DataTableGenericFilter ), 'AddColumnsProcessedMetricsGoal' => array( 'filter_update_columns_when_show_all_goals' => array('integer'), - 'idGoal' => array('string', Piwik_DataTable_Filter_AddColumnsProcessedMetricsGoal::GOALS_OVERVIEW), + 'idGoal' => array('string', AddColumnsProcessedMetricsGoal::GOALS_OVERVIEW), ), 'Sort' => array( 'filter_sort_column' => array('string'), @@ -95,12 +97,12 @@ class Piwik_API_DataTableGenericFilter * Apply generic filters to the DataTable object resulting from the API Call. * Disable this feature by setting the parameter disable_generic_filters to 1 in the API call request. * - * @param Piwik_DataTable $datatable + * @param DataTable $datatable * @return bool */ protected function applyGenericFilters($datatable) { - if ($datatable instanceof Piwik_DataTable_Array) { + if ($datatable instanceof DataTable\Map) { $tables = $datatable->getArray(); $filterWasApplied = false; foreach ($tables as $table) { |