Nicholas Eli
05/06/2020, 9:12 PMgetPosts(_parent_, _args_, _ctx_, _info_){
return ctx.db.query.posts({}, info)
}
Data Model
type Post {
id: ID! @id
isPublished: Boolean! @default(_value_: false)
title: String!
text: String!
connections: [Connection!]! @relation(_name_: "ClientConnect")
}
type Link {
id: ID! @id
text: String!
url: String!
}
type Connection {
id: ID! @unique @id
client: Link @relation(_name_: "LinkConnect")
}
Schema
type Query {
getLinks(_filter_: String, _skip_: Int, _first_: Int, _orderBy_: LinkOrderByInput): [Link!]!
}
When I try to query this in the playground, on the Connection object, it references sort for that object. How can I refer it to the Link so that I may order on text or urlNicholas Eli
05/06/2020, 11:48 PM