]>
Commit | Line | Data |
---|---|---|
f67539c2 TL |
1 | <div class="cd-col-form" |
2 | *cdFormLoading="loading"> | |
9f95a23c | 3 | <form name="hostForm" |
9f95a23c TL |
4 | #formDir="ngForm" |
5 | [formGroup]="hostForm" | |
6 | novalidate> | |
7 | <div class="card"> | |
8 | <div i18n="form title|Example: Create Pool@@formTitle" | |
9 | class="card-header">{{ action | titlecase }} {{ resource | upperFirst }}</div> | |
10 | ||
11 | <div class="card-body"> | |
12 | ||
13 | <!-- Hostname --> | |
14 | <div class="form-group row"> | |
15 | <label class="cd-col-form-label required" | |
16 | for="hostname" | |
17 | i18n>Hostname</label> | |
18 | <div class="cd-col-form-input"> | |
19 | <input class="form-control" | |
20 | type="text" | |
21 | placeholder="mon-123" | |
22 | id="hostname" | |
23 | name="hostname" | |
24 | formControlName="hostname" | |
25 | autofocus> | |
26 | <span class="invalid-feedback" | |
27 | *ngIf="hostForm.showError('hostname', formDir, 'required')" | |
28 | i18n>This field is required.</span> | |
29 | <span class="invalid-feedback" | |
30 | *ngIf="hostForm.showError('hostname', formDir, 'uniqueName')" | |
31 | i18n>The chosen hostname is already in use.</span> | |
32 | </div> | |
33 | </div> | |
34 | </div> | |
35 | ||
36 | <div class="card-footer"> | |
f67539c2 TL |
37 | <cd-form-button-panel (submitActionEvent)="submit()" |
38 | [form]="hostForm" | |
39 | [submitText]="(action | titlecase) + ' ' + (resource | upperFirst)" | |
40 | wrappingClass="text-right"></cd-form-button-panel> | |
9f95a23c TL |
41 | </div> |
42 | </div> | |
43 | </form> | |
44 | </div> |