同じサブリソースを持つ2つのリソースがあります。
App.Router.map(function() {
this.resource('post', function() {
this.resource('comments', function() {
this.route('new');
});
});
this.resource('product', function() {
this.resource('comments', function() {
this.route('new');
});
});
});
問題は、emberルーターが、階層全体からではなく、現在のルートと親ルートだけからルートオブジェクトの名前を作成することです。/posts/:id/comments/new
したがって、とオブジェクトの両方をルーティングしようとし/products/:id/comments/new
ますApp.NewCommentRoute
。これを修正するにはどうすればよいですか?
この投稿は、GitHubの問題を基にしています。