Filter by procedure is activated on route /backoffice/dossiers/procedure/:id

This commit is contained in:
Xavier J 2016-09-08 16:21:54 +02:00
parent bb19982011
commit 62a0b84048
21 changed files with 287 additions and 15 deletions

View file

@ -1,5 +1,6 @@
class PreferenceListDossier < ActiveRecord::Base
belongs_to :gestionnaire
belongs_to :procedure
def table_attr
return self.attr if table.nil? || table.empty?

View file

@ -15,6 +15,8 @@ class Procedure < ActiveRecord::Base
has_many :assign_to, dependent: :destroy
has_many :gestionnaires, through: :assign_to
has_many :preference_list_dossiers
delegate :use_api_carto, to: :module_api_carto
accepts_nested_attributes_for :types_de_champ, :reject_if => proc { |attributes| attributes['libelle'].blank? }, :allow_destroy => true