superstore 2.1.1 → 2.1.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +24 -0
- data/lib/superstore/adapters/jsonb_adapter.rb +1 -1
- data/lib/superstore/scope/finder_methods.rb +2 -1
- data/superstore.gemspec +1 -1
- data/test/unit/scope/finder_methods_test.rb +5 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d340fd400d34afc915c915eaccf658743639dd74
|
4
|
+
data.tar.gz: 8c4f9958333d8ffd33d4777c21f7cfee409dddd5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 86c9c2e4e6a187f62402eae73914f7f6d0d653366d16a592617a424f33ee9f237cf6e467bb35d5f19f30bb702d2d081f9ca0b394c8ea31d04037ed633567cd4f
|
7
|
+
data.tar.gz: cf54fbfccda08f8c056b8316c8c874287c8c2aa524f78e0372be68f040a354f6f664cfc22bc4be1063437870817e179c015e8818bb4e717ec6eb58aa70027ec3
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,27 @@
|
|
1
|
+
# 2.1.1
|
2
|
+
|
3
|
+
Released 2016-04-01.
|
4
|
+
|
5
|
+
## New Features
|
6
|
+
|
7
|
+
* Added a `to_ids` scoped method.
|
8
|
+
|
9
|
+
# 2.1.0
|
10
|
+
|
11
|
+
Released 2016-02-12.
|
12
|
+
|
13
|
+
## Changed
|
14
|
+
|
15
|
+
* Associations are now ActiveRecord-based (#17)
|
16
|
+
|
17
|
+
# 2.0.1
|
18
|
+
|
19
|
+
Released 2016-02-12.
|
20
|
+
|
21
|
+
## Fixed
|
22
|
+
|
23
|
+
* `has_many` was not working correctly.
|
24
|
+
|
1
25
|
# 2.0.0
|
2
26
|
|
3
27
|
Released 2015-12-18.
|
@@ -105,7 +105,7 @@ module Superstore
|
|
105
105
|
end
|
106
106
|
|
107
107
|
def to_ids(scope)
|
108
|
-
statement = QueryBuilder.new(self, scope.select(
|
108
|
+
statement = QueryBuilder.new(self, scope.select(primary_key_column)).to_query
|
109
109
|
connection.select_values(statement)
|
110
110
|
end
|
111
111
|
|
data/superstore.gemspec
CHANGED
@@ -27,6 +27,11 @@ class Superstore::FinderMethodsTest < Superstore::TestCase
|
|
27
27
|
assert_equal [first_issue, second_issue], Issue.find([first_issue.id, second_issue.id])
|
28
28
|
end
|
29
29
|
|
30
|
+
test 'find with nil ids' do
|
31
|
+
Issue.create
|
32
|
+
assert_equal [], Issue.find([nil])
|
33
|
+
end
|
34
|
+
|
30
35
|
test 'find_by_id' do
|
31
36
|
Issue.create.tap do |issue|
|
32
37
|
assert_equal issue, Issue.find_by_id(issue.id)
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: superstore
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.1.
|
4
|
+
version: 2.1.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Michael Koziarski
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2016-04
|
12
|
+
date: 2016-05-04 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: activemodel
|