salesforceintegration 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +3 -2
- data/lib/salesforceintegration/version.rb +1 -1
- data/lib/salesforceintegration.rb +2 -0
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5687d322f96a2cd170f6c120484de8dbc34aa74a
|
4
|
+
data.tar.gz: fe99d8042a82d80fde89707deaaae7f30dc4f1ae
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2a8244aa943dba73a0527789522b02421cf4f1b59f9b7037b65bb3bbf560c8a274a7a267adcc5f9837a377ac3c637ad8fb742b1b786c19767bbcc1f99c8c6e33
|
7
|
+
data.tar.gz: 0d4a96aef7537bb69fad98153c87e38c044715722c0555e6b0b9953f91f1f1acd381ece5dbdbbb2cd4982d57756c8da2235820e5ec7c85d04f3998a219fd9cc4
|
data/README.md
CHANGED
@@ -23,7 +23,7 @@ Or install it yourself as:
|
|
23
23
|
First you need to create a salesforce instance:
|
24
24
|
|
25
25
|
```ruby
|
26
|
-
salesforceintegration = SalesforceIntegration.new("client_id", "client_secret", "host", "username", "password")
|
26
|
+
salesforceintegration = SalesforceIntegration::SalesforceIntegrationLead.new("client_id", "client_secret", "host", "username", "password")
|
27
27
|
```
|
28
28
|
* client_id and client_secret: See this [link](https://auth0.com/docs/connections/social/salesforce)
|
29
29
|
* host: Use login.salesforce.com or test.salesforce.com if using a sandbox
|
@@ -36,6 +36,7 @@ After salesforceintegration initialized you only need pass the lead's data
|
|
36
36
|
```ruby
|
37
37
|
salesforceintegration.create_lead_on_salesforce("first_name", "last_name", "email", "company", "job_title", "phone", "website")
|
38
38
|
```
|
39
|
+
This method returns the lead's ID
|
39
40
|
|
40
41
|
## Development
|
41
42
|
|
@@ -45,7 +46,7 @@ To install this gem onto your local machine, run `bundle exec rake install`. To
|
|
45
46
|
|
46
47
|
## Contributing
|
47
48
|
|
48
|
-
Bug reports and pull requests are welcome on GitHub at https://github.com/karlamaria/
|
49
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/karlamaria/salesforceintegration. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](contributor-covenant.org) code of conduct.
|
49
50
|
|
50
51
|
|
51
52
|
## License
|
@@ -15,6 +15,7 @@ module SalesforceIntegration
|
|
15
15
|
end
|
16
16
|
|
17
17
|
#TODO: Permitir associar a contas
|
18
|
+
#TODO: Validar campos
|
18
19
|
def create_lead_on_salesforce(first_name, last_name, email, company, job_title, phone, website)
|
19
20
|
lead = Lead.new
|
20
21
|
|
@@ -32,6 +33,7 @@ module SalesforceIntegration
|
|
32
33
|
lead['IsConverted'] = false
|
33
34
|
lead['IsUnreadByOwner'] = true
|
34
35
|
lead.save
|
36
|
+
lead.Id
|
35
37
|
end
|
36
38
|
end
|
37
39
|
end
|