]> git.proxmox.com Git - ceph.git/blob - ceph/src/pybind/mgr/dashboard/frontend/src/app/ceph/shared/feedback/feedback.component.html
72e2919814b2ac3412d25566748d8b5a12a88279
[ceph.git] / ceph / src / pybind / mgr / dashboard / frontend / src / app / ceph / shared / feedback / feedback.component.html
1 <cd-modal [modalRef]="activeModal">
2 <div class="modal-title"
3 i18n>Report an issue</div>
4
5 <div class="modal-content">
6 <form name="feedbackForm"
7 [formGroup]="feedbackForm"
8 #formDir="ngForm">
9 <div class="modal-body">
10 <cd-alert-panel *ngIf="!isFeedbackEnabled"
11 type="error"
12 i18n>Feedback module is not enabled. Please enable it from <a (click)="redirect()">Cluster-> Manager Modules.</a>
13 </cd-alert-panel>
14 <!-- api_key -->
15 <div class="form-group row"
16 *ngIf="!isAPIKeySet">
17 <label class="cd-col-form-label required"
18 for="api_key"
19 i18n>Ceph Tracker API Key</label>
20 <div class="cd-col-form-input">
21 <input id="api_key"
22 type="password"
23 formControlName="api_key"
24 class="form-control"
25 placeholder="Add Ceph tracker API key">
26 <span class="invalid-feedback"
27 *ngIf="feedbackForm.showError('api_key', formDir, 'required')"
28 i18n>Ceph Tracker API key is required.</span>
29 <span class="invalid-feedback"
30 *ngIf="feedbackForm.showError('api_key', formDir, 'invalidApiKey')"
31 i18n>Ceph Tracker API key is invalid.</span>
32 </div>
33 </div>
34
35 <!-- project -->
36 <div class="form-group row">
37 <label class="cd-col-form-label required"
38 for="project"
39 i18n>Project name</label>
40 <div class="cd-col-form-input">
41 <select class="form-control"
42 id="project"
43 formControlName="project">
44 <option ngValue=""
45 i18n>-- Select a project --</option>
46 <option *ngFor="let projectName of project"
47 [value]="projectName">{{ projectName }}</option>
48 </select>
49 <span class="invalid-feedback"
50 *ngIf="feedbackForm.showError('project', formDir, 'required')"
51 i18n>Project name is required.</span>
52 </div>
53 </div>
54
55 <!-- tracker -->
56 <div class="form-group row">
57 <label class="cd-col-form-label required"
58 for="tracker"
59 i18n>Tracker</label>
60 <div class="cd-col-form-input">
61 <select class="form-control"
62 id="tracker"
63 formControlName="tracker">
64 <option ngValue=""
65 i18n>-- Select a tracker --</option>
66 <option *ngFor="let trackerName of tracker"
67 [value]="trackerName">{{ trackerName }}</option>
68 </select>
69 <span class="invalid-feedback"
70 *ngIf="feedbackForm.showError('tracker', formDir, 'required')"
71 i18n>Tracker name is required.</span>
72 </div>
73 </div>
74
75 <!-- subject -->
76 <div class="form-group row">
77 <label class="cd-col-form-label required"
78 for="subject"
79 i18n>Subject</label>
80 <div class="cd-col-form-input">
81 <input id="subject"
82 type="text"
83 formControlName="subject"
84 class="form-control"
85 placeholder="Add issue title">
86 <span class="invalid-feedback"
87 *ngIf="feedbackForm.showError('subject', formDir, 'required')"
88 i18n>Subject is required.</span>
89 </div>
90 </div>
91
92 <!-- description -->
93 <div class="form-group row">
94 <label class="cd-col-form-label required"
95 for="description"
96 i18n>Description</label>
97 <div class="cd-col-form-input">
98 <textarea id="description"
99 type="text"
100 formControlName="description"
101 class="form-control"
102 placeholder="Add issue description">
103 </textarea>
104 <span class="invalid-feedback"
105 *ngIf="feedbackForm.showError('description', formDir, 'required')"
106 i18n>Description is required.</span>
107 </div>
108 </div>
109
110 </div>
111 <div class="modal-footer">
112 <cd-form-button-panel (submitActionEvent)="onSubmit()"
113 [form]="feedbackForm"
114 [submitText]="actionLabels.SUBMIT"
115 wrappingClass="text-right">
116 </cd-form-button-panel>
117 </div>
118 </form>
119 </div>
120 </cd-modal>