Class: Basecamp3::Forward

Inherits:
Model
  • Object
show all
Includes:
Concerns::Bucketable, Concerns::Creatorable, Concerns::Parentable, Concerns::Recordingable
Defined in:
lib/basecamp3/models/forward.rb

Overview

Constant Summary

Constants inherited from Model

Model::REQUIRED_FIELDS

Instance Attribute Summary collapse

Class Method Summary collapse

Methods included from Concerns::Recordingable

included

Methods included from Concerns::Parentable

#parent

Methods included from Concerns::Bucketable

#bucket

Methods included from Concerns::Creatorable

#creator

Methods inherited from Model

#initialize

Constructor Details

This class inherits a constructor from Basecamp3::Model

Instance Attribute Details

#contentObject

Returns the value of attribute content



10
11
12
# File 'lib/basecamp3/models/forward.rb', line 10

def content
  @content
end

#created_atObject

Returns the value of attribute created_at



10
11
12
# File 'lib/basecamp3/models/forward.rb', line 10

def created_at
  @created_at
end

#fromObject

Returns the value of attribute from



10
11
12
# File 'lib/basecamp3/models/forward.rb', line 10

def from
  @from
end

#idObject

Returns the value of attribute id



10
11
12
# File 'lib/basecamp3/models/forward.rb', line 10

def id
  @id
end

#replies_countObject

Returns the value of attribute replies_count



10
11
12
# File 'lib/basecamp3/models/forward.rb', line 10

def replies_count
  @replies_count
end

#statusObject

Returns the value of attribute status



10
11
12
# File 'lib/basecamp3/models/forward.rb', line 10

def status
  @status
end

#subjectObject

Returns the value of attribute subject



10
11
12
# File 'lib/basecamp3/models/forward.rb', line 10

def subject
  @subject
end

#updated_atObject

Returns the value of attribute updated_at



10
11
12
# File 'lib/basecamp3/models/forward.rb', line 10

def updated_at
  @updated_at
end

Class Method Details

.all(bucket_id, parent_id, params = {}) ⇒ Array<Basecamp3::Forward>

Returns a paginated list of active forwards.

Parameters:

  • bucket_id (Integer)

    the id of the bucket

  • parent_id (Integer)

    the id of the inbox

  • params (Hash) (defaults to: {})

    additional parameters

Options Hash (params):

  • :page (Integer) — default: optional

    to paginate results

Returns:



27
28
29
# File 'lib/basecamp3/models/forward.rb', line 27

def self.all(bucket_id, parent_id, params = {})
  Basecamp3.request.get("/buckets/#{bucket_id}/inboxes/#{parent_id}/forwards", params, Basecamp3::Forward)
end

.find(bucket_id, id) ⇒ Basecamp3::Forward

Returns the forward.

Parameters:

  • bucket_id (Integer)

    the id of the bucket

  • id (Integer)

    the id of the forward

Returns:



37
38
39
# File 'lib/basecamp3/models/forward.rb', line 37

def self.find(bucket_id, id)
  Basecamp3.request.get("/buckets/#{bucket_id}/inbox_forwards/#{id}", {}, Basecamp3::Forward)
end