Doesn't work well when using router
Modal service for AngularJS - supports creating popups and modals via a service.
Brought to you by:
evanfcrane
Originally created by: Utkarsh85
I am calling ModalService from a directive, which works well when on a particular route view. However, when I change the route to other view where the same directive exists, the ModelService fails to open.
Another issue I observed, when using ModalService in another service and called from any controller, again fails to open.
View and moderate all "tickets Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Tickets"
Originally posted by: pdgendt
When using ui-router in particular (don't know in general), if you inject
ModalServicemultiple times it won't work anymore.Solution for me was to return a new
ModalServiceinstance every time the factory was called.View and moderate all "tickets Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Tickets"
Originally posted by: pdgendt
I've made a gist with the modified factory, maybe someone can comment or verify: https://gist.github.com/pdgendt/c351649feb30860182c2