compass-web/v2/src/app/wizard/server_selection.tpl.html

112 lines
5.5 KiB
HTML

<div ng-controller="svSelectCtrl">
<div class="row">
<div collapse="findNewServersPanel.isCollapsed">
<div class="dashed-panel">
<span class="action pull-right" ng-click="findNewServersPanel.isCollapsed = true;">
<i class="ace-icon fa fa-times-circle bigger-120 light-grey"></i>
</span>
<div class="clearfix"></div>
<findservers results="foundResults"></findservers>
</div>
</div>
</div>
<div class="row">
<div class="pull-left">
<!--Search Input-->
<span class="input-icon">
<input type="text" placeholder="Search" ng-model="search.$">
<i class="ace-icon fa fa-search blue"></i>
</span>
<!-- Column Show / Hide button -->
<div class="btn-group" dropdown>
<button type="button" class="btn btn-default dropdown-toggle">
Column Show / Hide
<span class="ace-icon fa fa-caret-down icon-on-right"></span>
</button>
<ul class="dropdown-menu" role="menu">
<li ng-repeat="column in server_columns" ng-click="column.visible=!column.visible">
<a class="action">
<span ng-class="{'opacity-zero': !column.visible}">
<i class="ace-icon fa fa-check blue"></i>
</span>
{{column.title}}
</a>
</li>
</ul>
</div>
</div>
<div class="pull-right">
<button class="btn btn-info" ng-click="findNewServersPanel.isCollapsed = !findNewServersPanel.isCollapsed" ng-init="findNewServersPanel.isCollapsed = true;">
Discover Servers&nbsp;&nbsp;
<i class="ace-icon fa fa-plus" ng-class="{'fa-minus': !findNewServersPanel.isCollapsed}"></i>
</button>
</div>
<div class="pull-right side-padding-20">
<div class="checkbox">
<label>
<input ng-model="hideunselected" ng-change="hideUnselected()" type="checkbox" class="ace">
<span class="lbl">&nbsp;Hide Unselected Servers</span>
</label>
</div>
</div>
</div>
<div class="row">
<div class="space-6"></div>
<div class="table-responsive">
<table ng-table="tableParams" class="table table-hover table-striped">
<thead>
<tr>
<th>
<label>
<input ng-model="selectall" ng-change="selectAllServers(selectall)" type="checkbox" class="ace">
<span class="lbl"></span>
</label>
</th>
<th ng-repeat="column in server_columns" ng-show="column.visible" class="sortable" ng-class="{'sort-asc': tableParams.isSortBy(column.field, 'asc'),
'sort-desc': tableParams.isSortBy(column.field, 'desc')}" ng-click="tableParams.sorting(column.field, tableParams.isSortBy(column.field, 'asc') ? 'desc' : 'asc')">
<div>{{column.title}}</div>
</th>
</tr>
</thead>
<tbody>
<tr ng-show="$data.length==0">
<td colspan="9" class="center">No servers yet. Please click Discover Servers to discover available servers.</td>
</tr>
<tr ng-repeat="server in $data | filter:search" ng-class="{'success': server.new, 'hightlight': server.selected, 'grey': server.disabled}">
<td>
<label ng-init="ifPreSelect(server)">
<input ng-model="server.selected" type="checkbox" class="ace" ng-disabled="server.disabled">
<span class="lbl"></span>
</label>
</td>
<td ng-repeat="column in server_columns" ng-show="column.visible" sortable="column.field">
<span ng-switch on="column.field">
<span ng-switch-when="os_installed">
<span ng-if="server['os_name']">
<label>
<input ng-model="server.reinstallos" type="checkbox" class="ace">
<span class="lbl"></span>
</label>
</span>
<span ng-if="!server['os_name']">
-
</span>
</span>
<span ng-switch-when="clusters">
<span ng-repeat="cluster in server.clusters">
{{cluster.name}}&nbsp;
</span>
</span>
<span ng-switch-default>
{{server[column.field]}}
</span>
</span>
</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>