I've managed to do what I wanted, adding this to users/index.php :
[green] if ($row['privileges'] == 2592) {
echo '<br />'."\n";
echo '· '._AT('access').': ';
$pending = '';
switch ($row['access']){
case 'public':
echo _AT('public');
break;
case 'protected':
echo _AT('protected');
break;
case 'private':
echo _AT('private');
$sql = "SELECT COUNT(*) FROM ".TABLE_PREFIX."course_enrollment WHERE course_id=$row[course_id] AND approved='n'";
$c_result = mysql_query($sql, $db);
$c_row = mysql_fetch_array($c_result);
$num_rows_c = mysql_num_rows($c_result);
if($c_row[0] > 0){
$pending = ', '.$c_row[0].' <em><strong>'._AT('pending_approval2').' <a href="bounce.php?course='.$row['course_id'].SEP.'p='.urlencode('tools/enrollment/index.php?current_tab=1').'"> '._AT('pending_approval3').'</a></strong></em>.';
}
break;
}
$c_sql = "SELECT COUNT(*) FROM ".TABLE_PREFIX."course_enrollment WHERE course_id=$row[course_id] AND approved='y'";
$c_result = mysql_query($c_sql, $db);
$c_row = mysql_fetch_array($c_result);
/* minus 1 because the instructor doesn't count */
echo "<br />\n· "._AT('enrolled').": ".($c_row[0]-1).$pending." ";
} [/green]
Privileges are given a code in AT_course_enrollment.
I'd be interested have the list of that code according to the privileges...
Exemple :
32 = File Manager
2592 = File Manager + Enrollment Manager
Maybe we could work this out together and put this somewhere on that site ? I'm sure it could be useful to other developpers...