Commit 47b6f01c by utkarshcmu

confirmation box added for user removal

parent 68225d64
......@@ -37,6 +37,18 @@ export class OrgUsersCtrl {
}
removeUser(user) {
this.$scope.appEvent('confirm-modal', {
title: 'Confirm delete user',
text: 'Are you sure you want to delete user ' + user.login + '?',
yesText: "Delete",
icon: "fa-warning",
onConfirm: () => {
this.removeUserConfirmed(user);
}
});
}
removeUserConfirmed(user) {
this.backendSrv.delete('/api/org/users/' + user.userId)
.then(() => {
this.get();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment