rotulus 0.2.2 → 0.2.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -1
- data/lib/rotulus/page.rb +1 -1
- data/lib/rotulus/version.rb +1 -1
- metadata +5 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 15fae43a1fc07b2c268c1604c065a12f0d2288d733219aa563348019a872d7a0
|
4
|
+
data.tar.gz: ca8548477eee36f6bed018d8ec20d5dd5217f74d36954f13b4e243fbaee6755e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f9d0e4611e800688f8c10ad7347043a07e7358f79a4254ecac6359a1f5f4101d323cfe0b21d45b363984cdc681e3ffc8b8b9587311e96553ab952eb76016792b
|
7
|
+
data.tar.gz: a3240e33d45cd4360c4235e94860558c584a9f1f373c9ad7451ad9d819c2616f5a2e2146bef0449b716b846144ee87c19e92596c2b39c13e34bef254f49c50af
|
data/CHANGELOG.md
CHANGED
@@ -5,4 +5,7 @@
|
|
5
5
|
- Drop unnecessary ORDER BY columns following a non-nullable and distinct column.
|
6
6
|
|
7
7
|
## 0.2.2
|
8
|
-
- Raise error when there is no non-nullable and distinct column in the configured order definition.
|
8
|
+
- Raise error when there is no non-nullable and distinct column in the configured order definition.
|
9
|
+
|
10
|
+
## 0.2.3
|
11
|
+
- Replace any existing order defined on the given ar_relation
|
data/lib/rotulus/page.rb
CHANGED
@@ -209,7 +209,7 @@ module Rotulus
|
|
209
209
|
return @loaded_records unless @loaded_records.nil?
|
210
210
|
|
211
211
|
@loaded_records = ar_relation.where(cursor&.sql)
|
212
|
-
.
|
212
|
+
.reorder(order_by_sql)
|
213
213
|
.limit(limit + 1)
|
214
214
|
.select(*select_columns)
|
215
215
|
return @loaded_records.to_a unless paged_back?
|
data/lib/rotulus/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rotulus
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Uy Jayson B
|
@@ -64,8 +64,8 @@ dependencies:
|
|
64
64
|
- - ">="
|
65
65
|
- !ruby/object:Gem::Version
|
66
66
|
version: '0'
|
67
|
-
description: Cursor-based pagination for
|
68
|
-
|
67
|
+
description: Cursor-based pagination for Rails/ActiveRecord apps with multiple column
|
68
|
+
sort and custom cursor format support for a more stable and predictable pagination.
|
69
69
|
email:
|
70
70
|
- uy.json.dev@gmail.com
|
71
71
|
executables: []
|
@@ -116,6 +116,6 @@ requirements: []
|
|
116
116
|
rubygems_version: 3.1.4
|
117
117
|
signing_key:
|
118
118
|
specification_version: 4
|
119
|
-
summary: Cursor-based
|
120
|
-
|
119
|
+
summary: Cursor-based Rails/ActiveRecord pagination with multiple column sort and
|
120
|
+
custom cursor token format support.
|
121
121
|
test_files: []
|