opitzconsulting / jquery-mobile-angular-adapter

jquery mobile angular adapter
MIT License
517 stars 114 forks source link

Problems redirecting to a page after a dialog is closed with the new version. #165

Closed jaumeavila closed 11 years ago

jaumeavila commented 11 years ago

Hi! With the previous version of the adapter (1.2.1) we could redirect after a dialog had been closed, but now, with the latest version, it does not work. For what we have debugged, it seems like the vent locationChangeStart is not correctly fired after the dialog is closed, which is kind of correct, I guess, since a dialog is not a new page (I think). But somehow, it was fired before.

Please look at this fiddle that Tobias did for me when I asked how to redirect after a dialog was closed and worked fine before. http://jsfiddle.net/gHQ29/

Thanks,

Jaume

tbosch commented 11 years ago

Updated the jsfiddle to use the current libraries: http://jsfiddle.net/gHQ29/1/

tbosch commented 11 years ago

Hi, yes, navigation has changed (to the better :-) ) . Closing a dialog now goes back in history, as it should. So, you could just intercept that close function.

Here is an updated jsfiddle: http://jsfiddle.net/gHQ29/2/

Note: This is a lot simpler and does not require the redirectService any more...

Does this solve your problem?

Tobias

jaumeavila commented 11 years ago

Yes, this absolutely solves our problem.

Thanks so much!

Jaume