If I understand correctly, then what you're wanting to do is access related
data. For example, if you request a `Teacher` object which `has_one
School`, then you want to be able to access data about the school.

Your API call should return this information, but perhaps you are concerned
that you are making too many database calls? If so, the solution you're
looking for is Active Record's `include`. See here:
http://guides.rubyonrails.org/active_record_querying.html#eager-loading-associations


On Thu, Jan 23, 2014 at 8:24 AM, Sheetal Sharma <
[email protected]> wrote:

> We are using rails at back end and angularjs on front end for an
> application. In rails we are using joins on tables for example id on one
> table corresponds to id in another table(has-one relationship in rails). Is
> there a way in angularjs by which we can access the data which we get by
> join on tables? currently we can only get the individual table data using
> json api call. if any example in angularjs corresponding to the above
> problem could be found please do post it.
>
>
> Thanks
>
> --
> You received this message because you are subscribed to the Google Groups
> "AngularJS" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to [email protected].
> Visit this group at http://groups.google.com/group/angular.
> For more options, visit https://groups.google.com/groups/opt_out.
>

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to