forest_admin_rails 1.0.0.pre.beta.44 → 1.0.0.pre.beta.46
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d4ee344821fe2af7186c5d18b1a7ab549ff04ae9a04f6db9189bc8345323603b
|
4
|
+
data.tar.gz: 2f8161ee52c197b15a682c63662162602c3c5995c6342a3daa231b3181fb5302
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2c9d3b56548934619019e192486b0f8ca7fb9facb16810075bf57395b7bece1cbfe97d12d0306e6af88855849f287f12739389a26e5d1f2d2f4a841faa6a4658
|
7
|
+
data.tar.gz: 48e506d506ace9fb049d5bfc6a4cd8b3fffdca57577b13ed810f073db1ddd467b38b3e0fbaf171b98d8211c6c252de670341ec6fba81c82299db35164db48bfd
|
@@ -47,10 +47,10 @@ module ForestAdminRails
|
|
47
47
|
}
|
48
48
|
|
49
49
|
data[:errors][0][:data] = exception.try(:data)
|
50
|
+
end
|
50
51
|
|
51
|
-
|
52
|
-
|
53
|
-
# end
|
52
|
+
unless Facades::Container.cache(:is_production)
|
53
|
+
ForestAdminAgent::Facades::Container.logger.log('Debug', exception.full_message)
|
54
54
|
end
|
55
55
|
|
56
56
|
render json: data, status: exception.try(:status)
|
data/config/routes.rb
CHANGED
@@ -1,5 +1,7 @@
|
|
1
1
|
ForestAdminRails::Engine.routes.draw do
|
2
|
-
|
3
|
-
|
2
|
+
Rails.error.handle(ForestAdminDatasourceToolkit::Exceptions::ForestException) do
|
3
|
+
ForestAdminAgent::Http::Router.routes.each do |name, agent_route|
|
4
|
+
match agent_route[:uri], to: 'forest#index', via: agent_route[:method], as: name, route_alias: name
|
5
|
+
end
|
4
6
|
end
|
5
7
|
end
|
@@ -22,11 +22,19 @@ module ForestAdminRails
|
|
22
22
|
class Engine < ::Rails::Engine
|
23
23
|
isolate_namespace ForestAdminRails
|
24
24
|
|
25
|
+
extend ActiveSupport::Concern
|
26
|
+
|
27
|
+
initializer 'forest_admin_rails.error_subscribe' do
|
28
|
+
Rails.error.subscribe(ForestAdminErrorSubscriber.new)
|
29
|
+
end
|
30
|
+
|
25
31
|
config.after_initialize do
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
32
|
+
Rails.error.handle(ForestAdminDatasourceToolkit::Exceptions::ForestException) do
|
33
|
+
agent_factory = ForestAdminAgent::Builder::AgentFactory.instance
|
34
|
+
agent_factory.setup(ForestAdminRails.config)
|
35
|
+
load_configuration
|
36
|
+
load_cors
|
37
|
+
end
|
30
38
|
end
|
31
39
|
|
32
40
|
def load_configuration
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: forest_admin_rails
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.0.pre.beta.
|
4
|
+
version: 1.0.0.pre.beta.46
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Matthieu
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2024-05-
|
12
|
+
date: 2024-05-15 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: dry-configurable
|
@@ -68,6 +68,7 @@ files:
|
|
68
68
|
- Rakefile
|
69
69
|
- app/controllers/forest_admin_rails/forest_controller.rb
|
70
70
|
- app/helpers/forest_admin_rails/application_helper.rb
|
71
|
+
- config/initializers/forest_admin_error_subscriber.rb
|
71
72
|
- config/routes.rb
|
72
73
|
- lib/forest_admin_rails.rb
|
73
74
|
- lib/forest_admin_rails/engine.rb
|