javascript - Bootstrap modal with AngularJS -


i want output message when click button. wants saved. how create modal.

<input type="submit"         class="btn btn-primary"         value="remove verify"         ng-show="isverifypage"         ng-click="save()"> 

js file

$scope.save = function() {    //connect backend }).success(function(data, status) {      alert('successfully saved');   })   .error(function(error) {      console.log($scope.status);   }); } 

my must inject controller sweetalert. , when want make alert use in example.

nameyoucontroller.$inject = ['$scope','sweetalert'];     function nameyoucontroller( $scope, sweetalert) {         $scope.save = function() {            //connect backend         }).success(function(data, status) {           return sweetalert.swal('successfully saved');         }).error(function(error) {           console.log($scope.status);       });     } 

Comments

Popular posts from this blog

commonjs - How to write a typescript definition file for a node module that exports a function? -

openid - Okta: Failed to get authorization code through API call -

ios - Change Storyboard View using Seague -