diff --git a/admin/committees.php b/admin/committees.php index 210de28..40b5949 100644 --- a/admin/committees.php +++ b/admin/committees.php @@ -255,27 +255,35 @@ if($_GET['unlinkmember'] && $_GET['unlinkcommittee']) { $q2=mysql_query("SELECT committees_link.title, committees_link.ord, - users.accounts_id, - MAX(users.year) AS my, - users.lastname + committees_link.accounts_id FROM committees_link - JOIN users ON users.accounts_id = committees_link.accounts_id WHERE committees_id='{$r->id}' - GROUP BY users.accounts_id - ORDER BY ord, - users.lastname "); + ORDER BY ord"); echo "\n"; echo mysql_error(); while($r2=mysql_fetch_object($q2)) { $u = user_load_by_accounts_id($r2->accounts_id); + + //if rollover is proper, this shouldnt be necessary, but, the simcoe rollover didnt do this, so lets do it here as a safety + if(!$u) { + $roleq=mysql_query("SELECT * FROM roles WHERE type='committee'"); + $roler=mysql_fetch_object($roleq); + //hmm thats okay,w e must have missed something in the rollover... sicne its tied to the accounts_id, we just need to add a record + account_add_role($r2->accounts_id,$roler->id,$conference['id']); + + //and now we should be able to load them + $u = user_load_by_accounts_id($r2->accounts_id); + } + + echo "    "; echo "\"Edit\""; echo " "; echo "id}\">\"Unlink\""; echo ""; echo ""; - echo "{$u['name']}"; + echo "{$u['firstname']} {$u['lastname']}"; echo ""; echo "title}\" name=\"title[{$r->id}][{$u['accounts_id']}]\" size=\"25\">"; echo ""; diff --git a/user_edit_tabs.inc.php b/user_edit_tabs.inc.php index 1153004..80d23b5 100644 --- a/user_edit_tabs.inc.php +++ b/user_edit_tabs.inc.php @@ -89,6 +89,7 @@ $tabs = array( 'types' => array('teacher','participant','judge','committee','volunteer','sponsor','fair','admin','config'), 'file' => 'user_roles.php', 'status_func' => false, + 'enabled' => true, ), 'school' => array( 'label' => 'School',