我已经定义了两条ember路线如下。
export default Router.map(function () {
this.route('stock-overview', {path: '/:lan/stock-overview/:companyId'});
this.route('stock-overview', {path: '/:lan/stock-overview/:exchange/:symbol'});
相同名称但不同数量的参数。但是当我按照以下方式添加link-to
帮助器时,它会出错。
<li>{{#link-to 'stock-overview' 'en' '70'}}Stock Overview{{/link-to}}</li>
<li>{{#link-to 'stock-overview' 'en' 'exchange' 'someSymbol'}}Stock Overview{{/link-to}}</li>
Console Error:
Uncaught Error: More context objects were passed than there are dynamic segments for the route: stock-overview
我该如何处理这种情况?我的余烬版本是:1.11.1
感谢任何帮助。
答案 0 :(得分:0)