blob: 2ae664e630ed9aca4deae2177bb316f24c5ce5e1 [file] [log] [blame]
<!-- /********************************************************************************
* Copyright (c) 2020 Contributors to the Eclipse Foundation
*
* See the NOTICE file(s) distributed with this work for additional
* information regarding copyright ownership.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v. 2.0 which is available at
* http://www.eclipse.org/legal/epl-2.0.
*
* SPDX-License-Identifier: EPL-2.0
********************************************************************************/ -->
<app-card-layout>
<div header>
<span>{{ 'AddressTypes.Title' | translate }}</span>
<div class="pull-right">
<button class="btn btn-primary new-button" (click)="sandbox.setDisplayForm()">
{{ 'NewBtn' | translate }}
</button>
</div>
</div>
<div class="address-types-grid-wrapper" body>
<ag-grid-angular
autoresizecolumns
class="ag-theme-balham"
[ngClass]="sandbox.displayForm ? 'ag-grid-height-edit' : 'ag-grid-height-list'"
[class.ag-grid-height-list]="!sandbox.displayForm"
[gridOptions]="gridOptions"
[columnDefs]="columnDefinition"
[rowSelection]="'single'"
[frameworkComponents]="frameworkComponents"
[rowData]="sandbox.addressTypes$ | async"
>
</ag-grid-angular>
<div *ngIf="sandbox.displayForm" class="address-types-details">
<app-address-types-details></app-address-types-details>
</div>
</div>
</app-card-layout>