Skip to content

Commit

Permalink
fix(amazon/securityGroup): Resolve angular/react modal-body conflict (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
caseyhebebrand committed Jul 13, 2021
1 parent b4ad37a commit 5cd3743
Showing 1 changed file with 17 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -156,20 +156,24 @@ angular

this.editInboundRules = function editInboundRules() {
confirmNotManaged($scope.securityGroup, application).then((notManaged) => {
notManaged &&
$uibModal.open({
templateUrl: require('../configure/editSecurityGroup.html'),
controller: 'awsEditSecurityGroupCtrl as ctrl',
size: 'lg',
resolve: {
securityGroup: function () {
return angular.copy($scope.securityGroup);
},
application: function () {
return application;
// Wait for the MD confirmation modal to go away first to avoid react/angular bootstrap fighting over the body.modal-open class
return new Promise((resolve) => setTimeout(resolve, 500)).then(() => {
if (notManaged) {
$uibModal.open({
templateUrl: require('../configure/editSecurityGroup.html'),
controller: 'awsEditSecurityGroupCtrl as ctrl',
size: 'lg',
resolve: {
securityGroup: function () {
return angular.copy($scope.securityGroup);
},
application: function () {
return application;
},
},
},
});
});
}
});
});
};

Expand Down

0 comments on commit 5cd3743

Please sign in to comment.