Files
Tony Murray daffa7e274 Eventlog updates (#9633)
* Eventlog updates
remove host from eventlog table, retain in api
allow most fields nullable

* updated schema

* revert auth for legacy log_event function
safer check in the model

* add function modifiers
2019-01-10 00:52:00 -06:00

21 lines
836 B
PHP

<?php
echo ' <div class="row">
<div class="col-md-12">
<div class="panel panel-default panel-condensed">
<div class="panel-heading">';
echo '<a href="device/device='.$device['device_id'].'/tab=logs/section=eventlog/">';
echo '<i class="fa fa-bookmark fa-lg icon-theme" aria-hidden="true"></i> <strong>Recent Events</strong></a>';
echo ' </div>
<table class="table table-hover table-condensed table-striped">';
$eventlog = dbFetchRows("SELECT *,DATE_FORMAT(datetime, '".$config['dateformat']['mysql']['compact']."') as humandate FROM `eventlog` WHERE `device_id` = ? ORDER BY `datetime` DESC LIMIT 0,10", [$device['device_id']]);
foreach ($eventlog as $entry) {
include 'includes/print-event-short.inc.php';
}
echo '</table>';
echo '</div>';
echo '</div>';
echo '</div>';