"The server returned the hash with key 0" because didFindAll () expects the javascript object to be not a string. Try again:
json = {"items":[{"id":93,"title":"title","date":"14-11-2012"}]};
The next step is to transform the object to have the naming conventions that ember expects. Since your model is called Deadline, use the following:
jsonTransformed = '{"deadlines": [{"id":93,"title":"title 1","date":"14-11-2012"},{"id":94,"title":"title 2","date":"14-11-2012"}]}';
I added a second entry, but you get the idea. Finally, you need to change the way you set the Clive.deadlineList variable: Clive.Deadline.find() returns a collection of Clive.Deadline models, so it's simple:
Clive.deadlineList = Clive.Deadline.find() console.log(Clive.deadlineList.getEach('title')); // -> title1, title2
Here is the updated jsfiddle with a working example: http://jsfiddle.net/mgrassotti/6D5BC/9/
source share