blob: 0ec5e0f48da2fd98d97979ef653ee935a6dc19ca [file] [log] [blame]
{{!
* 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 id="hosts">
<div class="box-header row">
<div class="pull-left">
<span>{{t hosts.table.Search}}&nbsp;</span>{{view Ember.TextField valueBinding="view.globalSearchValue"}}
</div>
{{#if App.isAdmin}}
<div class="button-section pull-right">
<button class="btn btn-inverse add-host-button" {{action addHost}}>
<i class="icon-plus icon-white"></i>
{{t hosts.host.add}}
</button>
</div>
{{/if}}
</div>
<table class="datatable table table-bordered table-striped" id="hosts-table">
<thead>
<tr>
{{#view view.sortView contentBinding="view.filteredContent"}}
<th class="first"></th>
{{view view.parentView.nameSort}}
{{view view.parentView.ipSort}}
{{view view.parentView.cpuSort}}
{{view view.parentView.memorySort}}
{{view view.parentView.diskUsageSort}}
{{view view.parentView.loadAvgSort}}
<th>{{t common.components}}</th>
{{/view}}
</tr>
<tr>
<th class="first">&nbsp;</th>
<th>{{view view.nameFilterView}}</th>
<th>{{view view.ipFilterView}}</th>
<th>{{view view.cpuFilterView}}</th>
<th>{{view view.ramFilterView}}</th>
<th></th>
<th>{{view view.loadAvgFilterView}}</th>
<th>{{view view.componentsFilterView}}</th>
</tr>
</thead>
<tbody>
{{#if view.pageContent}}
{{#each host in view.pageContent}}
{{#view view.HostView contentBinding="host"}}
<td class="first">
<span {{bindAttr class="host.healthClass"}} {{bindAttr title="host.healthToolTip" }}></span>
</td>
<td class="name">
<a title="{{unbound host.publicHostName}}" href="#" {{action "showDetails" host}}>{{unbound host.publicHostNameFormatted}}</a>
{{#if host.criticalAlertsCount}}
<span class="label label-important alerts-count" {{action "showAlertsPopup" host target="controller"}}>{{host.criticalAlertsCount}}</span>
{{/if}}
</td>
<td>{{host.ip}}</td>
<td>{{host.cpu}}</td>
<td>{{host.memoryFormatted}}</td>
<td>
<div class="progress progress-info" title="{{unbound host.diskInfoBar}}">
<div class="bar" {{bindAttr style="view.usageStyle"}}></div>
</div>
</td>
<td>{{host.loadAvg}}</td>
<td>
<span title="{{unbound view.labels}}">{{view.shortLabels}}</span>
</td>
{{/view}}
{{/each}}
{{else}}
<tr>
<td class="first"></td>
<td colspan="7">
{{t hosts.table.noHosts}}
</td>
</tr>
{{/if}}
</tbody>
</table>
<div class="page-bar">
<div class="items-on-page">
<label>{{t common.show}}: {{view view.hostPerPageSelectView selectionBinding="view.displayLength"}}</label>
</div>
<div class="info">{{view.paginationInfo}}</div>
<div class="paging_two_button">
{{view view.paginationLeft}}
{{view view.paginationRight}}
</div>
</div>
</div>