Include Event Summaries when loading Monitors

This commit is contained in:
Isaac Connor 2021-04-09 19:46:57 -04:00
parent 3dcb71933e
commit 1ccb8d7aef
1 changed files with 6 additions and 2 deletions

View File

@ -171,10 +171,14 @@ $html .= '</span>
$html .= '</span> $html .= '</span>
'; ';
$sql = 'SELECT *,S.Status AS Status, S.CaptureFPS AS CaptureFPS, S.AnalysisFPS AS AnalysisFPS, S.CaptureBandwidth AS CaptureBandwidth $sql = 'SELECT M.*, S.*, E.*
FROM Monitors AS M LEFT JOIN Monitor_Status AS S ON MonitorId=Id ' . FROM Monitors AS M
LEFT JOIN Monitor_Status AS S ON S.MonitorId=M.Id
LEFT JOIN Event_Summaries AS E ON E.MonitorId=M.Id
' .
( count($conditions) ? ' WHERE ' . implode(' AND ', $conditions) : '' ).' ORDER BY Sequence ASC'; ( count($conditions) ? ' WHERE ' . implode(' AND ', $conditions) : '' ).' ORDER BY Sequence ASC';
$monitors = dbFetchAll($sql, null, $values); $monitors = dbFetchAll($sql, null, $values);
ZM\Debug(print_r($monitors, true));
$displayMonitors = array(); $displayMonitors = array();
$monitors_dropdown = array(); $monitors_dropdown = array();