From: nicolasconnault Date: Thu, 13 Mar 2008 12:13:26 +0000 (+0000) Subject: MDL-13300 Adds verbosity to the heading above the list of participants, showing which... X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=f642a21aad43af600f76104442f8222e63960328;p=moodle.git MDL-13300 Adds verbosity to the heading above the list of participants, showing which group is selected, and the inactivity time period, if either of these two filters are used --- diff --git a/lang/en_utf8/role.php b/lang/en_utf8/role.php index ad296ca3d5..7f2e9c4a0e 100644 --- a/lang/en_utf8/role.php +++ b/lang/en_utf8/role.php @@ -167,7 +167,9 @@ $string['user:viewdetails'] = 'View user profiles'; $string['user:viewhiddendetails'] = 'View hidden details of users'; $string['user:viewuseractivitiesreport'] = 'See user activity reports'; $string['viewrole'] = 'View role details'; -$string['xuserswiththerole'] = 'Users with the role \"$a->role\": $a->number'; +$string['xuserswiththerole'] = 'Users with the role \"$a->role\"'; +$string['ingroup'] = 'in the group \"$a->group\"'; +$string['inactiveformorethan'] = 'inactive for more than $a->timeperiod'; // MNET $string['site:mnetlogintoremote'] = 'Roam to a remote Moodle'; diff --git a/user/index.php b/user/index.php index b6df199bae..7a9aeca35d 100644 --- a/user/index.php +++ b/user/index.php @@ -508,7 +508,21 @@ }else{ $a->role = $currentrole->name;//safety net } - $heading = format_string(get_string('xuserswiththerole', 'role', $a)); + + $heading = format_string(get_string('xuserswiththerole', 'role', $a)); + + if ($currentgroup and $group) { + $a->group = $group->name; + $heading .= ' ' . format_string(get_string('ingroup', 'role', $a)); + } + + if ($accesssince) { + $a->timeperiod = $timeoptions[$accesssince]; + $heading .= ' ' . format_string(get_string('inactiveformorethan', 'role', $a)); + } + + $heading .= ": $a->number"; + if (user_can_assign($context, $roleid)) { $heading .= ' '; $heading .= '';