Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
Hi,
I am opening a new dialog using the following code:
dialogService.open({ template: '/App_Plugins/uContentMap/views/dialogs/ucontentmap.node.delete.html', dialogData: nodeId });
This opens the dialog.
Inside the view I have a button called Close that needs to close the current dialog.
Close
But how do I close this dialog inside my controller located in the view?
View:
<div ng-controller="uContentMap.Nodes.DeleteController" ng-init="init(dialogData)" class="umb-modalcolumn ng-cloak"> <div class="umb-modalcolumn-header"> <h1>Delete</h1> </div> <div class="umb-modalcolumn-body"> <div class="umb-dialog umb-pane"> <div class="umb-dialog-body"> <p class="umb-abstract">Are you sure you want to delete <strong>{{vm.Content.Name}}</strong>?</p> <div class="umb-pane btn-toolbar umb-btn-toolbar"> <div class="control-group umb-control-group"> <a href ng-click="closeDialog()" class="btn btn-link">Cancel</a> <a href ng-click="deleteNode()" class="btn btn-primary">OK</a> </div> </div> </div> </div> </div> </div>
/Michaël
ok solved it by looking into the source code of Umbraco.
Just use the close() function instead of creating your own one.
close()
And to close it after submit just call $scope.submit() in your controller
$scope.submit()
is working on a reply...
Write your reply to:
Upload image
Image will be uploaded when post is submitted
Close dialog from another controller
Hi,
I am opening a new dialog using the following code:
This opens the dialog.
Inside the view I have a button called
Close
that needs to close the current dialog.But how do I close this dialog inside my controller located in the view?
View:
/Michaël
ok solved it by looking into the source code of Umbraco.
Just use the
close()
function instead of creating your own one./Michaël
And to close it after submit just call
$scope.submit()
in your controller/Michaël
is working on a reply...