]>
Commit | Line | Data |
---|---|---|
92f5a8d4 | 1 | <cd-modal [modalRef]="modalRef"> |
11fdf7f2 TL |
2 | <ng-container class="modal-title" |
3 | i18n>{mode, select, edit {Edit} other {Add}} | |
4 | pool mirror peer</ng-container> | |
5 | ||
6 | <ng-container class="modal-content"> | |
7 | <form name="editPeerForm" | |
8 | class="form" | |
9 | #formDir="ngForm" | |
10 | [formGroup]="editPeerForm" | |
11 | novalidate> | |
12 | <div class="modal-body"> | |
13 | <p> | |
14 | <ng-container i18n>{mode, select, edit {Edit} other {Add}} the pool | |
15 | mirror peer attributes for pool <kbd>{{ poolName }}</kbd> and click | |
16 | <kbd>Submit</kbd>.</ng-container> | |
17 | </p> | |
18 | ||
19 | <div class="form-group" | |
20 | [ngClass]="{'has-error': editPeerForm.showError('clusterName', formDir)}"> | |
21 | <label class="control-label" | |
22 | for="clusterName"> | |
23 | <span i18n>Cluster Name</span> | |
24 | <span class="required"></span> | |
25 | </label> | |
26 | <input class="form-control" | |
27 | type="text" | |
28 | placeholder="Name..." | |
29 | i18n-placeholder | |
30 | id="clusterName" | |
31 | name="clusterName" | |
32 | formControlName="clusterName" | |
33 | autofocus> | |
34 | <span class="help-block" | |
35 | *ngIf="editPeerForm.showError('clusterName', formDir, 'required')" | |
36 | i18n>This field is required.</span> | |
37 | <span class="help-block" | |
38 | *ngIf="editPeerForm.showError('clusterName', formDir, 'invalidClusterName')" | |
39 | i18n>The cluster name is not valid.</span> | |
40 | </div> | |
41 | ||
42 | <div class="form-group" | |
43 | [ngClass]="{'has-error': editPeerForm.showError('clientID', formDir)}"> | |
44 | <label class="control-label" | |
45 | for="clientID"> | |
46 | <span i18n>CephX ID</span> | |
47 | <span class="required"></span> | |
48 | </label> | |
49 | <input class="form-control" | |
50 | type="text" | |
51 | placeholder="CephX ID..." | |
52 | i18n-placeholder | |
53 | id="clientID" | |
54 | name="clientID" | |
55 | formControlName="clientID"> | |
56 | <span class="help-block" | |
57 | *ngIf="editPeerForm.showError('clientID', formDir, 'required')" | |
58 | i18n>This field is required.</span> | |
59 | <span class="help-block" | |
60 | *ngIf="editPeerForm.showError('clientID', formDir, 'invalidClientID')" | |
61 | i18n>The CephX ID is not valid.</span> | |
62 | </div> | |
63 | ||
64 | <div class="form-group" | |
65 | [ngClass]="{'has-error': editPeerForm.showError('monAddr', formDir)}"> | |
66 | <label class="control-label" | |
67 | for="monAddr"> | |
68 | <span i18n>Monitor Addresses</span> | |
69 | </label> | |
70 | <input class="form-control" | |
71 | type="text" | |
72 | placeholder="Comma-delimited addresses..." | |
73 | i18n-placeholder | |
74 | id="monAddr" | |
75 | name="monAddr" | |
76 | formControlName="monAddr"> | |
77 | <span class="help-block" | |
78 | *ngIf="editPeerForm.showError('monAddr', formDir, 'invalidMonAddr')" | |
79 | i18n>The monitory address is not valid.</span> | |
80 | </div> | |
81 | ||
82 | <div class="form-group" | |
83 | [ngClass]="{'has-error': editPeerForm.showError('key', formDir)}"> | |
84 | <label class="control-label" | |
85 | for="key"> | |
86 | <span i18n>CephX Key</span> | |
87 | </label> | |
88 | <input class="form-control" | |
89 | type="text" | |
90 | placeholder="Base64-encoded key..." | |
91 | i18n-placeholder | |
92 | id="key" | |
93 | name="key" | |
94 | formControlName="key"> | |
95 | <span class="help-block" | |
96 | *ngIf="editPeerForm.showError('key', formDir, 'invalidKey')" | |
97 | i18n>CephX key must be base64 encoded.</span> | |
98 | </div> | |
99 | ||
100 | </div> | |
101 | ||
102 | <div class="modal-footer"> | |
103 | <div class="button-group text-right"> | |
104 | <cd-submit-button i18n | |
105 | [form]="editPeerForm" | |
106 | (submitAction)="update()">Submit</cd-submit-button> | |
107 | <cd-back-button [back]="modalRef.hide" | |
108 | name="Cancel" | |
109 | i18n-name> | |
110 | </cd-back-button> | |
111 | </div> | |
112 | </div> | |
113 | </form> | |
114 | </ng-container> | |
115 | </cd-modal> |