Sha256: d564bc9a4448b9cfd7cfa07345526fa96c8644e65b144c59692137af1fb2cf59
Contents?: true
Size: 400 Bytes
Versions: 3
Compression:
Stored size: 400 Bytes
Contents
require 'attachable' class Attachment include Mongoid::Document include Mongoid::Timestamps include Attachable field :title field :filename attaches :file embedded_in :specialist_document_edition validates_with SafeHtml def url file.file_url end # TODO: Move this to a domain object in specialist publisher def snippet "[InlineAttachment:#{filename}]" end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
govuk_content_models-8.9.0 | app/models/attachment.rb |
govuk_content_models-8.8.0 | app/models/attachment.rb |
govuk_content_models-8.7.0 | app/models/attachment.rb |