Allow to render map without marker on new forms.

This commit is contained in:
Senén Rodero Rodríguez
2017-08-08 10:47:35 +02:00
parent dd7afd3593
commit 130e4533ac
9 changed files with 79 additions and 32 deletions

View File

@@ -27,8 +27,8 @@ class Budget
has_many :valuators, through: :valuator_assignments
has_many :comments, as: :commentable
has_many :milestones
has_one :map_location
accepts_nested_attributes_for :map_location
has_one :map_location, dependent: :destroy
accepts_nested_attributes_for :map_location, allow_destroy: true
validates :title, presence: true
validates :author, presence: true