opitzconsulting / jquery-mobile-angular-adapter

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

Problems passing parameter functions with navigate in v1.1.2 #95

Closed jaumeavila closed 11 years ago

jaumeavila commented 11 years ago

When passing a parameter to a function using navigate, in version 1.1.2 it sends the parameter as an object instead of a string or an int. In v1.1.1 it worked great. Example using v1.1.1 and working: http://jsfiddle.net/FL5Wf/2/

Example using v1.1.2 and not working: http://jsfiddle.net/FL5Wf/3/

Debuggin I have seen that it is received by the destination controller as an object.

Jaume

tbosch commented 11 years ago

Hi, this is a breaking change introduces in 1.1.2, also mentioned in the Changelog.md. $navigate now only accepts one parameter object, which needs to be a hash, and that hash is given to the onActivate function.

Here is a fiddle to show this: http://jsfiddle.net/FL5Wf/6/

Tobias

jaumeavila commented 11 years ago

Thanks, Tobias.

Sorry for not checking changelog.md.

Jaume

tbosch commented 11 years ago

Hi, please note that I just pushed a change that removes $navigate from the adapter. Please use the functions on $location instead. I created a migration guide: https://github.com/tigbro/jquery-mobile-angular-adapter/blob/master/Changelog.md

Tobias