mirror of https://github.com/k3s-io/k3s
63 lines
2.5 KiB
Plaintext
63 lines
2.5 KiB
Plaintext
<!--
|
|
Copyright 2014 Google Inc. All rights reserved.
|
|
|
|
Licensed 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 style="margin-top: 10px">
|
|
<div class="k8s-title-font k8s-box">
|
|
{{ groupName }}
|
|
|
|
<div ng-if="group.kind != 'grouping'">
|
|
<div ng-if="!settings.display || settings.display=='box'">
|
|
<div class="content k8s-item k8s-inline" ng-repeat="item in group">
|
|
<div class="k8s-title-font k8s-font-regular">
|
|
<div ng-switch on='item.labels["type"]'>
|
|
<a ng-switch-when='pod' href="#/pods/{{ item.id }}">{{ item.id }}</a>
|
|
<a ng-switch-when='service' href="#/services/{{ item.id }}">{{ item.id }}</a>
|
|
<a ng-switch-when='replicationController' href="#/replicationControllers/{{ item.id }}">{{ item.id }}</a>
|
|
<span ng-switch-default>{{item.id}}</span>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div ng-if="settings.display=='list'">
|
|
<table style="width: 90%; padding: 10px">
|
|
<tr ng-repeat="item in group" ng-class-odd="'k8s-odd'" ng-class-even="'k8s-even'" valign="top">
|
|
<td class="k8s-cell">
|
|
<div ng-switch on='item.labels["type"]'>
|
|
<a ng-switch-when='pod' href="#/pods/{{ item.id }}">{{ item.id }}</a>
|
|
<a ng-switch-when='service' href="#/services/{{ item.id }}">{{ item.id }}</a>
|
|
<a ng-switch-when='replicationController' href="#/replicationControllers/{{ item.id }}">{{ item.id }}</a>
|
|
<span ng-switch-default>{{item.id}}</span>
|
|
</div>
|
|
</td>
|
|
<td class="k8s-cell">
|
|
<div ng-repeat='(key, value) in item.labels'>
|
|
<a href="#/groups/{{key}}/selector/{{controller.routeParams.selector}}">{{key}}</a> :
|
|
<a href="#/groups/{{controller.routeParams.grouping}}/selector/{{key}}={{value}}">{{value}}</a> </span>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
<div ng-if="group.kind == 'grouping'">
|
|
<div ng-repeat="(groupName,group) in group.items" ng-include="'box.ng'">
|
|
</div>
|
|
</div>
|
|
<div>
|
|
<a ng-click="settings={display:'box'}">box</a>
|
|
<a ng-click="settings={display:'list'}">list</a>
|
|
<a ng-click="controller.resetGroupLayout(this);">reset</a>
|
|
</div>
|
|
</div>
|