You are here

class FrxMergeDocument in Forena Reports 8

Hierarchy

Expanded class hierarchy of FrxMergeDocument

1 string reference to 'FrxMergeDocument'
ReportEditor::scrapeBlockConfig in src/Editor/ReportEditor.php
Scrape Data block configuration This tries to introspect the frx:block configuration based on the child nodes in the report by calling the getConfig method on the block.

File

src/FrxPlugin/Template/FrxMergeDocument.php, line 3

Namespace

Drupal\forena\Template
View source
class FrxMergeDocument extends TemplateBase {
  public $templateName = 'Generic Merge Document';

  /**
   * Returns the section
   * Enter description here ...
   */
  public function configForm($config) {
    $form_ctl = array();
    $form_ctl['content'] = array(
      '#type' => 'text_format',
      '#title' => t('Document'),
      '#rows' => 5,
      '#format' => $this->input_format,
      '#default_value' => @$config['content']['value'],
    );
    return $form_ctl;
  }
  public function configValidate(&$config) {
    $this
      ->validateTextFormats($config, array(
      'content',
    ));
  }
  public function scrapeConfig(\SimpleXMLElement $xml) {
    $config = array();
    $config['class'] = get_class($this);
    $this
      ->extractTemplateHTML($this->reportDocDomNode, $config);
    return $config;
  }
  public function generate() {
    $config = $this->configuration;
    $config['class'] = get_class($this);
    $config['foreach'] = '*';
    $div = $this
      ->blockDiv($config);
    $this
      ->removeChildren($div);
    $this
      ->addFragment($div, $config['content']['value']);
  }

}

Members

Namesort descending Modifiers Type Description Overrides
FrxAPI::app public function Returns containing application service
FrxAPI::currentDataContext public function Get the current data context.
FrxAPI::currentDataContextArray public function
FrxAPI::dataManager public function Returns the data manager service
FrxAPI::dataService public function Return Data Service
FrxAPI::documentManager public function Returns the fornea document manager
FrxAPI::error public function Report an error
FrxAPI::getDataContext public function Get the context of a specific id.
FrxAPI::getDocument public function Get the current document
FrxAPI::getReportFileContents public function Load the contents of a file in the report file system.
FrxAPI::popData public function Pop data off of the stack.
FrxAPI::pushData public function Push data onto the Stack
FrxAPI::report public function Run a report with a particular format. 1
FrxAPI::reportFileSystem public function Get the current report file system.
FrxAPI::setDataContext public function Set Data context by id.
FrxAPI::setDocument public function Change to a specific document type.
FrxAPI::skins public function Get list of skins.
FrxMergeDocument::$templateName public property
FrxMergeDocument::configForm public function Returns the section Enter description here ...
FrxMergeDocument::configValidate public function
FrxMergeDocument::generate public function Overrides TemplateInterface::generate
FrxMergeDocument::scrapeConfig public function Overrides TemplateInterface::scrapeConfig
TemplateBase::$columns public property
TemplateBase::$configuration public property @var array Confiuration of template
TemplateBase::$id public property
TemplateBase::$name public property
TemplateBase::$numeric_columns public property
TemplateBase::$xmlns public property
TemplateBase::columns public function Extract a list of columns from the data context.
TemplateBase::configure public function Overrides TemplateInterface::configure
TemplateBase::innerXML public function Return the inside xml of the current node Overrides FrxAPI::innerXML