From a70996f723a9598c1d653bb615c0b32b263b20d5 Mon Sep 17 00:00:00 2001 From: "Ramón M. Gómez" Date: Thu, 14 May 2020 13:39:41 +0200 Subject: #947: Fix bug when counting RemotePC-enabled labs. --- admin/WebConsole/principal/estadisticas.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/admin/WebConsole/principal/estadisticas.php b/admin/WebConsole/principal/estadisticas.php index eede5aaf..ced1cc58 100644 --- a/admin/WebConsole/principal/estadisticas.php +++ b/admin/WebConsole/principal/estadisticas.php @@ -74,7 +74,7 @@ SELECT * FROM (SELECT nombrecentro AS ou, COUNT(DISTINCT idaula) AS labs, COUNT(DISTINCT IF(idordprofesor > 0, idaula, NULL)) AS hasprof, - COUNT(IF(inremotepc = 1, 1, NULL)) AS remotelab, + COUNT(DISTINCT IF(inremotepc = 1, idaula, NULL)) AS remotelab, COUNT(idordenador) AS clients, COUNT(numserie) AS hasconfig, COUNT(IF(idrepositorio > 0, 1, NULL)) AS hasrepo, @@ -124,4 +124,4 @@ EOT; function print_data_row($label, $value, $total=0) { echo "\t\t $label:  $value" . ($total>0 ? " (".intval($value*100/$total)."%)" : "") . " \n"; -} \ No newline at end of file +} -- cgit v1.2.3-18-g5258