Model not being executed when router change


#1

i’m building my first emberJS application, just started learning yesterday about the framework to day i started getting into some problems that couldn’t find a solution for… this is one of them :smile:

i have a search result: http://rommelxcastro.github.io/batarang/#/stocks/search/goo if you click on one of the item you should go to a new route that is something like (http://rommelxcastro.github.io/batarang/#/stocks/STATNOR/1225_70109301_2), this is suppose to show all the info, no problem with this, the problem is that when the route is loaded i need to load some more information for this specific item and update the model but looks like the model inside the route is not being executed, idk why or the info is not being updated. this is my route code: https://github.com/rommelxcastro/batarang/blob/develop/app/scripts/routes/stock_route.js#L17

thanks for the help, if you didn’t understand something, please let me know


#2

I think the problem is that you’re trying to pass an object in your transitionToRoute() in your controller- it should follow these conventions. Pass the stock symbol as a dynamic segment to the display route (eg., transitionToRoute(“stocks.search”, stockSymbol)).