mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-04-08 18:55:09 +02:00
Fixed error, when type modules is Asyncronous type, tiquet: #2193
(cherry picked from commit 7efff2181640af397efb5f0f2c6eb41a7906b938)
This commit is contained in:
parent
f51a36fd3d
commit
c8d152c9cf
@ -130,7 +130,7 @@ function mainModuleGroups() {
|
||||
//The big query
|
||||
switch ($config["dbtype"]) {
|
||||
case "mysql":
|
||||
$sql = "SELECT COUNT(id_agente) AS count, case utimestamp when 0 then 5 else estado end as estado
|
||||
$sql = "SELECT COUNT(id_agente) AS count, estado
|
||||
FROM tagente_estado
|
||||
WHERE id_agente IN
|
||||
(SELECT id_agente FROM tagente WHERE id_grupo = %d AND disabled IS FALSE)
|
||||
@ -141,8 +141,7 @@ function mainModuleGroups() {
|
||||
GROUP BY estado";
|
||||
break;
|
||||
case "postgresql":
|
||||
$sql = "SELECT COUNT(id_agente) AS count,
|
||||
case utimestamp when 0 then 5 else estado end as estado
|
||||
$sql = "SELECT COUNT(id_agente) AS count, estado
|
||||
FROM tagente_estado
|
||||
WHERE id_agente IN
|
||||
(SELECT id_agente FROM tagente WHERE id_grupo = %d AND disabled = 0)
|
||||
@ -153,7 +152,7 @@ function mainModuleGroups() {
|
||||
GROUP BY estado, utimestamp";
|
||||
break;
|
||||
case "oracle":
|
||||
$sql = "SELECT COUNT(id_agente) AS count, case when utimestamp = 0 then 5 else estado end estado
|
||||
$sql = "SELECT COUNT(id_agente) AS count, estado
|
||||
FROM tagente_estado
|
||||
WHERE id_agente IN
|
||||
(SELECT id_agente FROM tagente WHERE id_grupo = %d AND (disabled IS NOT NULL AND disabled <> 0))
|
||||
|
Loading…
x
Reference in New Issue
Block a user