rails_db 2.0.5 → 2.0.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +2 -1
- data/lib/rails_db.rb +2 -1
- data/lib/rails_db/connection.rb +3 -1
- data/lib/rails_db/version.rb +1 -1
- data/rails_db.gemspec +1 -0
- metadata +16 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a93993de667f0685489cb8f5bfc808c6dd38f06faa4ba31e5e6f94c087075464
|
4
|
+
data.tar.gz: 222191ecaf961bf0604b79b1151e7104f9845241eac0ed0f4a19e5810699c129
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d73372834d7db11c241b11540c063f191cc5d7df1ee21b30a0f554fee59dc6a6a1120b97673b405ba1ee3f1b5e83380382291de46f5a9b6ef93895804c07125b
|
7
|
+
data.tar.gz: 552b70ffd82d6455df32444cbb400bbe0d94bc01e588e982c8c3bcc5416d47fb460eab494a913a6a083fac6c39da089936f7af4c95cb67bf43b869a58cc66a32
|
data/Gemfile.lock
CHANGED
data/lib/rails_db.rb
CHANGED
@@ -3,6 +3,7 @@ require 'codemirror-rails'
|
|
3
3
|
require 'terminal-table'
|
4
4
|
require 'csv'
|
5
5
|
require 'simple_form'
|
6
|
+
require 'active_record'
|
6
7
|
require 'ransack'
|
7
8
|
require 'kaminari'
|
8
9
|
|
@@ -63,4 +64,4 @@ require_relative "libs"
|
|
63
64
|
require_relative "rails_db/engine"
|
64
65
|
require_relative "rails/routes"
|
65
66
|
require_relative "ext/simple_form_ext"
|
66
|
-
require_relative "ext/ransack_ext"
|
67
|
+
require_relative "ext/ransack_ext"
|
data/lib/rails_db/connection.rb
CHANGED
@@ -3,6 +3,8 @@ module RailsDb
|
|
3
3
|
|
4
4
|
def connection
|
5
5
|
ActiveRecord::Base.connection
|
6
|
+
rescue ActiveRecord::ConnectionNotEstablished
|
7
|
+
ActiveRecord::Base.establish_connection(Rails.application.config.database_configuration[Rails.env]).connection
|
6
8
|
end
|
7
9
|
|
8
10
|
def columns
|
@@ -22,4 +24,4 @@ module RailsDb
|
|
22
24
|
end
|
23
25
|
|
24
26
|
end
|
25
|
-
end
|
27
|
+
end
|
data/lib/rails_db/version.rb
CHANGED
data/rails_db.gemspec
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rails_db
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Igor Kasyanchuk
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-01-
|
11
|
+
date: 2019-01-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -66,6 +66,20 @@ dependencies:
|
|
66
66
|
- - ">="
|
67
67
|
- !ruby/object:Gem::Version
|
68
68
|
version: 4.0.1
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: activerecord
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - ">="
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '0'
|
76
|
+
type: :runtime
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - ">="
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '0'
|
69
83
|
- !ruby/object:Gem::Dependency
|
70
84
|
name: ransack
|
71
85
|
requirement: !ruby/object:Gem::Requirement
|