diff options
author | root | 2019-02-19 18:53:50 +0100 |
---|---|---|
committer | root | 2019-02-19 18:53:50 +0100 |
commit | 0ad4c0f8196b61699754762aacbaab0223478ab9 (patch) | |
tree | de434c4aea8d07ecd01cd3badd48d057d62c2d1b /modules-available/statistics_reporting/page.inc.php | |
parent | [usb-lock-off] Edit rule cleanup and fix of the dropdown boxes. (diff) | |
parent | [statistics] Fix RAM change warning to handle increase too (diff) | |
download | slx-admin-0ad4c0f8196b61699754762aacbaab0223478ab9.tar.gz slx-admin-0ad4c0f8196b61699754762aacbaab0223478ab9.tar.xz slx-admin-0ad4c0f8196b61699754762aacbaab0223478ab9.zip |
Merge branch 'master' into usb-lock-offusb-lock-off
Diffstat (limited to 'modules-available/statistics_reporting/page.inc.php')
-rw-r--r-- | modules-available/statistics_reporting/page.inc.php | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/modules-available/statistics_reporting/page.inc.php b/modules-available/statistics_reporting/page.inc.php index b30b5cab..cc03e4d8 100644 --- a/modules-available/statistics_reporting/page.inc.php +++ b/modules-available/statistics_reporting/page.inc.php @@ -84,6 +84,7 @@ class Page_Statistics_Reporting extends Page die(json_encode($report)); } } + User::assertPermission('*'); } /** @@ -283,6 +284,7 @@ class Page_Statistics_Reporting extends Page private function fetchData($flags) { + // TODO: Make all modes location-aware, filter while querying, not after switch ($this->type) { case 'total': return GetData::total($flags); @@ -309,7 +311,7 @@ class Page_Statistics_Reporting extends Page case 'client': $data = GetData::perClient($flags, Request::any('new', false, 'string')); // only show clients from locations which you have permission for - $filterLocs = User::getAllowedLocations("table.view.location"); + $filterLocs = User::getAllowedLocations("table.view.client"); foreach ($data as $key => $row) { if (!in_array($row['locationid'], $filterLocs)) { unset($data[$key]); |