Sha256: d2f44780f7c36435ff7fc57d834ce5fccafa4f70ab1cfb3918ee83da92e3bf98

Contents?: true

Size: 786 Bytes

Versions: 17

Compression:

Stored size: 786 Bytes

Contents

# frozen_string_literal: true
module Thredded
  module UserPermissions
    module Read
      module All
        extend ActiveSupport::Concern
        included { extend ClassMethods }

        # @return [ActiveRecord::Relation<Thredded::Messageboard>] messageboards that the user can read
        def thredded_can_read_messageboards
          Thredded::Messageboard.all
        end

        module ClassMethods
          # Users that can read the given messageboards.
          #
          # @param _messageboards [Array<Thredded::Messageboard>]
          # @return [ActiveRecord::Relation<Thredded.user_class>] users that can read the given messageboards
          def thredded_messageboards_readers(_messageboards)
            all
          end
        end
      end
    end
  end
end

Version data entries

17 entries across 17 versions & 1 rubygems

Version Path
thredded-0.9.4 app/models/thredded/user_permissions/read/all.rb
thredded-0.9.3 app/models/thredded/user_permissions/read/all.rb
thredded-0.9.2 app/models/thredded/user_permissions/read/all.rb
thredded-0.9.1 app/models/thredded/user_permissions/read/all.rb
thredded-0.8.4 app/models/thredded/user_permissions/read/all.rb
thredded-0.8.2 app/models/thredded/user_permissions/read/all.rb
thredded-0.7.0 app/models/thredded/user_permissions/read/all.rb
thredded-0.6.3 app/models/thredded/user_permissions/read/all.rb
thredded-0.6.2 app/models/thredded/user_permissions/read/all.rb
thredded-0.6.1 app/models/thredded/user_permissions/read/all.rb
thredded-0.6.0 app/models/thredded/user_permissions/read/all.rb
thredded-0.5.1 app/models/thredded/user_permissions/read/all.rb
thredded-0.5.0 app/models/thredded/user_permissions/read/all.rb
thredded-0.4.0 app/models/thredded/user_permissions/read/all.rb
thredded-0.3.2 app/models/thredded/user_permissions/read/all.rb
thredded-0.3.1 app/models/thredded/user_permissions/read/all.rb
thredded-0.3.0 app/models/thredded/user_permissions/read/all.rb