add test and fix association fo type piece jointe

This commit is contained in:
Tanguy PATTE 2015-08-17 11:24:09 +02:00
parent ae3ffbd780
commit e53c808b42
2 changed files with 24 additions and 6 deletions

View file

@ -1,8 +1,4 @@
class TypePieceJointe < ActiveRecord::Base
# TODO: test this methods
def self.get_liste_piece_jointe(formulaire)
where ("\"CERFA\" = '#{formulaire.demarche_id}'")
end
has_many :pieces_jointes
belongs_to :formulaire
end