wazuh-kibana-app/public/templates/management/logs.html

82 lines
4.4 KiB
HTML
Raw Normal View History

2018-11-02 16:03:15 +00:00
<div layout="column" class="mozilla-table-size-85" ng-controller="managerLogController as ctrl" ng-if="!ctrl.loading && mctrl.tab == 'logs'">
2018-07-02 12:54:33 +00:00
<!-- Headline -->
2018-11-02 07:42:35 +00:00
<div ng-show="!ctrl.loading" layout="column" layout-padding>
2018-07-02 12:54:33 +00:00
<span class="font-size-18"><i class="fa fa-fw fa-pencil-square-o" aria-hidden="true"></i> Logs</span>
<span class="md-subheader">Review the logs of all Wazuh manager daemons</span>
</div>
<!-- End headline -->
2018-05-28 14:09:35 +00:00
<!-- Filters and Realtime button section -->
2018-11-02 07:42:35 +00:00
<div ng-show="!ctrl.loading" layout="row" layout-align="start center" class="md-padding">
2018-10-09 07:05:22 +00:00
<!-- Daemon selector -->
<div flex="20" layout="column" layout-align="center" class="height-40 wz-margin-right-15 wz-select-input">
2018-11-02 07:42:35 +00:00
<select flex class="kuiSelect wz-border-none cursor-pointer max-height-35" ng-disabled="ctrl.realtime || !ctrl.daemons.length" id="categoryBox" ng-model="ctrl.category" ng-change="ctrl.filter({name:'category',value:ctrl.category})"
2018-03-08 11:59:39 +00:00
aria-label="Logs category">
2018-05-28 14:09:35 +00:00
<option value="all">All daemons</option>
2018-11-02 07:42:35 +00:00
<option ng-repeat="daemon in ctrl.daemons | orderObjectBy: 'title'" value="{{daemon.title}}">{{daemon.title}}</option>
2018-03-08 11:59:39 +00:00
</select>
</div>
2018-05-28 14:09:35 +00:00
<!-- End daemon selector -->
2016-09-20 08:55:43 +00:00
2018-05-28 14:09:35 +00:00
<!-- Level selector -->
<div flex="20" layout="column" layout-align="center" class="height-40 wz-select-input wz-margin-right-15">
2018-11-02 07:42:35 +00:00
<select flex class="kuiSelect wz-border-none cursor-pointer max-height-35" ng-disabled="ctrl.realtime" id="levelBox" ng-model="ctrl.type_log" ng-change="ctrl.filter({name:'type_log',value:ctrl.type_log})"
2018-03-08 11:59:39 +00:00
aria-label="Logs level">
2018-05-28 14:09:35 +00:00
<option value="all">All log levels</option>
2018-03-08 11:59:39 +00:00
<option value="info">Info</option>
<option value="error">Error</option>
<option value="warning">Warning</option>
2018-07-26 15:03:27 +00:00
<option value="critical">Critical</option>
<option value="debug">Debug</option>
2018-03-08 11:59:39 +00:00
</select>
</div>
2018-11-02 07:42:35 +00:00
<div flex="20" layout="column" ng-show="ctrl.nodeList" layout-align="center" class="height-40 wz-select-input">
<select flex class="kuiSelect wz-border-none cursor-pointer max-height-35" ng-disabled="ctrl.realtime" id="categoryBox" ng-model="ctrl.selectedNode" ng-change="ctrl.changeNode(ctrl.selectedNode)"
aria-label="Logs category">
2018-11-02 07:42:35 +00:00
<option ng-repeat="node in ctrl.nodeList" value="{{node}}">{{node}}</option>
</select>
</div>
2018-05-28 14:09:35 +00:00
<!-- End Level selector -->
2018-05-28 14:09:35 +00:00
<!-- White space between filters and Realtime button -->
2017-11-21 17:22:49 +00:00
<span flex></span>
2018-05-28 14:09:35 +00:00
2018-11-12 16:47:36 +00:00
<md-button ng-if="!ctrl.realtime" class="wz-button md-raised md-primary no-margin-right" ng-click="ctrl.playRealtime()" aria-label="Play realtime button">
2018-02-20 11:36:06 +00:00
<i class="fa fa-play fa-fw" aria-hidden="true"></i>
2017-11-21 17:22:49 +00:00
Play realtime
</md-button>
2018-11-12 16:47:36 +00:00
<md-button ng-if="ctrl.realtime" class="wz-button md-raised md-primary no-margin-right" ng-click="ctrl.stopRealtime()" aria-label="Stop realtime button">
2018-02-20 11:36:06 +00:00
<i class="fa fa-stop fa-fw" aria-hidden="true"></i>
2017-11-21 17:22:49 +00:00
Stop realtime
</md-button>
</div>
2018-05-28 14:09:35 +00:00
<!-- End Filters and Realtime button section -->
2018-02-20 11:36:06 +00:00
2018-11-02 07:42:35 +00:00
<div layout="row" flex class="md-padding" ng-if="ctrl.logsPath">
<input placeholder="Filter logs..." ng-model="ctrl.custom_search" type="text" class="kuiLocalSearchInput ng-empty ng-pristine ng-scope ng-touched ng-valid"
aria-invalid="false" wz-enter="ctrl.search(ctrl.custom_search)">
<button type="submit" aria-label="Search" class="kuiLocalSearchButton height-40" ng-click="ctrl.search(ctrl.custom_search)">
<span class="fa fa-search" aria-hidden="true"></span>
</button>
</div>
2018-05-28 14:09:35 +00:00
<!-- Logs table section -->
2018-11-02 07:42:35 +00:00
<div layout="row" layout-padding ng-if="ctrl.logsPath">
2018-08-16 15:02:30 +00:00
<wz-table
2018-07-02 12:54:33 +00:00
flex
2018-07-09 13:05:22 +00:00
extra-limit="true"
2018-11-02 07:42:35 +00:00
path="ctrl.logsPath"
2018-06-19 15:37:21 +00:00
keys="['timestamp',{value:'tag',size:2},'level',{value:'description',size:4,nosortable:true}]"
row-sizes="[12,10,7]">
2018-08-16 15:02:30 +00:00
</wz-table>
2017-10-20 20:37:42 +00:00
</div>
2018-05-28 14:09:35 +00:00
<!-- End Logs table section -->
2018-07-02 12:54:33 +00:00
<div layout="row" layout-padding>
<span flex></span>
2018-11-02 07:42:35 +00:00
<a class="small" id="btnDownload" ng-click="ctrl.downloadCsv()">Formatted <i aria-hidden="true" class="fa fa-fw fa-download"></i></a>
</div>
2017-11-21 17:22:49 +00:00
</div>