activerecord-postgis-adapter 4.1.0 → 4.1.1
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: e49c16a53afd0537f375be4d46940f25bdde63b998d430d2c5f874a11bc63db0
|
4
|
+
data.tar.gz: b5343a0e8790a65b76e3d74177e0cee4ddca51e1538fe17c7fb1506db691834c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0fb4fa64b34f707cffdb9f8e2d6b9366013250aae1550229e65d684ca57b69d0959b5ae791df04fbe5cb3a611c505db5956d91a848c32746fa6b337bea33e973
|
7
|
+
data.tar.gz: d206ab27ba8dd26cebfe31a69908fb6803a2ceb16657090126abae2c9c274721d6ca4fbc10c09ef16b292d938be9dd47b36f2609ba5fb4111d0d23e8de7c03dd
|
@@ -6,7 +6,7 @@ module ActiveRecord
|
|
6
6
|
# pass table_name to #new_column
|
7
7
|
def columns(table_name)
|
8
8
|
# Limit, precision, and scale are all handled by the superclass.
|
9
|
-
column_definitions(table_name).map do |column_name, type, default, notnull, oid, fmod, collation|
|
9
|
+
column_definitions(table_name).map do |column_name, type, default, notnull, oid, fmod, collation, comment|
|
10
10
|
oid = oid.to_i
|
11
11
|
fmod = fmod.to_i
|
12
12
|
type_metadata = fetch_type_metadata(column_name, type, oid, fmod)
|
@@ -14,12 +14,12 @@ module ActiveRecord
|
|
14
14
|
default_value = extract_value_from_default(default)
|
15
15
|
|
16
16
|
default_function = extract_default_function(default_value, default)
|
17
|
-
new_column(table_name, column_name, default_value, cast_type, type_metadata, !notnull, default_function, collation)
|
17
|
+
new_column(table_name, column_name, default_value, cast_type, type_metadata, !notnull, default_function, collation, comment)
|
18
18
|
end
|
19
19
|
end
|
20
20
|
|
21
21
|
# override
|
22
|
-
def new_column(table_name, column_name, default, cast_type, sql_type_metadata = nil, null = true, default_function = nil, collation = nil)
|
22
|
+
def new_column(table_name, column_name, default, cast_type, sql_type_metadata = nil, null = true, default_function = nil, collation = nil, comment = nil)
|
23
23
|
# JDBC gets true/false in Rails 4, where other platforms get 't'/'f' strings.
|
24
24
|
if null.is_a?(String)
|
25
25
|
null = (null == "t")
|
@@ -34,6 +34,7 @@ module ActiveRecord
|
|
34
34
|
table_name,
|
35
35
|
default_function,
|
36
36
|
collation,
|
37
|
+
comment,
|
37
38
|
cast_type,
|
38
39
|
column_info)
|
39
40
|
end
|
@@ -8,7 +8,7 @@ module ActiveRecord # :nodoc:
|
|
8
8
|
# cast_type example classes:
|
9
9
|
# OID::Spatial
|
10
10
|
# OID::Integer
|
11
|
-
def initialize(name, default, sql_type_metadata = nil, null = true, table_name = nil, default_function = nil, collation = nil, cast_type = nil, opts = nil)
|
11
|
+
def initialize(name, default, sql_type_metadata = nil, null = true, table_name = nil, default_function = nil, collation = nil, comment = nil, cast_type = nil, opts = nil)
|
12
12
|
@cast_type = cast_type
|
13
13
|
@geographic = !!(sql_type_metadata.sql_type =~ /geography\(/i)
|
14
14
|
if opts
|
@@ -29,7 +29,7 @@ module ActiveRecord # :nodoc:
|
|
29
29
|
# @geometric_type = geo_type_from_sql_type(sql_type)
|
30
30
|
build_from_sql_type(sql_type_metadata.sql_type)
|
31
31
|
end
|
32
|
-
super(name, default, sql_type_metadata, null, table_name, default_function, collation)
|
32
|
+
super(name, default, sql_type_metadata, null, table_name, default_function, collation, comment: comment)
|
33
33
|
if spatial?
|
34
34
|
if @srid
|
35
35
|
@limit = { srid: @srid, type: to_type_name(geometric_type) }
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: activerecord-postgis-adapter
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.1.
|
4
|
+
version: 4.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Daniel Azuma, Tee Parham
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-12-
|
11
|
+
date: 2017-12-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activerecord
|