Skip to content

Add relation resolver using ExtendObjectType #3178

Answered by gojanpaolo
danrot asked this question in Q&A
Discussion options

You must be logged in to vote

@danrot Can you create a project that reproduces the issue?

I tried running the code you provided but it's working fine.

See working sample project here: https://github.com/gojanpaolo/hotchocolate-3178

Runnning the following query:

query {
  employee(id: 1) {
    absences {
      id
    }
  }
}

... returns the following response

{
  "data": {
    "employee": {
      "absences": [
        {
          "id": 1
        }
      ]
    }
  }
}

Replies: 1 comment 8 replies

Comment options

You must be logged in to vote
8 replies
@gojanpaolo
Comment options

@danrot
Comment options

@danrot
Comment options

@michaelstaib
Comment options

@ThisNoName
Comment options

Answer selected by danrot
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
4 participants