You are here

function cas_user_identities in CAS 7

Same name and namespace in other branches
  1. 6.3 cas.pages.inc \cas_user_identities()

Menu callback; Manage CAS identities for the specified user.

1 string reference to 'cas_user_identities'
cas_menu in ./cas.module
Implements hook_menu().

File

./cas.pages.inc, line 11
User page callbacks for the cas module.

Code

function cas_user_identities($account) {
  drupal_set_title(check_plain(format_username($account)));
  $header = array(
    t('CAS username'),
    t('Operations'),
  );
  $rows = array();
  foreach ($account->cas_names as $aid => $cas_name) {
    $rows[] = array(
      check_plain($cas_name),
      l(t('Delete'), 'user/' . $account->uid . '/cas/delete/' . $aid),
    );
  }
  $build['cas_table'] = array(
    '#theme' => 'table',
    '#header' => $header,
    '#rows' => $rows,
  );
  $build['cas_user_add'] = drupal_get_form('cas_user_add', $account);
  return $build;
}