-
-
Notifications
You must be signed in to change notification settings - Fork 44
Description
The issues forum is NOT for support requests. It is for bugs and feature requests only.
Please read https://github.com/angular-ui/bootstrap/blob/master/CONTRIBUTING.md and search
existing issues (both open and closed) prior to opening any new issue and ensure you follow the instructions therein.
Bug description:
I uiboostrap for bs 3 if you created a modal and didn't pass it a new controller, it would use the controller for the page you were on. I believe you could also pass in the controller and controllerAs for the current controller, into your modal, and it would use the current object.
This version always creates a new controller object. There is no way to pass in anything remotely useful for the johnpapa standard of using vm=this;
I have tested in all way shapes and forms, and short of passing in a service to hold the data to be edited, there is no real way to connect the current page data.
I found this to be true because modalInstance was null whenever the break point was hit to close the modal. Because using the current pages controller, instantiated a new copy of the controller.
Is there a way to get your current page viewmodel/controller into the modal?
Thanks
Link to minimally-working plunker that reproduces the issue:
Steps to reproduce the issue:
Version of Angular, UIBS, and Bootstrap
Angular:
UIBS:
Bootstrap: