Skip to content

Commit

Permalink
[Statistics/Behavioural] Detailed View and Double Data Entry - Site p…
Browse files Browse the repository at this point in the history
…ermission fix (aces#6861)

Code refactorization of the functions _hasAccess and _checkCriteria.
Adds per projects permissions restrictions.

A user with permission data_entry should be now able to access the 'breakdown per participant' only for the sites and projects it have access to.

    Resolves aces#6659
  • Loading branch information
racostas authored and AlexandraLivadas committed Jun 15, 2021
1 parent faf7923 commit a41e037
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions modules/statistics/php/statistics_site.class.inc
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,7 @@ class Statistics_Site extends \NDB_Menu
if (!empty($list_of_permitted_sites)) {
$paramCenters = [];
$centerIDs = [];

foreach ($list_of_permitted_sites as $key => $siteID) {
$paramCenters[] = ":paramSiteID$key";
$centerIDs["paramSiteID$key"] = $siteID;
Expand Down

0 comments on commit a41e037

Please # to comment.