Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add merge of additionalOptions object from the scope into modal instance options #58

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

add merge of additionalOptions object from the scope into modal instance options #58

wants to merge 1 commit into from

Conversation

ascalabro
Copy link

Enable the setting of additional options to the modal instance.
These options should be property additionalOptions, of the scope, which gets merged into the default modal options object in the directive.
Without a change like this one, it is not possible to set modal options other than the default from the directive..

@ascalabro
Copy link
Author

Set $scope.additionalOptions in the controller and these will become options for the modal

$scope.additionalOptions = {
        onShow: function() {
            console.log('scope options sent in scope.additionalOptions.onShow');
        },
        closable  : false,
        onDeny    : function(){
            console.log('Denied');
            return false;
        },
        onApprove : function() {
            alert('Approved!');
        }
    };

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant