Sha256: 8f1c9bff8681dece8d914c373587a12bebdab19a166770b4d6d5513b9f6cc4be
Contents?: true
Size: 754 Bytes
Versions: 44
Compression:
Stored size: 754 Bytes
Contents
# frozen_string_literal: true module Decidim module Meetings class MeetingsType < Decidim::Api::Types::BaseObject implements Decidim::Core::ComponentInterface graphql_name "Meetings" description "A meetings component of a participatory space." field :meetings, Decidim::Meetings::MeetingType.connection_type, null: true, connection: true def meetings Meeting.published.visible.where(component: object).includes(:component) end field :meeting, Decidim::Meetings::MeetingType, null: true do argument :id, GraphQL::Types::ID, required: true end def meeting(**args) Meeting.published.visible.where(component: object).find_by(id: args[:id]) end end end end
Version data entries
44 entries across 44 versions & 1 rubygems