]> git.apps.os.sepia.ceph.com Git - ceph.git/blob
06d913bc3c64b91a8c373be96d33d029e22235a0
[ceph.git] /
1 <cd-modal>
2   <ng-container i18n
3                 class="modal-title">Move an image to trash</ng-container>
4
5   <ng-container class="modal-content">
6     <form name="moveForm"
7           class="form"
8           #formDir="ngForm"
9           [formGroup]="moveForm"
10           novalidate>
11       <div class="modal-body">
12         <p i18n>To move <kbd>{{ imageSpec }}</kbd> to trash,
13           click <kbd>Move Image</kbd>. Optionally, you can pick an expiration date.</p>
14
15         <div class="form-group">
16           <label class="col-form-label"
17                  for="expires"
18                  i18n>Protection expires at</label>
19           <input type="text"
20                  placeholder="NOT PROTECTED"
21                  i18n-placeholder
22                  class="form-control"
23                  [minDate]="minDate"
24                  [bsConfig]="bsConfig"
25                  formControlName="expiresAt"
26                  bsDatepicker>
27           <span class="invalid-feedback"
28                 *ngIf="moveForm.showError('expiresAt', formDir, 'format')"
29                 i18n>Wrong date format. Please use "YYYY-MM-DD HH:mm:ss".</span>
30           <span class="invalid-feedback"
31                 *ngIf="moveForm.showError('expiresAt', formDir, 'expired')"
32                 i18n>Protection has already expired. Please pick a future date or leave it empty.</span>
33         </div>
34       </div>
35
36       <div class="modal-footer">
37         <div class="button-group text-right">
38           <cd-submit-button i18n
39                             [form]="moveForm"
40                             (submitAction)="moveImage()">Move Image</cd-submit-button>
41           <cd-back-button [back]="modalRef.hide"
42                           name="Cancel"
43                           i18n-name>
44           </cd-back-button>
45         </div>
46       </div>
47     </form>
48   </ng-container>
49 </cd-modal>