You are here

function theme_biblio_admin_author_edit_merge_table in Bibliography Module 7

1 theme call to theme_biblio_admin_author_edit_merge_table()
biblio_admin_author_edit_form in includes/biblio.admin.inc
_state

File

includes/biblio_theme.inc, line 1272

Code

function theme_biblio_admin_author_edit_merge_table($variables) {
  $form = $variables['form'];
  $headers = $form['#header'];
  $rows = array();
  foreach (element_children($form['candidates']) as $key) {

    // Build the table row.
    $row = array();
    $row[] = array(
      'data' => drupal_render($form['candidates'][$key]['name']),
    );
    $row[] = drupal_render($form['candidates'][$key]['link']);
    $row[] = drupal_render($form['candidates'][$key]['merge']);
    $row[] = drupal_render($form['candidates'][$key]['retain']);
    $rows[] = $row;
  }
  $output = theme('table', array(
    'header' => $headers,
    'rows' => $rows,
    'attributes' => array(
      'id' => $form['#id'],
    ),
  ));
  $row = $rows = array();
  $row[] = array(
    'data' => drupal_render($form['more_authors_search']) . drupal_render($form['more_authors_add']),
  );
  $rows[] = $row;
  $output .= theme('table', array(
    'header' => array(),
    'rows' => $rows,
    'attributes' => array(
      'id' => $form['#id'],
    ),
  ));
  $output .= drupal_render_children($form);
  return $output;
}