Sha256: 3c901055ebddd663b79108bb3933a3ae2b945f00e6ab155e60c693b859fefd5d

Contents?: true

Size: 336 Bytes

Versions: 16

Compression:

Stored size: 336 Bytes

Contents

# frozen_string_literal: true

module Spotlight
  ##
  # Sir-trevor image upload attachments
  class Attachment < ActiveRecord::Base
    belongs_to :exhibit
    mount_uploader :file, Spotlight::AttachmentUploader

    def as_json(options = nil)
      file.as_json(options).merge(name:, uid:, attachment: to_global_id)
    end
  end
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
blacklight-spotlight-5.0.0.pre.alpha3 app/models/spotlight/attachment.rb
blacklight-spotlight-5.0.0.pre.alpha2 app/models/spotlight/attachment.rb
blacklight-spotlight-5.0.0.pre.alpha1 app/models/spotlight/attachment.rb
blacklight-spotlight-4.7.1 app/models/spotlight/attachment.rb
blacklight-spotlight-4.7.0 app/models/spotlight/attachment.rb
blacklight-spotlight-4.6.1 app/models/spotlight/attachment.rb
blacklight-spotlight-4.6.0 app/models/spotlight/attachment.rb
blacklight-spotlight-4.5.0 app/models/spotlight/attachment.rb
blacklight-spotlight-4.4.0 app/models/spotlight/attachment.rb
blacklight-spotlight-4.3.6 app/models/spotlight/attachment.rb
blacklight-spotlight-4.3.5 app/models/spotlight/attachment.rb
blacklight-spotlight-4.3.4 app/models/spotlight/attachment.rb
blacklight-spotlight-4.3.3 app/models/spotlight/attachment.rb
blacklight-spotlight-4.3.2 app/models/spotlight/attachment.rb
blacklight-spotlight-4.3.1 app/models/spotlight/attachment.rb
blacklight-spotlight-4.3.0 app/models/spotlight/attachment.rb