Skip to content

Commit

Permalink
Use the new print_user function for the group
Browse files Browse the repository at this point in the history
  • Loading branch information
moodler committed Jan 10, 2004
1 parent 499795e commit 548ef30
Showing 1 changed file with 1 addition and 13 deletions.
14 changes: 1 addition & 13 deletions course/group.php
Expand Up @@ -76,21 +76,9 @@
echo '<br />';

if ($users = get_users_in_group($group->id)) {
$table->align = array('left', 'left');
$table->width = array('100', '*');
foreach ($users as $user) {
if (!$lastaccess = get_field("user_students", "timeaccess", "userid", $user->id, "course", $course->id)) {
if (!$lastaccess = get_field("user_teachers", "timeaccess", "userid", $user->id, "course", $course->id)) {
$datestring = get_string("never");
}
}
if ($lastaccess) {
$datestring = userdate($lastaccess)."&nbsp (".format_time(time() - $lastaccess).")";
}
$information = '<p><b>'.fullname($user).'</b></p>'.get_string("lastaccess").": $datestring";
$table->data[] = array(print_user_picture($user->id, $course->id, $user->picture, true, true), $information);
print_user($user, $course);
}
print_table($table);
} else {
print_heading(get_string('nousersyet'));
}
Expand Down

0 comments on commit 548ef30

Please sign in to comment.