function analytics_dashboard_page

cis7 analytics_dashboard.module analytics_dashboard_page()

Page callback for report page.

1 string reference to 'analytics_dashboard_page'
analytics_dashboard_menu in sites/all/modules/local_contrib/google_chart_tools/analytics_dashboard/analytics_dashboard.module
Implements hook_menu().

File

sites/all/modules/local_contrib/google_chart_tools/analytics_dashboard/analytics_dashboard.module, line 58

Code

function analytics_dashboard_page() {
  module_load_include('inc', 'analytics_dashboard', 'analytics_dashboard.charts');
  module_load_include('inc', 'analytics_dashboard', 'analytics_dashboard.forms');
  $form = drupal_get_form('analytics_dashboard_form');
  $form = drupal_render($form);
  $charts = analytics_dashboard_get_charts();
  $visibles = variable_get('chart_visible', array());
  $ret = $form;
  $ret .= '<div id="charts">';
  foreach ($charts as $chart) {
    if (in_array($chart['id'], $visibles, TRUE)) {
      $ret .= $chart['markup'];
    }
  }
  $ret .= '</div>';
  return $ret;
}