7
8
9
10
11
12
13
14
15
16
|
# File 'lib/granite/form/active_record/nested_attributes.rb', line 7
def accepts_nested_attributes_for(*attr_names)
options = attr_names.
granite_associations, active_record_association = attr_names.partition do |association_name|
reflect_on_association(association_name).is_a?(Granite::Form::Model::Associations::Reflections::Base)
end
Granite::Form::Model::Associations::NestedAttributes::NestedAttributesMethods
.accepts_nested_attributes_for(self, *granite_associations, options.dup)
super(*active_record_association, options.dup)
end
|