I have an Ember route with a model hook that returns a jquery promise; the data is returned correctly and its structure is:
{
status: 'success',
data: [...]
}
In the template I'm trying to access the data field (is an array of objects, each of them with username and other properties).
{{#each model.data in data}}
- this is a user:
{{???.username}}
{{/each}}
I can't understand what I have to use instead of "???" to be able to display the username; I can see that the data is cycled correctly by the each helper because I get the string "- this is a user:" as many times as the data array's length
Aucun commentaire:
Enregistrer un commentaire