You are here

function theme_pm_dashboard in Drupal PM (Project Management) 7.2

Same name and namespace in other branches
  1. 8 pm.theme.inc \theme_pm_dashboard()
  2. 7.3 pm.theme.inc \theme_pm_dashboard()
  3. 7 pm.theme.inc \theme_pm_dashboard()

Provides HTML for a Project Management dashboard.

File

./pm.theme.inc, line 10
Provides theme functions for Project Management modules.

Code

function theme_pm_dashboard($link_blocks) {
  $content = '<div id="pmdashboard">';
  if (!empty($link_blocks)) {
    $content .= '<dl class="pmdashboard clear-block">';
    foreach ($link_blocks as $link_block_array) {
      $content .= '<div class="pmdashboard">';
      if (!empty($link_block_array) and is_array($link_block_array)) {
        foreach ($link_block_array as $link_array) {
          if (!empty($link_array['theme'])) {
            $content .= theme($link_array['theme'], $link_array);
          }
          else {
            $content .= theme('pm_dashboard_link', $link_array);
          }
        }
      }
      $content .= '</div>';
    }
    $content .= '</dl>';
  }
  else {
    $content .= t('No dashboard links available');
  }
  $content .= '</div>';
  return $content;
}