You are here

public function FrxDataSource::getSQLInclude in Forena Reports 7.4

Same name and namespace in other branches
  1. 7.3 FrxDataSource.inc \FrxDataSource::getSQLInclude()
1 call to FrxDataSource::getSQLInclude()
FrxDataSource::parseSQLFile in ./FrxDataSource.inc

File

./FrxDataSource.inc, line 245
Class that defines default methods for access control in an FrxDataSource

Class

FrxDataSource
@file Class that defines default methods for access control in an FrxDataSource

Code

public function getSQLInclude($block_name) {

  //@TODO: allow relative block includes
  $block = $this
    ->loadBlock($block_name, TRUE);
  if ($block && $block['type'] == 'sql') {
    return $block;
  }
  else {
    drupal_set_message(t('Include %b.sql not found', array(
      '%b' => $block_name,
    )), 'error', FALSE);
  }
}