mirror of
https://github.com/Karaka-Management/oms-Monitoring.git
synced 2026-01-24 22:38:41 +00:00
Adding git report functionality
This commit is contained in:
parent
31567e65d4
commit
af7016a227
|
|
@ -21,6 +21,15 @@ $log = $this->app->logger->getByLine((int) $this->request->getData(
|
|||
$temp = trim($log['backtrace']);
|
||||
$log['backtrace'] = json_decode($temp, true);
|
||||
|
||||
$details = '* Uri: `' . trim($log['path']) . "`\n"
|
||||
. '* Level: `' . trim($log['level']) . "`\n"
|
||||
. '* Message: `' . trim($log['message']) . "`\n"
|
||||
. '* File: `' . trim($log['file']) . "`\n"
|
||||
. '* Line: `' . trim($log['line']) . "`\n"
|
||||
. '* Version: `' . trim($log['version']) . "`\n"
|
||||
. '* OS: `' . trim($log['os']) . "`\n\n"
|
||||
. "Backtrace: \n\n```\n" . json_encode($log['backtrace'], JSON_PRETTY_PRINT);
|
||||
|
||||
echo $this->getData('nav')->render(); ?>
|
||||
|
||||
<section class="box w-100">
|
||||
|
|
@ -36,13 +45,18 @@ echo $this->getData('nav')->render(); ?>
|
|||
<td><?= $this->l11n->lang['Monitoring']['Time']; ?>
|
||||
<td><i class="fa fa-clock-o"></i>
|
||||
<td><?= $log['datetime']; ?>
|
||||
<tr>
|
||||
<td><?= $this->l11n->lang['Monitoring']['Uri']; ?>
|
||||
<td><i class="fa fa-globe"></i>
|
||||
<td><?= $log['path']; ?>
|
||||
<tr>
|
||||
<td><?= $this->l11n->lang['Monitoring']['Source']; ?>
|
||||
<td><i class="fa fa-wifi"></i>
|
||||
<td><?= $log['ip']; ?>
|
||||
<tr>
|
||||
<td><?= $this->l11n->lang['Monitoring']['Level']; ?>
|
||||
<td><i class="fa fa-<?= in_array($log['level'], ['notice', 'info', 'debug']) ? 'info-circle' : 'warning'; ?>"></i>
|
||||
<td>
|
||||
<i class="fa fa-<?= in_array($log['level'], ['notice', 'info', 'debug']) ? 'info-circle' : 'warning'; ?>"></i>
|
||||
<td><?= $log['level']; ?>
|
||||
<tr>
|
||||
<td><?= $this->l11n->lang['Monitoring']['Message']; ?>
|
||||
|
|
@ -69,6 +83,9 @@ echo $this->getData('nav')->render(); ?>
|
|||
<tr>
|
||||
<td colspan="3">
|
||||
<pre><?= json_encode($log['backtrace'], JSON_PRETTY_PRINT); ?></pre>
|
||||
<tr>
|
||||
<td colspan="3" style="padding-top: 10px"><a class="button" target="_blank"
|
||||
href="https://gitreports.com/issue/Orange-Management/Orange-Management/?name=Guest&issue_title=<?= urlencode($log['message']); ?>&details=<?= urlencode($details); ?>"><?= $this->l11n->lang['Monitoring']['Report']; ?></a>
|
||||
</table>
|
||||
</div>
|
||||
</section>
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@ echo $this->getData('nav')->render(); ?>
|
|||
<td><a href=<?= $url; ?>><i class="fa fa-clock-o"></i> <?= $value[0] ?? ''; ?></a>
|
||||
<td><a href=<?= $url; ?>><i class="fa fa-<?= in_array($value[1], ['notice', 'info', 'debug']) ? 'info-circle' : 'warning'; ?>"></i> <?= $value[1] ?? ''; ?></a>
|
||||
<td><a href=<?= $url; ?>><i class="fa fa-wifi"></i> <?= $value[2] ?? ''; ?></a>
|
||||
<td><a href=<?= $url; ?>><i class="fa fa-commenting"></i> <?= $value[6] ?? ''; ?></a>
|
||||
<td><a href=<?= $url; ?>><i class="fa fa-commenting"></i> <?= $value[7] ?? ''; ?></a>
|
||||
<?php endforeach;
|
||||
if (!isset($key)) : ?>
|
||||
<tr>
|
||||
|
|
|
|||
|
|
@ -42,11 +42,13 @@ $MODLANG['Monitoring'] = [
|
|||
'Penetrators' => 'Penetrators',
|
||||
'RAMUsage' => 'RAM Usage',
|
||||
'Release' => 'Release',
|
||||
'Report' => 'Report',
|
||||
'Source' => 'Source',
|
||||
'SystemRAM' => 'System RAM',
|
||||
'Theme' => 'Theme',
|
||||
'Time' => 'Time',
|
||||
'Timestamp' => 'Timestamp',
|
||||
'Uri' => 'Uri',
|
||||
'Version' => 'Version',
|
||||
'Warnings' => 'Warnings',
|
||||
];
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user