Class: AWeber::Resources::Subscriber
- Inherits:
-
AWeber::Resource
- Object
- AWeber::Resource
- AWeber::Resources::Subscriber
- Defined in:
- lib/aweber/resources/subscriber.rb
Instance Attribute Summary
Attributes inherited from AWeber::Resource
Instance Method Summary collapse
Methods inherited from AWeber::Resource
#<=>, alias_attribute, api_attr, basepath, #delete, has_many, has_one, #initialize, #inspect, #path, #save, #uri, #writable_attrs
Constructor Details
This class inherits a constructor from AWeber::Resource
Instance Method Details
#list=(list) ⇒ Object
29 30 31 32 33 34 35 |
# File 'lib/aweber/resources/subscriber.rb', line 29 def list=(list) client.post(self_link, { "ws.op" => "move", "list_link" => list.self_link }) move_to(list) end |
#move(list, last_followup_sent = nil) ⇒ Object
37 38 39 40 41 42 43 44 45 46 47 48 49 |
# File 'lib/aweber/resources/subscriber.rb', line 37 def move(list, last_followup_sent=nil) move_args = { "ws.op" => "move", "list_link" => list.self_link } if last_followup_sent move_args['last_followup_message_number_sent'] = last_followup_sent end r = client.post(self_link, move_args) move_to(list) end |