AngularJs-无法单击对话框内的按钮(对话框打开时禁用)



我使用了ngDialog,angularJs插件,来自:http://ngmodules.org/modules/ngDialog单击openDialog按钮时,对话框将打开,但已禁用。我无法与对话框交互。

HTML文件:

<body ng-app="managePartners">
<div ng-controller="managePartnerController">
<button ng-click="openTheDialog()">Open Dialog</button>
</div>
</body>

myScript.js文件:

    var app = angular.module("managePartners",['ngDialog']);
    app.controller("managePartnerController", function($scope , ngDialog){
      $scope.openTheDialog = function(){
      var dialog = ngDialog.open({
                template: '<p>Are you sure you want to close the parent dialog?</p>' +
                                '<div class="ngdialog-buttons">' +
                                    '<button type="button" class="ngdialog-button ngdialog-button-secondary" ng-click="closeThisDialog(0)">No' +
                                    '<button type="button" class="ngdialog-button ngdialog-button-primary" ng-click="confirm(1)">Yes' +
                                '</button></div>',
                plain: true,
                closeByDocument: false,
                closeByEscape: true,
                showClose:false,
                scope:$scope,
            });
  };
});

导入插件的所有Css文件使其工作!

最新更新