Sha256: 36f379fd492cf6b34d7d26e36a5b306b14d35f28bce92cbb8158c2b39dea7a8a

Contents?: true

Size: 365 Bytes

Versions: 29

Compression:

Stored size: 365 Bytes

Contents

# frozen_string_literal: true
module Hyrax
  class FileSet
    module Querying
      extend ActiveSupport::Concern

      module ClassMethods
        def where_digest_is(digest_string)
          where "digest_ssim" => urnify(digest_string)
        end

        def urnify(digest_string)
          "urn:sha1:#{digest_string}"
        end
      end
    end
  end
end

Version data entries

29 entries across 29 versions & 1 rubygems

Version Path
hyrax-5.1.0.pre.beta1 app/models/concerns/hyrax/file_set/querying.rb
hyrax-5.0.4 app/models/concerns/hyrax/file_set/querying.rb
hyrax-5.0.3 app/models/concerns/hyrax/file_set/querying.rb
hyrax-5.0.2 app/models/concerns/hyrax/file_set/querying.rb
hyrax-5.0.1 app/models/concerns/hyrax/file_set/querying.rb
hyrax-5.0.0 app/models/concerns/hyrax/file_set/querying.rb
hyrax-5.0.0.rc3 app/models/concerns/hyrax/file_set/querying.rb
hyrax-5.0.0.rc2 app/models/concerns/hyrax/file_set/querying.rb
hyrax-5.0.0.rc1 app/models/concerns/hyrax/file_set/querying.rb
hyrax-3.6.0 app/models/concerns/hyrax/file_set/querying.rb
hyrax-4.0.0 app/models/concerns/hyrax/file_set/querying.rb
hyrax-4.0.0.rc3 app/models/concerns/hyrax/file_set/querying.rb
hyrax-4.0.0.rc2 app/models/concerns/hyrax/file_set/querying.rb
hyrax-4.0.0.rc1 app/models/concerns/hyrax/file_set/querying.rb
hyrax-3.5.0 app/models/concerns/hyrax/file_set/querying.rb
hyrax-4.0.0.beta2 app/models/concerns/hyrax/file_set/querying.rb
hyrax-3.4.2 app/models/concerns/hyrax/file_set/querying.rb
hyrax-4.0.0.beta1 app/models/concerns/hyrax/file_set/querying.rb
hyrax-3.4.1 app/models/concerns/hyrax/file_set/querying.rb
hyrax-3.4.0 app/models/concerns/hyrax/file_set/querying.rb