|
116 | 116 | class="w-30" |
117 | 117 | [loadingText]="'Loading alert fields...'" |
118 | 118 | [loading]="!alertFields" |
| 119 | + [disabled]="i === 0" |
119 | 120 | bindLabel="label" |
120 | 121 | bindValue="field" |
121 | 122 | formControlName="field" |
|
139 | 140 | formControlName="value" |
140 | 141 | id="values"> |
141 | 142 | </ng-select> |
142 | | - <i class="icon-cross2 cursor-pointer ml-3" ngbTooltip="Delete condition" |
| 143 | + <i *ngIf="i > 0" class="icon-cross2 cursor-pointer ml-3" ngbTooltip="Delete condition" |
143 | 144 | placement="left" |
144 | 145 | (click)="removeRuleCondition(i)"></i> |
| 146 | + <i *ngIf="i === 0" class="icon-lock2 ml-3 text-muted" ngbTooltip="Alert name is required"></i> |
145 | 147 | </div> |
146 | 148 | <div class="d-flex justify-content-between pr-4"> |
147 | 149 | <div> |
148 | | - <span *ngIf="ruleConditions.length === 0 || !ruleConditions.valid" |
| 150 | + <span *ngIf="!ruleConditions.valid" |
149 | 151 | class="text-danger-300 font-size-base"> |
150 | | - You must set at least one trigger condition |
| 152 | + You must select an alert name and complete all trigger conditions |
151 | 153 | </span> |
152 | 154 | </div> |
153 | 155 | <button class="btn utm-button btn-success align-self-end" (click)="addRuleCondition()"> |
|
175 | 177 | <div class="d-flex mt-3 flex-column"> |
176 | 178 | <div class="alert alert-info alert-styled-right mb-2 info-dismissible"> |
177 | 179 | <span class="font-weight-semibold">Info! </span> |
178 | | - <span>Select the agent handling strategy for the automation. If <strong>not active</strong>, commands will run on specified platform agents if the trigger conditions and dataSource field value of the alert match. Alternatively, choose a <strong>default agent</strong> to run the automation if no other agent matches the criteria. If this option is <strong>active</strong>, commands will run only on specified platform agents if the trigger conditions and dataSource field value of the alert match, if not, the <strong>automation won't be executed</strong>.</span> |
| 180 | + <span>Select the agent handling strategy for the automation. If <strong>not active</strong>, commands will run on specified platform agents if the trigger conditions and dataSource field value of the alert match. Alternatively, choose a <strong>dedicated agent</strong> to run the automation if no other agent matches the criteria. If this option is <strong>active</strong>, commands will run only on specified platform agents if the trigger conditions and dataSource field value of the alert match, if not, the <strong>automation won't be executed</strong>.</span> |
179 | 181 | </div> |
180 | 182 | <app-utm-toggle (toggleChange)="onChangeToggle($event)" |
181 | 183 | [active]="formRule.get('agentType').value" |
|
208 | 210 | </div> |
209 | 211 | <div *ngIf="formRule.get('agentType').value" class="d-flex mt-2 flex-column"> |
210 | 212 | <div class="col-6 p-0"> |
211 | | - <label class="pb-1" for="exclude">Default agent</label> |
| 213 | + <label class="pb-1" for="exclude">Dedicated agent</label> |
212 | 214 | <ng-select [clearable]="false" |
213 | 215 | [items]="agents" |
214 | 216 | [placeholder]="'Select agent'" |
|
235 | 237 | </div> |
236 | 238 | </div> |
237 | 239 | <div *ngIf="step===3" class="configure-step mt-3 mb-3"> |
| 240 | + <div *ngIf="isWindows()" class="form-group mb-3"> |
| 241 | + <label class="pb-1">Shell</label> |
| 242 | + <select formControlName="shell" class="form-control w-25"> |
| 243 | + <option value="cmd">cmd</option> |
| 244 | + <option value="powershell">powershell</option> |
| 245 | + </select> |
| 246 | + </div> |
238 | 247 | <span class="font-size-lg mb-2"> <i |
239 | 248 | class="icon-keyboard"></i> Press <b>TAB</b> to use alert fields in the command</span> |
240 | 249 | <div class="window"> |
|
0 commit comments