Class: SfIntegrator::Lead
- Inherits:
-
Object
- Object
- SfIntegrator::Lead
- Includes:
- ActiveModel::Validations
- Defined in:
- lib/sf_integrator/lead.rb
Instance Attribute Summary collapse
-
#client ⇒ Object
Returns the value of attribute client.
-
#company ⇒ Object
Returns the value of attribute company.
-
#email ⇒ Object
Returns the value of attribute email.
-
#first_name ⇒ Object
Returns the value of attribute first_name.
-
#job_title ⇒ Object
Returns the value of attribute job_title.
-
#last_name ⇒ Object
Returns the value of attribute last_name.
-
#phone ⇒ Object
Returns the value of attribute phone.
-
#website ⇒ Object
Returns the value of attribute website.
Instance Method Summary collapse
- #create ⇒ Object
-
#initialize ⇒ Lead
constructor
A new instance of Lead.
Constructor Details
#initialize ⇒ Lead
Returns a new instance of Lead.
11 12 13 |
# File 'lib/sf_integrator/lead.rb', line 11 def initialize @client = Restforce.new(SfIntegrator::Integrator.configs.to_hash) end |
Instance Attribute Details
#client ⇒ Object
Returns the value of attribute client.
9 10 11 |
# File 'lib/sf_integrator/lead.rb', line 9 def client @client end |
#company ⇒ Object
Returns the value of attribute company.
9 10 11 |
# File 'lib/sf_integrator/lead.rb', line 9 def company @company end |
#email ⇒ Object
Returns the value of attribute email.
9 10 11 |
# File 'lib/sf_integrator/lead.rb', line 9 def email @email end |
#first_name ⇒ Object
Returns the value of attribute first_name.
9 10 11 |
# File 'lib/sf_integrator/lead.rb', line 9 def first_name @first_name end |
#job_title ⇒ Object
Returns the value of attribute job_title.
9 10 11 |
# File 'lib/sf_integrator/lead.rb', line 9 def job_title @job_title end |
#last_name ⇒ Object
Returns the value of attribute last_name.
9 10 11 |
# File 'lib/sf_integrator/lead.rb', line 9 def last_name @last_name end |
#phone ⇒ Object
Returns the value of attribute phone.
9 10 11 |
# File 'lib/sf_integrator/lead.rb', line 9 def phone @phone end |
#website ⇒ Object
Returns the value of attribute website.
9 10 11 |
# File 'lib/sf_integrator/lead.rb', line 9 def website @website end |
Instance Method Details
#create ⇒ Object
15 16 17 18 |
# File 'lib/sf_integrator/lead.rb', line 15 def create params = build_params client.create('Lead', params) end |