You are here

function template_preprocess_timefield_weekly_summary_minical_box in Timefield 7

Template preprocess function for the minical box. Every element added to a minical will be themed with this function.

File

./timefield.module, line 941
Defines a Field API field for time

Code

function template_preprocess_timefield_weekly_summary_minical_box(&$variables) {
  $variables['label'] = $variables['element']['label'];
  $variables['time'] = timefield_integer_to_time($variables['settings']['display_format'], $variables['element']['value']);
  if (isset($variables['element']['value2'])) {
    $variables['time'] .= '-' . timefield_integer_to_time($variables['settings']['display_format'], $variables['element']['value2']);
  }
  $variables['classes'] = implode(' ', $variables['classes_array']);
}