Sha256: 2578029766460c9aafc620e89b08df2c758e4fc318f8803c7eeac798a33d8b7c
Contents?: true
Size: 1.67 KB
Versions: 2
Compression:
Stored size: 1.67 KB
Contents
module Ecoportal module API class GraphQL module Query class ContractorEntities < Ecoportal::API::GraphQL::Base::QueryConnection class_resolver :item_class, Ecoportal::API::GraphQL::Model::ContractorEntity class_resolver :connection_class, Ecoportal::API::GraphQL::Connection::ContractorEntity def query(path: default_base_path, **kargs, &block) path ||= default_base_path #ap = access_point(path) request(*path, "contractorEntities") do graphql_query(**kargs, &basic_block(&block)) end end def default_base_path ["currentOrganization"] end private def basic_block(&block) connection_block = block || default_connection_block Proc.new { query(searchConf: :Search, after: :string, before: :string, first: :int, last: :int) { currentOrganization { contractorEntities( searchConf: :searchConf, after: :after, before: :before, first: :first, last: :last, &connection_block ) } } } end def default_connection_block Proc.new { totalCount pageInfo { endCursor } nodes { ___Ecoportal__API__GraphQL__Fragment__ContractorEntity } } end end end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
ecoportal-api-graphql-0.1.6 | lib/ecoportal/api/graphql/query/contractor_entities.rb |
ecoportal-api-graphql-0.1.5 | lib/ecoportal/api/graphql/query/contractor_entities.rb |