You are here

public function ReportManager::checkAccess in Forena Reports 8

Check access on areport.

Parameters

$security:

Return value

bool

1 call to ReportManager::checkAccess()
ReportManager::report in src/ReportManager.php
Generate a forena report

File

src/ReportManager.php, line 55
Implements \Drupal\forena\File\ReportFileSystem

Class

ReportManager
Access to Report rendering engine.

Namespace

Drupal\forena

Code

public function checkAccess($security) {
  $access = empty($security);
  foreach ($security as $provider => $rights) {
    $m = DataManager::instance()
      ->repository($provider);
    foreach ($rights as $right) {
      if ($m && $m
        ->access($right)) {
        $access = TRUE;
      }
    }
  }
  return $access;
}