Class: Podio::Reminder
Instance Attribute Summary
#attributes, #error_code, #error_message, #error_parameters, #error_propagate
Class Method Summary
collapse
#==, #[], #[]=, #api_friendly_ref_type, #as_json, collection, delegate_to_hash, handle_api_errors_for, has_many, has_one, #hash, #initialize, list, member, #new_record?, #persisted?, property, #to_param
Class Method Details
.create(ref_type, ref_id, attributes) ⇒ Object
16
17
18
19
20
21
22
|
# File 'lib/podio/models/reminder.rb', line 16
def create(ref_type, ref_id, attributes)
response = Podio.connection.post do |req|
req.url "/reminder/#{ref_type}/#{ref_id}"
req.body = attributes
end
response.status
end
|
.delete(ref_type, ref_id) ⇒ Object
8
9
10
|
# File 'lib/podio/models/reminder.rb', line 8
def delete(ref_type, ref_id)
Podio.connection.delete("/reminder/#{ref_type}/#{ref_id}").body
end
|
.snooze(ref_type, ref_id) ⇒ Object
12
13
14
|
# File 'lib/podio/models/reminder.rb', line 12
def snooze(ref_type, ref_id)
Podio.connection.post("/reminder/#{ref_type}/#{ref_id}/snooze").body
end
|
.update(ref_type, ref_id, attributes) ⇒ Object
24
25
26
27
28
29
30
|
# File 'lib/podio/models/reminder.rb', line 24
def update(ref_type, ref_id, attributes)
response = Podio.connection.put do |req|
req.url "/reminder/#{ref_type}/#{ref_id}"
req.body = attributes
end
response.status
end
|