Thanks for the reply!
Actually, I want a sample code for this. Becuase I already create a schema and fauna already generate a docs for me within the GraphQL Playground but as I told in the topic it’s return with the blank data
type ShopCollection {
shop_collection_id: Int!
title: String!
automated_max_products: Int!
type: String!
has_autoshffle: Boolean!
base_rules: String!
status: String!
shop_domain: String!
createdAt: Time!
# _id: Generated by Fauna as each document's unique identifier
# _ts: Timestamp generated by Fauna upon object updating
}
# A query named 'entries' which returns an array of ShopCollection objects
# Implicit arguments: _size (count) and _cursor (location within the Index)
type Query {
entries: [ShopCollection!]
@resolver(name: "listLatestCollections", paginated: true)
}
So this is happening because of the @resolver directive on the listLatestCollections query. What that does is tell Fauna to invoke a User-defined function (UDF) named listLatestCollections whenever the GraphQL query entries is called.
What the error message is telling you is that the listLatestCollections UDF hasn’t been implemented by you.
You should be able to get this working by removing @resolver(name: "listLatestCollections", from your entries query definition.
You could also implement the listLatestCollections UDF, but that’s beyond the scope of this topic.