Sha256: 02910d91bf13c007fbc220207b6e0c3355ccbd5fc8a4069639dfcb69459aa4ab

Contents?: true

Size: 482 Bytes

Versions: 37

Compression:

Stored size: 482 Bytes

Contents

# frozen_string_literal: true

module Decidim
  # This type represents the current user session.
  SessionType = GraphQL::ObjectType.define do
    name "Session"
    description "The current session"

    field :user, UserType, "The current user" do
      resolve ->(obj, _args, _ctx) { obj }
    end

    field :verifiedUserGroups, !types[!UserGroupType], "The current user verified user groups" do
      resolve ->(obj, _args, _ctx) { obj.user_groups.verified }
    end
  end
end

Version data entries

37 entries across 37 versions & 2 rubygems

Version Path
decidim-core-0.9.3 lib/decidim/core/api/session_type.rb
decidim-core-0.9.2 lib/decidim/core/api/session_type.rb
decidim-core-0.9.1 lib/decidim/core/api/session_type.rb
decidim-core-0.9.0 lib/decidim/core/api/session_type.rb
decidim-core-0.8.4 lib/decidim/core/api/session_type.rb
decidim-core-0.8.3 lib/decidim/core/api/session_type.rb
decidim-core-0.8.2 lib/decidim/core/api/session_type.rb
decidim-core-0.8.1 lib/decidim/core/api/session_type.rb
decidim-core-0.8.0 lib/decidim/core/api/session_type.rb
decidim-core-0.7.4 lib/decidim/core/api/session_type.rb
decidim-core-0.7.3 lib/decidim/core/api/session_type.rb
decidim-core-0.7.2 lib/decidim/core/api/session_type.rb
decidim-core-0.7.1 lib/decidim/core/api/session_type.rb
decidim-core-0.7.0 lib/decidim/core/api/session_type.rb
decidim-core-0.6.8 lib/decidim/core/api/session_type.rb
decidim-0.6.8 decidim-core/lib/decidim/core/api/session_type.rb
decidim-core-0.6.7 lib/decidim/core/api/session_type.rb
decidim-0.6.7 decidim-core/lib/decidim/core/api/session_type.rb
decidim-core-0.6.6 lib/decidim/core/api/session_type.rb
decidim-0.6.6 decidim-core/lib/decidim/core/api/session_type.rb