angularjs - Modal background mask does not appear when i open the modal for the second time -
i using angular bootstrap modal.the modal has angular data table in modal body , close button in modal footer.the issue facing once click on close button,the modal disappear screen remains grayed out , inaccessible.so,i included below code.
$('#modal-id').modal('hide'); $('body').removeclass('modal-open'); $('.modal-backdrop').remove();
after adding this,the modal , background works fine when open , close first time when open modal next time,the gray background not appear. insight appreciated.
my controller :
$scope.modalpop = function(){ $scope.modaloverlay = $modal.open({ templateurl: 'url', scope: $scope, animation: false, windowclass: 'overlay-lg' }); }; $scope.modalclose = function() { $scope.modaloverlay .close(); $('#modal-id').modal('hide'); $('body').removeclass('modal-open'); $('.modal-backdrop').remove(); }
where modalclose function on ng-click close button in modal footer.
Comments
Post a Comment