Class: Dscf::Core::Document
- Inherits:
-
ApplicationRecord
- Object
- ActiveRecord::Base
- ApplicationRecord
- Dscf::Core::Document
- Defined in:
- app/models/dscf/core/document.rb
Instance Method Summary collapse
Instance Method Details
#file_url ⇒ Object
12 13 14 15 16 |
# File 'app/models/dscf/core/document.rb', line 12 def file_url return nil unless file.attached? Rails.application.routes.url_helpers.rails_blob_url(file, only_path: true) end |