Class: Insightly::TaskLink
Class Method Summary
collapse
Instance Method Summary
collapse
Methods inherited from ReadOnly
#==, #build, build, #config, #get_collection, #initialize, #process, #remote_data
Methods inherited from Base
#==, all, api_field, build, #build, #config, custom_fields, date_to_insightly, #get_collection, #initialize, #load, #process, #reload, #remote_data, #remote_id=, #remote_id?, #remote_id_field, #to_json, #url_base
Class Method Details
28
29
30
31
32
|
# File 'lib/insightly/task_link.rb', line 28
def self.add_contact(id)
item = TaskLink.new
item.contact_id = id
item
end
|
.add_opportunity(id) ⇒ Object
34
35
36
37
38
39
|
# File 'lib/insightly/task_link.rb', line 34
def self.add_opportunity(id)
item = TaskLink.new
item.opportunity_id = id
item
end
|
.add_organisation(id) ⇒ Object
41
42
43
44
45
|
# File 'lib/insightly/task_link.rb', line 41
def self.add_organisation(id)
item = TaskLink.new
item.organisation_id = id
item
end
|
.search_by_opportunity_id(opportunity_id) ⇒ Object
18
19
20
21
22
23
24
25
26
|
# File 'lib/insightly/task_link.rb', line 18
def self.search_by_opportunity_id(opportunity_id)
list = []
TaskLink.all.each do |x|
if !x.task_id.nil? && x.opportunity_id == opportunity_id
list << x
end
end
list
end
|
Instance Method Details
#remote_id ⇒ Object
14
15
16
|
# File 'lib/insightly/task_link.rb', line 14
def remote_id
self.task_link_id
end
|