diff options
author | Benaka Moorthi <benaka.moorthi@gmail.com> | 2013-07-12 05:32:39 +0400 |
---|---|---|
committer | Benaka Moorthi <benaka.moorthi@gmail.com> | 2013-07-12 05:32:39 +0400 |
commit | 145661260ad127a5435d8789df7841f858264541 (patch) | |
tree | 36036ecbfa5b23bc9b36a35f6c26fd6be08bb4a9 /core | |
parent | 22d767681a824087e3a228c3e3ba1f842c6272b8 (diff) |
Allow extra query params to be added to ViewDataTable's API request string and remove modification hack in Goals::getItemsView.
Diffstat (limited to 'core')
-rw-r--r-- | core/ViewDataTable.php | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/core/ViewDataTable.php b/core/ViewDataTable.php index 021cac985e..a60bdb2208 100644 --- a/core/ViewDataTable.php +++ b/core/ViewDataTable.php @@ -580,6 +580,11 @@ abstract class Piwik_ViewDataTable if(!empty($segment)) { $requestString .= '&segment=' . $segment; } + + if (!empty($this->viewProperties['request_string_suffix'])) { + $requestString .= $this->viewProperties['request_string_suffix']; + } + return $requestString; } @@ -770,6 +775,16 @@ abstract class Piwik_ViewDataTable } return $this->variablesDefault[$nameVar]; } + + /** + * Makes sure the supplied suffix is appended to the URL used to query API data. + * + * @param string $suffix + */ + public function setRequestStringSuffix($suffix) + { + $this->viewProperties['request_string_suffix'] = $suffix; + } /** * The generic filters (limit, offset, sort by visit desc) will not be applied to this datatable. |