diff --git a/src/dialog/dialog.js b/src/dialog/dialog.js index 67a192b2ce..92ef40730b 100644 --- a/src/dialog/dialog.js +++ b/src/dialog/dialog.js @@ -123,7 +123,7 @@ dialogModule.provider("$dialog", function(){ if (self.options.controller) { var ctrl = $controller(self.options.controller, locals); - self.modalEl.contents().data('ngControllerController', ctrl); + self.modalEl.children().data('ngControllerController', ctrl); } $compile(self.modalEl)($scope); diff --git a/src/dialog/test/dialog.spec.js b/src/dialog/test/dialog.spec.js index 8cbdcbf618..79d368462c 100644 --- a/src/dialog/test/dialog.spec.js +++ b/src/dialog/test/dialog.spec.js @@ -1,7 +1,7 @@ describe('Given ui.bootstrap.dialog', function(){ var $document, $compile, $scope, $rootScope, $dialog, q, provider; - var template = '