demarches-normaliennes/app/models/piece_jointe.rb

13 lines
292 B
Ruby
Raw Normal View History

class PieceJointe < ActiveRecord::Base
belongs_to :dossier
belongs_to :type_piece_jointe
2015-08-18 17:00:09 +02:00
delegate :api_entreprise, :libelle, to: :type_piece_jointe
alias_attribute :type, :type_piece_jointe_id
mount_uploader :content, PieceJointeUploader
2015-08-18 16:51:57 +02:00
def empty?
content.blank?
end
end