You are here

public function Report::collapseParameters in Forena Reports 8

Same name and namespace in other branches
  1. 7.5 src/Report.php \Drupal\forena\Report::collapseParameters()

Collapse the parameters if the data is loaded.

File

src/Report.php, line 339
Basic report provider. Controls the rendering of the report.

Class

Report

Namespace

Drupal\forena

Code

public function collapseParameters() {
  if (is_array($this
    ->getDocument()->parameters_form) && $this
    ->getDocument()->parameters_form) {
    $form = $this
      ->getDocument()->parameters_form;
    if (isset($form['params']) && @$form['params']['#collapsible']) {
      $this
        ->getDocument()->parameters_form['params']['#collapsed'] = $this->blocks_loaded;
    }
  }
}