information-system-gui/src/main/webapp/app/home/home.component.html

88 lines
4.1 KiB
HTML

<div class="row" id="generalContainer">
<div [ngSwitch]="account !== null">
<div *ngSwitchCase="true">
<div *ngIf="isLoading" class="loader-container">
<mat-spinner mode="indeterminate" style="top: 50%; left: 50%;"></mat-spinner>
</div>
<div class="d-flex flex-row py-4"> <!-- top row with buttons and select-->
<div id="btn-group" class="col-md-3 py-3">
<button mat-raised-button color="primary"><mat-icon>source</mat-icon> <span>File</span></button>
<button mat-raised-button color="primary"><mat-icon>edit</mat-icon> <span>Edit</span></button>
<button mat-raised-button color="primary"><mat-icon>explore</mat-icon> <span>View</span></button>
<button mat-raised-button color="primary"><mat-icon>help</mat-icon><span>Help</span></button>
</div>
<div id="context-block" class="col-md-9 px-4">
<div ngbDropdown #myDrop="ngbDropdown"></div>
<form [formGroup]="chooseContextForm">
<div >
<mat-form-field id="pathfield" [style.width.px]="200" class="form-field">
<mat-select [(value)]="selected" placeholder="Contexts" formControlName="pathfield" (valueChange)="setNewContext($event)">
<mat-select-filter [placeholder]="'filter by name'" [displayMember]="'path'" [array]="allCtxs" (filteredReturn)="filteredContexts =$event"></mat-select-filter>
<mat-option *ngFor="let item of filteredContexts" [value]="item">
{{item.path}}
</mat-option>
</mat-select>
</mat-form-field>
<button mat-button (click)="copyPath(pathfield)" color="primary" matTooltip="copy path" matTooltipPosition="below">
<mat-icon class="icon-wide2">content_copy</mat-icon>
</button>
<mat-form-field id="namefield" [style.width.px]=300 appearance="outline" class="form-field">
<mat-label for="namefield">Context Name</mat-label>
<input matInput type="text" placeholder="Name"
formControlName="namefield" readonly [value]="pathfield.value.name" />
</mat-form-field>
<mat-form-field id="uidfield" [style.width.px]=350 appearance="outline" class="form-field">
<mat-label for="uidfield">Context UUID</mat-label>
<input matInput type="text" placeholder="UUID"
formControlName="uidfield" readonly [value]="pathfield.value.id" />
</mat-form-field>
<button mat-button (click)="copyUid(pathfield)" color="primary" matTooltip="copy UUID" matTooltipPosition="below">
<mat-icon class="icon-wide2">content_copy</mat-icon>
</button>
<button mat-button color="primary" matTooltip="locate" matTooltipPosition="below">
<mat-icon class="icon-wide2">location_searching</mat-icon>
</button>
</div>
</form>
</div>
</div>
<div class="d-flex flex-row gap-2">
<div id="restree" class="col-md-3 ps-3 pt-3 border rounded" >
<h4>Resource Types</h4>
<div id="tree-view">
<jhi-rsc-tree id="leftTree" (typeObjectEm)="buildTableData($event)"></jhi-rsc-tree>
</div>
</div>
<div class="col-md-9 border rounded">
<jhi-type-headline [typeObject]="resType" [currentCtx]="myContext"></jhi-type-headline>
<div [ngSwitch]="resType.name" >
<div *ngSwitchCase = "'HostingNode'">
<jhi-table-screen [typeObject]="resType" [currentCtx]="myContext"></jhi-table-screen>
</div>
<div *ngSwitchCase = "'VirtualMachine'">
<jhi-table-screen [typeObject]="resType" [currentCtx]="myContext"></jhi-table-screen>
</div>
<div *ngSwitchCase = "'EService'">
<jhi-table-screen-es [typeObject]="resType" [currentCtx]="myContext"></jhi-table-screen-es>
</div>
<div *ngSwitchCase = "'VirtualService'">
<jhi-table-screen-vs [typeObject]="resType" [currentCtx]="myContext"></jhi-table-screen-vs>
</div>
<div *ngSwitchDefault class="mx-4">At the moment there are no objects of this type.</div>
</div>
</div>
</div>
</div><!-- end successful login -->
<div class="alert alert-warning" *ngSwitchCase="false">
<h3>Please sign in! </h3>
</div>
</div><!-- end ngSwitch-account -->
</div><!-- end generalContainer -->