Sha256: 78963bc326518956a17e2e2167857deea15a1c724ec8f8faf8da04709069a0de

Contents?: true

Size: 326 Bytes

Versions: 66

Compression:

Stored size: 326 Bytes

Contents

module CurationConcerns
  module Permissions
    module Readable
      extend ActiveSupport::Concern
      def public?
        read_groups.include?('public')
      end

      def registered?
        read_groups.include?('registered')
      end

      def private?
        !(public? || registered?)
      end
    end
  end
end

Version data entries

66 entries across 66 versions & 2 rubygems

Version Path
curation_concerns-1.3.2 app/models/concerns/curation_concerns/permissions/readable.rb
curation_concerns-1.3.1 app/models/concerns/curation_concerns/permissions/readable.rb
curation_concerns-1.3.0 app/models/concerns/curation_concerns/permissions/readable.rb
curation_concerns-1.2.0 app/models/concerns/curation_concerns/permissions/readable.rb
curation_concerns-1.1.2 app/models/concerns/curation_concerns/permissions/readable.rb
curation_concerns-1.1.1 app/models/concerns/curation_concerns/permissions/readable.rb
curation_concerns-1.1.0 app/models/concerns/curation_concerns/permissions/readable.rb
curation_concerns-1.0.0 app/models/concerns/curation_concerns/permissions/readable.rb
curation_concerns-1.0.0.beta10 app/models/concerns/curation_concerns/permissions/readable.rb
curation_concerns-1.0.0.beta9 app/models/concerns/curation_concerns/permissions/readable.rb
curation_concerns-1.0.0.beta8 app/models/concerns/curation_concerns/permissions/readable.rb
curation_concerns-1.0.0.beta7 app/models/concerns/curation_concerns/permissions/readable.rb
curation_concerns-1.0.0.beta6 app/models/concerns/curation_concerns/permissions/readable.rb
curation_concerns-1.0.0.beta5 app/models/concerns/curation_concerns/permissions/readable.rb
curation_concerns-1.0.0.beta4 app/models/concerns/curation_concerns/permissions/readable.rb
curation_concerns-1.0.0.beta3 app/models/concerns/curation_concerns/permissions/readable.rb
curation_concerns-1.0.0.beta2 app/models/concerns/curation_concerns/permissions/readable.rb
curation_concerns-1.0.0.beta1 app/models/concerns/curation_concerns/permissions/readable.rb
curation_concerns-0.14.0 app/models/concerns/curation_concerns/permissions/readable.rb
curation_concerns-0.14.0.pre4 app/models/concerns/curation_concerns/permissions/readable.rb