Class: FormObj::Form::Array
Instance Method Summary
collapse
#build, #create, #to_hash, #update_attributes
Instance Method Details
#mark_as_persisted ⇒ Object
8
9
10
|
# File 'lib/form_obj/form/array.rb', line 8
def mark_as_persisted
each(&:mark_as_persisted)
end
|
#mark_for_destruction ⇒ Object
12
13
14
|
# File 'lib/form_obj/form/array.rb', line 12
def mark_for_destruction
each(&:mark_for_destruction)
end
|
#marked_for_destruction ⇒ Object
16
17
18
|
# File 'lib/form_obj/form/array.rb', line 16
def marked_for_destruction
select(&:marked_for_destruction?)
end
|
#persisted? ⇒ Boolean
4
5
6
|
# File 'lib/form_obj/form/array.rb', line 4
def persisted?
empty? || all?(&:persisted?)
end
|