Skip to content

support nested relations? #9

Description

@tkellen

Some context:
In this example, an organization has projects and a project has phases. Sometimes, a user may wish to see the organization related to the phase, but not want the intermediate project record in the response.
This can be accomplished using endpoints with the following:

GET /project-phases/12?include=project.organizations

{
  "linked": {
    "organizations": [
      {
        "id": 12,
        "name": ".....",
      }
    ]
  },
  "project-phases": {
    "id": 1,
    "name": "Phase One",
    "project_id": 25,
    "first_day": "2014-04-21T04:00:00.000Z",
    "last_day": "2014-12-22T05:00:00.000Z",
    "links": {
      "project.organization": {
        "type": "organizations",
        "id": 12
      }
    }
  }
}

Is supporting this even possible with ember-data @bmac?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions