Sha256: f5f84574d4b12bf6612a5bc140d199ac98e1b70b99e3ee0ebe0c098333c35cc7
Contents?: true
Size: 734 Bytes
Versions: 6
Compression:
Stored size: 734 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.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.visible.where(component: object).find_by(id: args[:id]) end end end end
Version data entries
6 entries across 6 versions & 1 rubygems