You are here

function quant_get_quant_charts in Quant 7

Fetch all available charts

6 calls to quant_get_quant_charts()
quant_admin_settings in ./quant.admin.inc
Provide admin settings form
quant_admin_settings_submit in ./quant.admin.inc
Submit the admin settings form
quant_admin_settings_validate in ./quant.admin.inc
Validate the admin settings form
quant_get_quant_chart in ./quant.module
Fetch a quant chart by ID
quant_uninstall in ./quant.install
Implementation of hook_uninstall()

... See full list

File

./quant.module, line 116

Code

function quant_get_quant_charts() {
  static $charts = NULL;

  // Act if the static cache is not yet populated
  if ($charts === NULL) {
    $charts = _quant_get_data('quant_charts');
    foreach ($charts as $key => $plugin) {

      // Include the file we need
      quant_include($plugin->plugin['file'], $plugin->plugin['path'], NULL);

      // Load the class so the functions can be accessed, if needed
      $charts[$key]->chart = new $plugin->plugin['class'](NULL, $plugin);
    }
  }
  return $charts;
}