Skip to content

Commit 434ef57

Browse files
authored
Fix success modal for reset grouping (#807)
Add debug message to catches Fix codacy Remove $log messages
1 parent 42efe7d commit 434ef57

File tree

2 files changed

+11
-6
lines changed

2 files changed

+11
-6
lines changed

src/main/resources/static/javascript/mainApp/general.controller.js

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818
$scope.invalidMembers = [];
1919
$scope.membersInList = "";
2020
$scope.isMultiAdd = false;
21-
2221
// Remove members
2322
$scope.multiRemoveResults = [];
2423
$scope.membersToRemove = [];
@@ -913,7 +912,7 @@
913912
$scope.getGroupingInformation();
914913
$scope.syncDestArray = [];
915914
}
916-
});
915+
}).catch(() => {});
917916
}
918917

919918
/**
@@ -1328,7 +1327,7 @@
13281327
$scope.loading = true;
13291328
clearMemberInput($scope.listName);
13301329
$scope.getGroupingInformation();
1331-
});
1330+
}).catch(() => {});
13321331
}
13331332

13341333
/**
@@ -1524,6 +1523,7 @@
15241523
}
15251524
}
15261525
}
1526+
15271527
// Otherwise, display the result success modal.
15281528
$scope.displaySuccessfulGroupResetModal((() => {
15291529
if (results.includeSuccess && results.excludeSuccess) {
@@ -1553,9 +1553,14 @@
15531553
$scope.successfulGroupResetModalInstance = $uibModal.open({
15541554
templateUrl: "modal/successfulGroupResetModal",
15551555
scope: $scope,
1556-
backdrop: "static",
1557-
keyboard: false
1556+
backdrop: true,
1557+
keyboard: true
15581558
});
1559+
1560+
$scope.successfulGroupResetModalInstance.result.finally(() => {
1561+
$scope.loading = true;
1562+
$scope.getGroupingInformation();
1563+
}).catch(() => {});
15591564
};
15601565

15611566
/**

src/main/resources/templates/modal/successfulGroupResetModal.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<html xmlns:th="http://www.thymeleaf.org" lang="en">
22
<div class="modal-header">
33
<h5 class="modal-title" id="modal-title">Grouping Reset Completion</h5>
4-
<a class="close" type="button" ng-click="closeResetNotifModal()">
4+
<a class="close" type="button" ng-click="closeSuccessfulGroupResetModal()">
55
<span aria-hidden="true">&times;</span>
66
</a>
77
</div>

0 commit comments

Comments
 (0)