maestrano-connector-rails 0.3.0 → 0.3.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/VERSION +1 -1
- data/app/jobs/maestrano/connector/rails/synchronization_job.rb +3 -2
- data/app/models/maestrano/connector/rails/concerns/entity.rb +2 -2
- data/lib/generators/connector/templates/complex_entity_example/contact.rb +1 -1
- data/lib/generators/connector/templates/complex_entity_example/lead.rb +1 -1
- data/lib/generators/connector/templates/complex_entity_example/person.rb +1 -1
- data/maestrano-connector-rails.gemspec +2 -2
- 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: 7aacc2acd6c8b4ae959bc04f22610a0579eac001
|
4
|
+
data.tar.gz: d0291c5cdc84f85e25e11a845080792e420b27dc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 237c78f0dbf7fcf046858a580eda157c0d2a0629dfbc03048dc79a3218168c2c196a5f6efb308f1a4e4e719b07294d9b8e0d6bc729735280b2581c81f66f48ab
|
7
|
+
data.tar.gz: bc8df72fe6d4e8d81f84b4da628c72011e56d04344053f58ad9dc475ccf5c596fa39f78265fad03ab8badc8eef2ac5cebd95cbabd673c72b7a3a14f433e158f0
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.3.
|
1
|
+
0.3.1
|
@@ -49,13 +49,14 @@ module Maestrano::Connector::Rails
|
|
49
49
|
def sync_entity(entity_name, organization, connec_client, external_client, last_synchronization, opts)
|
50
50
|
entity_instance = "Entities::#{entity_name.titleize.split.join}".constantize.new
|
51
51
|
|
52
|
-
|
52
|
+
|
53
|
+
entity_instance.before_sync(connec_client, external_client, last_synchronization, organization, opts)
|
53
54
|
external_entities = entity_instance.get_external_entities(external_client, last_synchronization, organization, opts)
|
54
55
|
connec_entities = entity_instance.get_connec_entities(connec_client, last_synchronization, organization, opts)
|
55
56
|
mapped_entities = entity_instance.consolidate_and_map_data(connec_entities, external_entities, organization, opts)
|
56
57
|
entity_instance.push_entities_to_external(external_client, mapped_entities[:connec_entities], organization)
|
57
58
|
entity_instance.push_entities_to_connec(connec_client, mapped_entities[:external_entities], organization)
|
58
|
-
entity_instance.after_sync(connec_client, external_client, organization, opts)
|
59
|
+
entity_instance.after_sync(connec_client, external_client, last_synchronization, organization, opts)
|
59
60
|
end
|
60
61
|
end
|
61
62
|
end
|
@@ -341,11 +341,11 @@ module Maestrano::Connector::Rails::Concerns::Entity
|
|
341
341
|
# ----------------------------------------------
|
342
342
|
# After and before sync
|
343
343
|
# ----------------------------------------------
|
344
|
-
def before_sync(connec_client, external_client, organization)
|
344
|
+
def before_sync(connec_client, external_client, last_synchronization, organization, opts)
|
345
345
|
# Does nothing by default
|
346
346
|
end
|
347
347
|
|
348
|
-
def after_sync(connec_client, external_client, organization)
|
348
|
+
def after_sync(connec_client, external_client, last_synchronization, organization, opts)
|
349
349
|
# Does nothing by default
|
350
350
|
end
|
351
351
|
|
@@ -16,7 +16,7 @@
|
|
16
16
|
# when 'person'
|
17
17
|
# Entities::SubEntities::LeadMapper.denormalize(entity).merge(is_lead: true)
|
18
18
|
# else
|
19
|
-
# raise "Impossible mapping from #{self.entity_name} to #{name}"
|
19
|
+
# raise "Impossible mapping from #{self.class.entity_name} to #{name}"
|
20
20
|
# end
|
21
21
|
# end
|
22
22
|
|
@@ -2,11 +2,11 @@
|
|
2
2
|
# DO NOT EDIT THIS FILE DIRECTLY
|
3
3
|
# Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
|
4
4
|
# -*- encoding: utf-8 -*-
|
5
|
-
# stub: maestrano-connector-rails 0.3.
|
5
|
+
# stub: maestrano-connector-rails 0.3.1 ruby lib
|
6
6
|
|
7
7
|
Gem::Specification.new do |s|
|
8
8
|
s.name = "maestrano-connector-rails"
|
9
|
-
s.version = "0.3.
|
9
|
+
s.version = "0.3.1"
|
10
10
|
|
11
11
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
12
12
|
s.require_paths = ["lib"]
|