regarding the different posts I read I would have expected that the following code should work:
<tbody>
{{#each NewApp.router.gridController.tableContent}}
{{#view NewApp.TableRow rowBinding="this"}}
<td style="width: 100px">{{row.item_no}}</td>
<td align="right" style="width: 100px">{{row.price}}</td>
<td>{{row.name}}</td>
{{/view}}
{{/each}}
</tbody>
But I get only empty table rows. If I use tr everything works as expected.
The TableRow is defined as:
NewApp.TableRow = Ember.View.extend({
tagName: "tr",
row: null,
willInsertElement: function() {
console.dir(this.get("row"));
}
});
BTW: console.dir shows the correct data.
Regards
Roger
You can take a look at http://docs.emberjs.com/#doc=Ember.CollectionView&src=false, it can simplify your code.
For your example, use {{view.row.XXX}} in the template, it should do the job