1
0
mirror of https://github.com/LaCasemate/fab-manager.git synced 2025-01-29 18:52:22 +01:00

[fix taiga#15] empty workshop attachment not added

This commit is contained in:
Sylvain 2016-03-31 14:02:16 +02:00
parent 0273783b91
commit 32d5184164

View File

@ -4,7 +4,7 @@ class Event < ActiveRecord::Base
has_one :event_image, as: :viewable, dependent: :destroy
accepts_nested_attributes_for :event_image, allow_destroy: true
has_many :event_files, as: :viewable, dependent: :destroy
accepts_nested_attributes_for :event_files, allow_destroy: true
accepts_nested_attributes_for :event_files, allow_destroy: true, reject_if: :all_blank
has_and_belongs_to_many :categories, join_table: :events_categories
belongs_to :availability, dependent: :destroy