jeudi 20 octobre 2016

How to define two ember routes with same name with different number of query params?

I have defined two ember routes as follows.

export default Router.map(function () {

    this.route('stock-overview', {path: '/:lan/stock-overview/:companyId'});
    this.route('stock-overview', {path: '/:lan/stock-overview/:exchange/:symbol'});

same name but different number of params. but when i add link-to helper as follows it gives an error saying.

<li>Stock Overview</li>
<li>Stock Overview</li>

Console Error: 
Uncaught Error: More context objects were passed than there are dynamic segments for the route: stock-overview

How can I handle this situation.? My ember version is:1.11.1 Appreciate any help.




Aucun commentaire:

Enregistrer un commentaire