forest_liana 1.1.19 → 1.1.20
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/services/forest_liana/smart_collection.rb +12 -0
- data/lib/forest_liana.rb +2 -0
- data/lib/forest_liana/engine.rb +6 -4
- data/lib/forest_liana/version.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9ddcfda22c4ff09d0c572f50c1f9b915aaf2c594
|
4
|
+
data.tar.gz: 6e446ba8d2b87adbeaf577b444d9aa3bb962fdd7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: de6db21eb97e3be4c111d451df11fc8e16a70047bb7caa127206a6498128ced2310e4d4926d5a9a2556de2daab19c25f064ede67b8cd89299cef5877198feeb4
|
7
|
+
data.tar.gz: 821e98ce6b1e834d42e86b38e39132b764b5a956919628e257ba92308a50e160921d99a5f5553d9176a2cacaead96133f66ade8b76edd185d9abbc3387a60f7a
|
data/lib/forest_liana.rb
CHANGED
data/lib/forest_liana/engine.rb
CHANGED
@@ -9,6 +9,10 @@ module ForestLiana
|
|
9
9
|
isolate_namespace ForestLiana
|
10
10
|
logger = Logger.new(STDOUT)
|
11
11
|
|
12
|
+
initializer 'forest_liana.require_all' do |app|
|
13
|
+
Dir["#{app.root}/app/models/forest/*.rb"].each {|file| require file }
|
14
|
+
end
|
15
|
+
|
12
16
|
config.middleware.insert_before 0, 'Rack::Cors' do
|
13
17
|
allow do
|
14
18
|
origins 'http://localhost:4200', 'https://www.forestadmin.com',
|
@@ -37,22 +41,20 @@ module ForestLiana
|
|
37
41
|
forest_url = ENV['FOREST_URL'] ||
|
38
42
|
'https://forestadmin-server.herokuapp.com';
|
39
43
|
|
40
|
-
apimaps = []
|
41
44
|
SchemaUtils.tables_names.map do |table_name|
|
42
45
|
model = SchemaUtils.find_model_from_table_name(table_name)
|
43
46
|
if model.try(:table_exists?)
|
44
|
-
|
47
|
+
ForestLiana.apimap << SchemaAdapter.new(model).perform
|
45
48
|
end
|
46
49
|
end
|
47
50
|
|
48
51
|
liana_version = Gem::Specification.find_by_name('forest_liana')
|
49
52
|
.version.to_s
|
50
|
-
json = JSONAPI::Serializer.serialize(
|
53
|
+
json = JSONAPI::Serializer.serialize(ForestLiana.apimap, {
|
51
54
|
is_collection: true,
|
52
55
|
meta: { liana: 'forest-rails', liana_version: liana_version }
|
53
56
|
})
|
54
57
|
|
55
|
-
|
56
58
|
uri = URI.parse("#{forest_url}/forest/apimaps")
|
57
59
|
http = Net::HTTP.new(uri.host, uri.port)
|
58
60
|
http.use_ssl = true if forest_url.start_with?('https')
|
data/lib/forest_liana/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: forest_liana
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.20
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Sandro Munda
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-12-
|
11
|
+
date: 2015-12-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -147,6 +147,7 @@ files:
|
|
147
147
|
- app/services/forest_liana/schema_adapter.rb
|
148
148
|
- app/services/forest_liana/schema_utils.rb
|
149
149
|
- app/services/forest_liana/search_query_builder.rb
|
150
|
+
- app/services/forest_liana/smart_collection.rb
|
150
151
|
- app/services/forest_liana/stripe_cards_getter.rb
|
151
152
|
- app/services/forest_liana/stripe_invoices_getter.rb
|
152
153
|
- app/services/forest_liana/stripe_payment_refunder.rb
|