Skip to content
Snippets Groups Projects
Commit c60aaa75 authored by Jared Hancock's avatar Jared Hancock
Browse files

Merge pull request #205 from protich/issue/203


Fix staff and departments count on groups page

Reviewed-by: default avatarJared Hancock <jared@osticket.com>
parents cc15be08 894eb03b
No related branches found
No related tags found
No related merge requests found
......@@ -3,7 +3,7 @@ if(!defined('OSTADMININC') || !$thisstaff || !$thisstaff->isAdmin()) die('Access
$qstr='';
$sql='SELECT grp.*,count(staff.staff_id) as users, count(dept.dept_id) as depts '
$sql='SELECT grp.*,count(DISTINCT staff.staff_id) as users, count(DISTINCT dept.dept_id) as depts '
.' FROM '.GROUP_TABLE.' grp '
.' LEFT JOIN '.STAFF_TABLE.' staff ON(staff.group_id=grp.group_id) '
.' LEFT JOIN '.GROUP_DEPT_TABLE.' dept ON(dept.group_id=grp.group_id) '
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment