Trouble modeling my data


#1

Hi everyone,

I made a custom API using Symfony2 (with FOSRESTBundle). My problem is that I did not follow the convention of Ember. Here is an example of what I get when I call /catalogs/1

Here is what my API return: http://i.stack.imgur.com/y8V0h.png

I would like to have a model catalog that “hasMany” category, and a category could “hasMany” other category and “belongTo” his parent. Unfortunatly what I understand is that My JSON should return something like

catalog_categories[1,2,3]

My question is : Should I rework my whole API to fit the convention of ember or is there a way to make it work. I’ve read the whole documentation of ember-data but haven’t yet find what I need. Did I miss something?