]> git.apps.os.sepia.ceph.com Git - ceph.git/blob
7753d599bb6e0977ae2a9437402d8abfe6faaa8e
[ceph.git] /
1 <div class="row">
2   <div class="col-sm-4 pr-0">
3     <div class="card">
4       <div class="card-header">
5         <button type="button"
6                 [class.disabled]="loadingIndicator"
7                 class="btn btn-light pull-right"
8                 (click)="refreshAllDirectories()">
9           <i [ngClass]="[icons.large, icons.refresh]"
10              [class.fa-spin]="loadingIndicator"></i>
11         </button>
12       </div>
13       <div class="card-body">
14         <!--
15           ng2-tree can't be used here as it cannot handle the reloading of all nodes
16           without loosing all states of the current tree. The difference of both tree components is
17           that ng2-tree is defined and configured by each node where as angular-tree
18           is configured by a tree structure and consist of nodes that mainly hold data.
19           Angular-tree is a lot better for dynamically loaded trees. The downside is that it's not
20           possible to set individual icons for each node.
21         -->
22         <tree-root *ngIf="nodes"
23                    [nodes]="nodes"
24                    [options]="treeOptions">
25           <ng-template #loadingTemplate>
26             <i [ngClass]="[icons.spinner, icons.spin]"></i>
27           </ng-template>
28         </tree-root>
29       </div>
30     </div>
31   </div>
32   <!-- Selection details -->
33   <div class="col-sm-8 metadata"
34        *ngIf="selectedDir">
35     <div class="card">
36       <div class="card-header">
37         {{ selectedDir.path }}
38       </div>
39       <div class="card-body">
40         <ng-container *ngIf="selectedDir.path !== '/'">
41           <legend i18n>Quotas</legend>
42           <cd-table [data]="settings"
43                     [columns]="quota.columns"
44                     [limit]="0"
45                     [footer]="false"
46                     selectionType="single"
47                     (updateSelection)="quota.updateSelection($event)"
48                     [onlyActionHeader]="true"
49                     identifier="quotaKey"
50                     [forceIdentifier]="true"
51                     [toolHeader]="false">
52             <cd-table-actions class="only-table-actions"
53                               [permission]="permission"
54                               [selection]="quota.selection"
55                               [tableActions]="quota.tableActions">
56             </cd-table-actions>
57           </cd-table>
58         </ng-container>
59
60         <legend i18n>Snapshots</legend>
61         <cd-table [data]="selectedDir.snapshots"
62                   [columns]="snapshot.columns"
63                   identifier="name"
64                   forceIdentifier="true"
65                   selectionType="multiClick"
66                   (updateSelection)="snapshot.updateSelection($event)">
67           <cd-table-actions class="table-actions"
68                             [permission]="permission"
69                             [selection]="snapshot.selection"
70                             [tableActions]="snapshot.tableActions">
71           </cd-table-actions>
72         </cd-table>
73       </div>
74     </div>
75   </div>
76 </div>
77
78 <ng-template #origin
79              let-row="row"
80              let-value="value">
81   <span class="quota-origin"
82         (click)="selectOrigin(value)">{{value}}</span>
83 </ng-template>