Sha256: 88ad6ba6169c13da0eaf4fb52890f99850c197e48ee634e88b9a4702276d0d20

Contents?: true

Size: 1.25 KB

Versions: 16

Compression:

Stored size: 1.25 KB

Contents

module Ecoportal
  module API
    class GraphQL
      module Query
        class Actions < Ecoportal::API::GraphQL::Logic::QueryConnection
          field_name :actions

          class_resolver :item_class, Ecoportal::API::GraphQL::Model::Action
          class_resolver :connection_class, Ecoportal::API::GraphQL::Connection::Action

          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 {
                  actions(
                    searchConf: :searchConf,
                    after: :after,
                    before: :before,
                    first: :first,
                    last: :last,
                    &connection_block
                  )
                }
              }
            }
          end

          def default_connection_block
            Proc.new {
              ___Ecoportal__API__GraphQL__Fragment__Pagination
              nodes {
                ___Ecoportal__API__GraphQL__Fragment__Action
              }
            }
          end
        end
      end
    end
  end
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
ecoportal-api-graphql-0.3.15 lib/ecoportal/api/graphql/query/actions.rb
ecoportal-api-graphql-0.3.14 lib/ecoportal/api/graphql/query/actions.rb
ecoportal-api-graphql-0.3.13 lib/ecoportal/api/graphql/query/actions.rb
ecoportal-api-graphql-0.3.12 lib/ecoportal/api/graphql/query/actions.rb
ecoportal-api-graphql-0.3.11 lib/ecoportal/api/graphql/query/actions.rb
ecoportal-api-graphql-0.3.10 lib/ecoportal/api/graphql/query/actions.rb
ecoportal-api-graphql-0.3.9 lib/ecoportal/api/graphql/query/actions.rb
ecoportal-api-graphql-0.3.8 lib/ecoportal/api/graphql/query/actions.rb
ecoportal-api-graphql-0.3.7 lib/ecoportal/api/graphql/query/actions.rb
ecoportal-api-graphql-0.3.6 lib/ecoportal/api/graphql/query/actions.rb
ecoportal-api-graphql-0.3.5 lib/ecoportal/api/graphql/query/actions.rb
ecoportal-api-graphql-0.3.3 lib/ecoportal/api/graphql/query/actions.rb
ecoportal-api-graphql-0.3.1 lib/ecoportal/api/graphql/query/actions.rb
ecoportal-api-graphql-0.2.3 lib/ecoportal/api/graphql/query/actions.rb
ecoportal-api-graphql-0.2.2 lib/ecoportal/api/graphql/query/actions.rb
ecoportal-api-graphql-0.2.1 lib/ecoportal/api/graphql/query/actions.rb