13 lines
243 B
Ruby
13 lines
243 B
Ruby
# frozen_string_literal: true
|
|
|
|
class Attestation < ApplicationRecord
|
|
belongs_to :dossier, optional: false
|
|
|
|
has_one_attached :pdf
|
|
|
|
def pdf_url
|
|
if pdf.attached?
|
|
Rails.application.routes.url_helpers.url_for(pdf)
|
|
end
|
|
end
|
|
end
|