Class: ActiveForms::Form
Instance Attribute Summary
Attributes inherited from Mapper
#attributes
Class Method Summary
collapse
Instance Method Summary
collapse
Methods inherited from Mapper
#==, #apiVersion=, #initialize, #xmlns=
Class Method Details
.all(params = {}) ⇒ Object
5
6
7
8
9
10
11
12
|
# File 'lib/active_forms/form.rb', line 5
def all(params = {})
response = ActiveForms::Request.get("forms", params)
hashes = response["forms"]["form"]
hashes = [hashes] if hashes.is_a?(Hash)
objects = hashes.map { |attributes| new(attributes) }
end
|
Instance Method Details
#active? ⇒ Boolean
24
25
26
|
# File 'lib/active_forms/form.rb', line 24
def active?
status == "active"
end
|
#inactive? ⇒ Boolean
28
29
30
|
# File 'lib/active_forms/form.rb', line 28
def inactive?
status == "inactive"
end
|