Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,6 @@ export class AlertActionSelectComponent implements OnInit, OnDestroy {
const alert = this.alert;
this.changing = true;
if (status === AlertStatusEnum.COMPLETED || status === AlertStatusEnum.COMPLETED_AS_FALSE_POSITIVE) {
console.log('status', status);
const modalRef = this.modalService.open(AlertCompleteComponent, {centered: true});
modalRef.componentInstance.alertsIDs = [alert.id];
modalRef.componentInstance.canCreateRule = true;
Expand All @@ -184,6 +183,7 @@ export class AlertActionSelectComponent implements OnInit, OnDestroy {
this.syncIncidentAlertStatus([this.alert.id], status);
} else {
this.changing = false;
this.utmToastService.showError('Error', 'An error occurred while changing the alert status. Please try again later.');
}
});
} else {
Expand All @@ -192,6 +192,9 @@ export class AlertActionSelectComponent implements OnInit, OnDestroy {
this.changing = false;
this.alertUpdateHistoryBehavior.$refreshHistory.next(true);
this.syncIncidentAlertStatus([this.alert.id], status);
}, () => {
this.changing = false;
this.utmToastService.showError('Error', 'An error occurred while changing the alert status. Please try again later.');
});
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,10 @@ export class AlertCompleteComponent implements OnInit {
this.statusChange.emit('success');
this.activeModal.close();
this.creating = false;
});
},_err=>{
this.creating = false;
this.statusChange.emit('failed');
});
}

createRule() {
Expand Down
Loading