Sha256: c019891169887bda17c706844e74e65be7b1583e196083627f966fe272a9f68f

Contents?: true

Size: 561 Bytes

Versions: 57

Compression:

Stored size: 561 Bytes

Contents

module Ddr::Auth
  class LegacyDefaultPermissions < AbstractLegacyPermissions

    def source
      default_permissions
    end

    def role_type(access)
      case access
      when "discover"
        Roles::VIEWER
      when "read"
        Roles::VIEWER
      when "edit"
        Roles::CURATOR
      end
    end

    def scope
      Roles::POLICY_SCOPE
    end

    def clear
      defaultRights.clear_permissions!
      defaultRights.content = defaultRights.to_xml
    end

    def inspect
      "DEFAULT PERMISSIONS: #{source.inspect}"
    end

  end
end

Version data entries

57 entries across 57 versions & 1 rubygems

Version Path
ddr-models-2.6.2 lib/ddr/auth/legacy/legacy_default_permissions.rb
ddr-models-2.6.1 lib/ddr/auth/legacy/legacy_default_permissions.rb
ddr-models-2.6.0 lib/ddr/auth/legacy/legacy_default_permissions.rb
ddr-models-2.6.0.rc4 lib/ddr/auth/legacy/legacy_default_permissions.rb
ddr-models-2.6.0.rc3 lib/ddr/auth/legacy/legacy_default_permissions.rb
ddr-models-2.6.0.rc2 lib/ddr/auth/legacy/legacy_default_permissions.rb
ddr-models-2.6.0.rc1 lib/ddr/auth/legacy/legacy_default_permissions.rb
ddr-models-2.5.3 lib/ddr/auth/legacy/legacy_default_permissions.rb
ddr-models-2.5.2 lib/ddr/auth/legacy/legacy_default_permissions.rb
ddr-models-2.5.1 lib/ddr/auth/legacy/legacy_default_permissions.rb
ddr-models-2.5.0 lib/ddr/auth/legacy/legacy_default_permissions.rb
ddr-models-2.5.0.rc1 lib/ddr/auth/legacy/legacy_default_permissions.rb
ddr-models-2.4.16 lib/ddr/auth/legacy/legacy_default_permissions.rb
ddr-models-2.4.15 lib/ddr/auth/legacy/legacy_default_permissions.rb
ddr-models-2.4.14 lib/ddr/auth/legacy/legacy_default_permissions.rb
ddr-models-2.4.13 lib/ddr/auth/legacy/legacy_default_permissions.rb
ddr-models-2.4.12 lib/ddr/auth/legacy/legacy_default_permissions.rb
ddr-models-2.4.11 lib/ddr/auth/legacy/legacy_default_permissions.rb
ddr-models-2.4.10 lib/ddr/auth/legacy/legacy_default_permissions.rb
ddr-models-2.4.9 lib/ddr/auth/legacy/legacy_default_permissions.rb