0
{{#each posts}}
  {{view App.PostView controller=App.PostController}}
{{/each}}

但这总是得到 parentView 控制器而不是 PostController。

4

1 回答 1

2

I think you miss putting App.PostController between double quotes. The controller have to be an instance, not a class here. So you have to instantiate App.PostController in your js code beafore using it in the template.

于 2012-08-05T16:41:25.147 回答