Skip to content

Commit

Permalink
Merge pull request #9 from StatCan/fix-angular-component
Browse files Browse the repository at this point in the history
Fix angular component
  • Loading branch information
Wendy Gaultier authored Aug 21, 2020
2 parents 7ad65c2 + 20ff2f9 commit f0b855d
Showing 1 changed file with 12 additions and 4 deletions.
16 changes: 12 additions & 4 deletions frontend/src/app/resource-form/volume/volume.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,18 @@
<!-- Volume Name Input -->
<mat-form-field appearance="outline" id="name">
<mat-label>Name</mat-label>
<input matInput formControlName="name" *ngIf="volume.value.type == 'New'" />
<mat-select formControlName="name" *ngIf="volume.value.type == 'Existing'">
<mat-option *ngFor="let pvc of existingPVCs" [value]="pvc">{{ pvc }}</mat-option>
</mat-select>
<input
matInput
formControlName="name"
*ngIf="volume.value.type == 'New'; else existingPvcControl"
/>
<ng-template #existingPvcControl>
<mat-select formControlName="name">
<mat-option *ngFor="let pvc of existingPVCs" [value]="pvc">{{
pvc
}}</mat-option>
</mat-select>
</ng-template>
</mat-form-field>

<!-- Size Input -->
Expand Down

0 comments on commit f0b855d

Please sign in to comment.