mirror of
https://github.com/stylersnico/librenms.git
synced 2026-08-03 00:11:49 +02:00
Merge pull request #644 from f0o/issue-643
Fix searchbox on device's eventlog
This commit is contained in:
@@ -19,14 +19,19 @@
|
|||||||
?>
|
?>
|
||||||
</select>
|
</select>
|
||||||
</label>
|
</label>
|
||||||
<input class=submit type=submit value=Search>
|
<input class="submit" type="submit" value="Search">
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
print_optionbar_end();
|
print_optionbar_end();
|
||||||
|
|
||||||
$entries = dbFetchRows("SELECT *,DATE_FORMAT(datetime, '%D %b %Y %T') as humandate FROM `eventlog` WHERE `host` = ? ORDER BY `datetime` DESC LIMIT 0,250", array($device['device_id']));
|
$sql = "";
|
||||||
|
if( !empty($_POST['string']) ) {
|
||||||
|
$sql .= " AND message LIKE '%".mres($_POST['string'])."%'";
|
||||||
|
}
|
||||||
|
|
||||||
|
$entries = dbFetchRows("SELECT *,DATE_FORMAT(datetime, '%D %b %Y %T') as humandate FROM `eventlog` WHERE `host` = ? $sql ORDER BY `datetime` DESC LIMIT 0,250", array($device['device_id']));
|
||||||
|
|
||||||
echo(' <div class="panel panel-default panel-condensed">
|
echo(' <div class="panel panel-default panel-condensed">
|
||||||
<div class="panel-heading">
|
<div class="panel-heading">
|
||||||
|
|||||||
Reference in New Issue
Block a user