| <!-- |
| Licensed to the Apache Software Foundation (ASF) under one |
| or more contributor license agreements. See the NOTICE file |
| distributed with this work for additional information |
| regarding copyright ownership. The ASF licenses this file |
| to you under the Apache License, Version 2.0 (the |
| "License"); you may not use this file except in compliance |
| with the License. You may obtain a copy of the License at |
| |
| http://www.apache.org/licenses/LICENSE-2.0 |
| |
| Unless required by applicable law or agreed to in writing, software |
| distributed under the License is distributed on an "AS IS" BASIS, |
| WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| See the License for the specific language governing permissions and |
| limitations under the License. |
| --> |
| |
| <div class="box box-primary"> |
| <div class="box-header with-border"> |
| <span class="fa fa-bell"></span> |
| <h3 class="box-title"> |
| Alert List |
| </h3> |
| </div> |
| <div class="box-body"> |
| <!-- Site Filter --> |
| <ul class="nav nav-pills with-border"> |
| <li><span>Site Filter:</span></li> |
| <li ng-class="{active: siteFilter === ''}" ng-click="updateSiteFilter('')"><a>All</a></li> |
| <li ng-class="{active: siteFilter === site.siteId}" ng-click="updateSiteFilter(site.siteId)" |
| ng-repeat="site in Site.list track by $index"> |
| <a>{{site.siteName || site.siteId}}</a> |
| </li> |
| </ul> |
| |
| <div sort-table="alertList" is-sorting="isSorting"> |
| <table class="table table-bordered"> |
| <thead> |
| <tr> |
| <th sortpath="alertTimestamp" width="135"> |
| Time |
| <span class="fa fa-refresh fa-spin no-animate" ng-show="loading || isSorting"></span> |
| </th> |
| <th sortpath="tags.severity" width="85">Severity</th> |
| <th sortpath="tags.siteId" width="75">Site</th> |
| <!--th sortpath="streamId" width="75">Stream</th--> |
| <th width="100" sortpath="tags.category" >Category</th> |
| <th>Subject</th> |
| <th sortpath="tags.policyId" width="75">Policy</th> |
| <th width="10"></th> |
| </tr> |
| </thead> |
| <tbody> |
| <tr> |
| <td>{{Time.format(item.timestamp)}}</td> |
| <td> |
| <span class="label label-{{Policy.getSeverityClass(item.tags.severity)}}"> |
| {{item.tags.severity}} |
| </span> |
| </td> |
| <td>{{item.tags.siteId}}</td> |
| <!--<td>--> |
| <!--<ul class="list-unstyled">--> |
| <!--<li ng-repeat="app in item.appIds track by $index" class="label label-sm label-primary">--> |
| <!--{{Application.findProvider(app).type || app}}--> |
| <!--</li>--> |
| <!--</ul>--> |
| <!--</td>--> |
| <td>{{item.tags.category || "N/A"}}</td> |
| <td><a ui-sref="alertDetail({alertId: item.tags.alertId})" title="{{item.alertBody}}">{{item.alertSubject}}</a></td> |
| <!--td>{{item.streamId}}</td--> |
| <!--td class="text-break"> |
| <span ng-if="displayType === 'raw'" na-block="item.alertData"></span> |
| <div ng-if="displayType === 'format'" na-block="!!item.alertData"> |
| <ul> |
| <li ng-repeat="(key, value) in item.alertData track by $index"> |
| <strong>{{key}}:</strong> |
| {{value}} |
| </li> |
| </ul> |
| </div> |
| </td--> |
| <td> |
| <a ui-sref="policyDetail({name: item.tags.policyId})">{{item.tags.policyId}}</a> |
| </td> |
| <td> |
| <a ui-sref="alertDetail({alertId: item.tags.alertId})">detail</a> |
| </td> |
| </tr> |
| </tbody> |
| </table> |
| </div> |
| </div> |
| </div> |