Fixed problem with viewing from a filter that had monitor name in.

git-svn-id: http://svn.zoneminder.com/svn/zm/trunk@1008 e3e1d417-86f3-4887-817a-d78f3d33393f
This commit is contained in:
stan 2004-04-19 10:38:22 +00:00
parent 70c7ed31d6
commit c0f8237895
1 changed files with 2 additions and 2 deletions

View File

@ -49,7 +49,7 @@ $event = mysql_fetch_assoc( $result );
parseSort();
parseFilter();
$sql = "select * from Events as E where $sort_column ".($sort_order=='asc'?'<=':'>=')." '".$event[$sort_field]."'$filter_sql$mid_sql order by $sort_column ".($sort_order=='asc'?'desc':'asc');
$sql = "select E.* from Events as E inner join Monitors as M on E.MonitorId = M.Id where $sort_column ".($sort_order=='asc'?'<=':'>=')." '".$event[$sort_field]."'$filter_sql$mid_sql order by $sort_column ".($sort_order=='asc'?'desc':'asc');
$result = mysql_query( $sql );
if ( !$result )
die( mysql_error() );
@ -62,7 +62,7 @@ while ( $row = mysql_fetch_assoc( $result ) )
}
}
$sql = "select * from Events as E where $sort_column ".($sort_order=='asc'?'>=':'<=')." '".$event[$sort_field]."'$filter_sql$mid_sql order by $sort_column $sort_order";
$sql = "select E.* from Events as E inner join Monitors as M on E.MonitorId = M.Id where $sort_column ".($sort_order=='asc'?'>=':'<=')." '".$event[$sort_field]."'$filter_sql$mid_sql order by $sort_column $sort_order";
$result = mysql_query( $sql );
if ( !$result )
die( mysql_error() );