JSON and nested objects

2 views
Skip to first unread message

Robots And Pencils Developers

unread,
Jan 17, 2011, 11:19:22 AM1/17/11
to ObjectiveResource
This library was not allowing nested objects for me when using JSON.
I thought one of the branches that was integrated said it did this,
but maybe just for one to many. I have added it for belongs_to and
has_one. Let me know if anyone wants this. The way I coded it, you
would just add this to a class you want to show up as a nested
resource:

+ (BOOL)allowNesting{
return YES;
}

Note: you still have to actually return that nested object in your
rails code.
Reply all
Reply to author
Forward
0 new messages