$DB->query("SELECT
p.ID,
p.Name,
p.Level,
p.Secondary,
COUNT(u.ID)+COUNT(DISTINCT l.UserID)
FROM permissions AS p
LEFT JOIN users_main AS u ON u.PermissionID=p.ID
LEFT JOIN users_levels AS l ON l.PermissionID=p.ID
GROUP BY p.ID
ORDER BY p.Secondary ASC, p.Level ASC");
if ($DB->record_count()) {
?>
Name |
Level |
User count |
Actions |
while (list($ID,$Name,$Level,$Secondary,$UserCount)=$DB->next_record()) { ?>
=display_str($Name); ?> |
=($Secondary ? 'Secondary' : $Level) ?> |
=number_format($UserCount); ?> |
Edit
Remove
|
} ?>
} else { ?>
There are no permission classes.
} ?>
View::show_footer();
?>