activerecord-time 0.19.0 → 0.20.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/activerecord-time.gemspec +1 -1
- data/lib/activerecord-time/extension.rb +3 -4
- data/lib/activerecord-time/version.rb +1 -1
- data/lib/time_of_day.rb +4 -0
- metadata +7 -13
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b4fd61f3d4336ca6066bf7c370cc9b6ef79197a8a223c90c5988df700f4766f7
|
4
|
+
data.tar.gz: 0c718820286900bcb68d4ca0a7fbcf138d9f2333335ef8a136e81421fb67f894
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0b6cdf1f3d47679076e9e20ff5504ddd1b0322508e76431d7e27050f0d6b9e0cdddaef424cc3eb70cebbd4dda78fde8240864737ae011b1b402f42446a377bf4
|
7
|
+
data.tar.gz: 0a3a67c6781ca27f19ca9814835f44389756625d13c69be4ca291c09e69fb602b33a05927af0b860a5c21814a1856473b3a7f5cc79e26b915c2fcbc89d3ca151
|
data/activerecord-time.gemspec
CHANGED
@@ -23,7 +23,7 @@ Gem::Specification.new do |gem|
|
|
23
23
|
gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
|
24
24
|
gem.require_paths = %w[lib]
|
25
25
|
|
26
|
-
gem.add_runtime_dependency 'activerecord', '
|
26
|
+
gem.add_runtime_dependency 'activerecord', '~>7.0'
|
27
27
|
|
28
28
|
if defined? JRUBY_VERSION
|
29
29
|
gem.add_development_dependency 'activerecord-jdbcpostgresql-adapter'
|
@@ -5,13 +5,13 @@ require 'active_record/connection_adapters/abstract/quoting'
|
|
5
5
|
module Activerecord
|
6
6
|
module Time
|
7
7
|
module Quoting
|
8
|
-
def
|
8
|
+
def quote(value)
|
9
9
|
return "'#{value}'" if value.is_a?(TimeOfDay)
|
10
10
|
|
11
11
|
super(value)
|
12
12
|
end
|
13
13
|
|
14
|
-
def
|
14
|
+
def type_cast(value)
|
15
15
|
return value.to_s if value.is_a?(TimeOfDay)
|
16
16
|
|
17
17
|
super(value)
|
@@ -20,8 +20,7 @@ module Activerecord
|
|
20
20
|
end
|
21
21
|
end
|
22
22
|
|
23
|
-
|
24
|
-
ActiveRecord::ConnectionAdapters::AbstractAdapter.prepend Activerecord::Time::Quoting
|
23
|
+
ActiveRecord::ConnectionAdapters::Quoting.prepend Activerecord::Time::Quoting
|
25
24
|
|
26
25
|
module ActiveRecord
|
27
26
|
module Type
|
data/lib/time_of_day.rb
CHANGED
metadata
CHANGED
@@ -1,35 +1,29 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: activerecord-time
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.20.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Uwe Kubosch
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2022-03-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activerecord
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- - "
|
18
|
-
- !ruby/object:Gem::Version
|
19
|
-
version: '5.1'
|
20
|
-
- - "<"
|
17
|
+
- - "~>"
|
21
18
|
- !ruby/object:Gem::Version
|
22
|
-
version: '7'
|
19
|
+
version: '7.0'
|
23
20
|
type: :runtime
|
24
21
|
prerelease: false
|
25
22
|
version_requirements: !ruby/object:Gem::Requirement
|
26
23
|
requirements:
|
27
|
-
- - "
|
28
|
-
- !ruby/object:Gem::Version
|
29
|
-
version: '5.1'
|
30
|
-
- - "<"
|
24
|
+
- - "~>"
|
31
25
|
- !ruby/object:Gem::Version
|
32
|
-
version: '7'
|
26
|
+
version: '7.0'
|
33
27
|
- !ruby/object:Gem::Dependency
|
34
28
|
name: pg
|
35
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -195,7 +189,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
195
189
|
- !ruby/object:Gem::Version
|
196
190
|
version: '0'
|
197
191
|
requirements: []
|
198
|
-
rubygems_version: 3.
|
192
|
+
rubygems_version: 3.3.7
|
199
193
|
signing_key:
|
200
194
|
specification_version: 4
|
201
195
|
summary: A handler for storing TimeOfDay objects in ActiveRecord objects as sql time
|