1<loader loading="loading"></loader>
2<div id="sensors-overview">
3	<div class="row column">
4		<h1>Sensors</h1>
5	</div>
6	<section class="row column">
7		<div class="page-header">
8			<h2 class="inline h4">All sensors present in the system</h2>
9			<a ng-href="data:text/json;charset=utf-8,{{export_data}}" class="inline btn-export float-right" download="{{export_name}}">Export</a>
10		</div>
11	</section>
12	<section class="row column">
13		<!-- search -->
14		<p class="content-label" aria-label="sensors filter">Filter sensors</p>
15		<div class="content__search">
16			<label for="content__search-input">Sensors Search</label>
17			<input id="content__search-input" type="text" ng-model="customSearch" ng-keydown="doSearchOnEnter($event)"/>
18			<div class="search-submit__wrapper">
19				<button class="clear-input" ng-click="clear()">&#10005;</button>
20				<input id="content__search-submit" type="submit" class="btn btn-primary content__search-submit" value="Filter" ng-click="doSearchOnClick()"/>
21			</div>
22
23		</div>
24		<div class="toggle-filter">
25			<p class="content-label">FILTER BY SEVERITY</p>
26			<button class="inline first btn-primary" ng-click="toggleSeverityAll()"
27					ng-class="selectedSeverity.all ? 'btn-primary' : 'btn-secondary'">All
28			</button>
29			<button class="inline " ng-click="toggleSeverity('critical')"
30					ng-class="selectedSeverity.critical ? 'btn-primary' : 'btn-secondary'">Critical
31			</button>
32			<button class="inline" ng-click="toggleSeverity('warning')"
33					ng-class="selectedSeverity.warning ? 'btn-primary' : 'btn-secondary'">Warning
34			</button>
35		</div>
36
37	</section> <!-- end search -->
38
39	<section class="row column" ng-show="filteredSensorData.length == 0">
40		<!-- message -->
41		<span ng-if="selectedSeverity.all">{{messages.NO_SENSOR_DATA}}</span>
42		<span ng-if="selectedSeverity.critical">{{messages.CRITICAL_NO_SENSOR_DATA}}</span>
43		<span ng-if="selectedSeverity.warning">{{messages.WARNING_NO_SENSOR_DATA}}</span>
44		<!-- end message -->
45	</section>
46
47	<section id="sensor-categories" class="row column" ng-show="filteredSensorData.length">
48		<div class="row column header-row">
49			<div class="column large-12 header__actions-bar">
50				<p class="inline sensor__title">Sensors</p>
51				<p class="inline sensor__reading">Low critical</p>
52				<p class="inline sensor__reading">Low warning</p>
53				<p class="inline sensor__reading sensor__heading-current">Current</p>
54				<p class="inline sensor__reading">High warning</p>
55				<p class="inline sensor__reading">High critical</p>
56			</div>
57		</div>
58		<!-- sensor -->
59		<div class="sensor__readings-row" ng-repeat="sensor in data|filter:filterBySeverity|filter:filterBySearchTerms|orderBy:'+custom_order' as filteredSensorData">
60			<p class="inline sensor__title"><span class="icon" ng-class="{'icon__critical': sensor.status == 'critical', 'icon__warning': sensor.status == 'warning', 'icon__normal': sensor.status == 'normal'}" aria-label="sensor.status" ></span>{{sensor.title}}</p>
61			<p class="inline sensor__reading"><span class="sensor__label">Low critical</span>{{sensor.CriticalLow}}<span class="content-label">{{sensor.unit}}<span ng-if="sensor.unit == 'C'">&deg;</span></p>
62			<p class="inline sensor__reading"><span class="sensor__label">Low warning</span>{{sensor.WarningLow}}<span class="content-label">{{sensor.unit}}<span ng-if="sensor.unit == 'C'">&deg;</span></p>
63			<p class="inline sensor__reading sensor__current" ng-class="{'sensor__critical': sensor.status == 'critical', 'sensor__warn': sensor.status == 'warning', 'sensor__normal': sensor.status == 'normal'}"><span class="sensor__label">Current</span>{{sensor.Value}}<span class="content-label">{{sensor.unit}}<span ng-if="sensor.unit == 'C'">&deg;</span></span></p>
64			<p class="inline sensor__reading"><span class="sensor__label">High warning</span>{{sensor.WarningHigh}}<span class="content-label">{{sensor.unit}}<span ng-if="sensor.unit == 'C'">&deg;</span></p>
65			<p class="inline sensor__reading"><span class="sensor__label">High critical</span>{{sensor.CriticalHigh}}<span class="content-label">{{sensor.unit}}<span ng-if="sensor.unit == 'C'">&deg;</span></p>
66		</div>
67	</section>
68</div>