Merge "Apply mat-table to control and catalog"
[portal/ric-dashboard.git] / webapp-frontend / src / app / catalog / catalog.component.html
1 <!--
2   ========================LICENSE_START=================================
3   O-RAN-SC
4   %%
5   Copyright (C) 2019 AT&T Intellectual Property and Nokia
6   %%
7   Licensed under the Apache License, Version 2.0 (the "License");
8   you may not use this file except in compliance with the License.
9   You may obtain a copy of the License at
10
11        http://www.apache.org/licenses/LICENSE-2.0
12
13   Unless required by applicable law or agreed to in writing, software
14   distributed under the License is distributed on an "AS IS" BASIS,
15   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16   See the License for the specific language governing permissions and
17   limitations under the License.
18   ========================LICENSE_END===================================
19   -->
20 <div class="catalog__section">
21   <h3 class="catalog__header">xApp Catalog</h3>
22   <div class="spinner-container" *ngIf="dataSource.loading$ | async">
23     <mat-spinner></mat-spinner>
24   </div>
25   <table mat-table [dataSource]="dataSource" class="catalog-table mat-elevation-z8">
26
27     <ng-container matColumnDef="name">
28       <mat-header-cell *matHeaderCellDef> xApp Name </mat-header-cell>
29       <mat-cell *matCellDef="let element"> {{element.name}} </mat-cell>
30     </ng-container>
31
32     <ng-container matColumnDef="version">
33       <mat-header-cell *matHeaderCellDef> xApp version </mat-header-cell>
34       <mat-cell *matCellDef="let element"> {{element.version}} </mat-cell>
35     </ng-container>
36
37     <ng-container matColumnDef="status">
38       <mat-header-cell *matHeaderCellDef> Status </mat-header-cell>
39       <mat-cell *matCellDef="let element"> {{element.status}} </mat-cell>
40     </ng-container>
41
42     <ng-container matColumnDef="action">
43       <mat-header-cell *matHeaderCellDef> Action </mat-header-cell>
44       <mat-cell *matCellDef="let element">
45         <div class="catalog-button-row">
46           <button mat-icon-button
47                   (click)="onConfigurexApp(element.name)">
48             <mat-icon>settings</mat-icon>
49           </button>
50           <button mat-button class="mat-raised-button mat-primary"
51                   (click)="onDeployxApp(element.name)">
52             Deploy
53           </button>
54         </div>
55       </mat-cell>
56     </ng-container>
57
58     <mat-header-row *matHeaderRowDef="displayedColumns"></mat-header-row>
59     <mat-row *matRowDef="let row; columns: displayedColumns;"></mat-row>
60   </table>
61 </div>