You are here

function forena_query_load_block in Forena Reports 7.3

1 string reference to 'forena_query_load_block'
forena_query_builder_form in ./forena_query.inc

File

./forena_query.inc, line 210

Code

function forena_query_load_block($form, &$form_state) {
  $form_state['rebuild'] = TRUE;
  $form_state['storage']['new'] = FALSE;
  @(list($provider, $block) = @explode('/', $form_state['values']['block'], 2));
  $block_def = @Frx::RepoMan()
    ->loadBlock($form_state['values']['block']);
  $form_state['storage']['block'] = $block_def;
  $form_state['storage']['provider'] = $provider;
  $form_state['storage']['block_name'] = $form_state['values']['block'];
  if (@$block_def['builder']) {
    $form_state['storage']['builder'] = $block_def['builder'];
    $form_state['storage']['step'] = 'builder';
  }
  else {
    $form_state['storage']['step'] = 'sql';
  }
}