deleted_at 0.2.4 → 0.2.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/deleted_at.gemspec +2 -0
- data/lib/deleted_at.rb +6 -1
- data/lib/deleted_at/railtie.rb +3 -6
- data/lib/deleted_at/version.rb +1 -1
- metadata +30 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7febb48c23b7e284e0dfe09367734ff47a712577
|
4
|
+
data.tar.gz: 787df5400cfdbdd7306e73125521e3c10af30aca
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 64aca7ab8a14d6bdb4479ac934e2f35e631715880a9a257ce722eb1398b9e03e3f74e16b8998736a3d1f714c9fe57b6b9eb18abc420f2eb598a0d87fb70b217e
|
7
|
+
data.tar.gz: 99642de01acec8e084b82d5967d06e677f11e1cf9dc10e816336d0568b39c5336212391fac550cd600d188833651c2a5e3b1e78b799e8d5112faa6d9d31af683
|
data/deleted_at.gemspec
CHANGED
@@ -31,6 +31,8 @@ Gem::Specification.new do |spec|
|
|
31
31
|
spec.required_ruby_version = '>= 2.0'
|
32
32
|
|
33
33
|
spec.add_dependency "activerecord", "~> 4.2"
|
34
|
+
spec.add_dependency "railties", "~> 4.2"
|
35
|
+
spec.add_dependency "scenic", "~> 1.3"
|
34
36
|
spec.add_dependency 'request_store', '~> 1.1', '>= 1.1'
|
35
37
|
|
36
38
|
spec.add_development_dependency "bundler", "~> 1.13"
|
data/lib/deleted_at.rb
CHANGED
@@ -1,8 +1,13 @@
|
|
1
1
|
require "deleted_at/version"
|
2
|
-
require 'deleted_at/railtie'
|
2
|
+
require 'deleted_at/railtie'
|
3
|
+
require 'deleted_at/views'
|
3
4
|
|
4
5
|
module DeletedAt
|
5
6
|
|
7
|
+
def self.load
|
8
|
+
::ActiveRecord::Relation.send :include, DeletedAt::ActiveRecord::Relation
|
9
|
+
::ActiveRecord::Base.send :include, DeletedAt::ActiveRecord::Base
|
10
|
+
end
|
6
11
|
|
7
12
|
def self.install(model)
|
8
13
|
DeletedAt::Views.install_present_view(model)
|
data/lib/deleted_at/railtie.rb
CHANGED
@@ -1,16 +1,13 @@
|
|
1
1
|
require 'rails/railtie'
|
2
|
-
require 'action_controller'
|
3
|
-
require 'action_controller/railtie'
|
4
2
|
require 'deleted_at/active_record/base'
|
5
3
|
require 'deleted_at/active_record/relation'
|
6
4
|
|
7
5
|
module DeletedAt
|
8
|
-
class Railtie <
|
6
|
+
class Railtie < Rails::Railtie
|
9
7
|
|
10
|
-
initializer 'deleted_at.
|
8
|
+
initializer 'deleted_at.load' do
|
11
9
|
ActiveSupport.on_load(:active_record) do
|
12
|
-
|
13
|
-
::ActiveRecord::Base.send :include, DeletedAt::ActiveRecord::Base
|
10
|
+
DeletedAt.load
|
14
11
|
end
|
15
12
|
end
|
16
13
|
|
data/lib/deleted_at/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: deleted_at
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dale Stevens
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-03-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activerecord
|
@@ -24,6 +24,34 @@ dependencies:
|
|
24
24
|
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '4.2'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: railties
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '4.2'
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '4.2'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: scenic
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - "~>"
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '1.3'
|
48
|
+
type: :runtime
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - "~>"
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '1.3'
|
27
55
|
- !ruby/object:Gem::Dependency
|
28
56
|
name: request_store
|
29
57
|
requirement: !ruby/object:Gem::Requirement
|