query_helper 0.2.17 → 0.2.18
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/lib/query_helper.rb +1 -1
- data/lib/query_helper/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 66a48754e9a1e5fcf794039299fc18c477bdda5cc334e09988e24a73cd5dc0b7
|
4
|
+
data.tar.gz: 2f1aa69978a6b1ccffca16f82b7617e32bbb5e819460782ae566de439a694043
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0b09be775d91bb839e8c15da2d166bc33ac6bbb1ed46b00f2bd6a52962d06999383797776411c26e86a28e082221fdb37f28562aa0d8d28f91087bf3971ab6f7
|
7
|
+
data.tar.gz: 77ec774a1a2a49b4ac90deb066321488ee7a4a2884bc149107b664a54eb31a955d109eeef9ce6c8a22b61afd66ffc06889382d50db8081e69b1b1432c6aa28b9
|
data/Gemfile.lock
CHANGED
data/lib/query_helper.rb
CHANGED
@@ -184,7 +184,7 @@ class QueryHelper
|
|
184
184
|
results_per_page = @per_page || count
|
185
185
|
results_page = @page || 1
|
186
186
|
|
187
|
-
total_pages = (count/(results_per_page.nonzero? || 1).to_f).ceil
|
187
|
+
total_pages = (count.to_i/(results_per_page.nonzero? || 1).to_f).ceil
|
188
188
|
next_page = results_page + 1 if results_page.between?(1, total_pages - 1)
|
189
189
|
previous_page = results_page - 1 if results_page.between?(2, total_pages)
|
190
190
|
first_page = results_page == 1
|
data/lib/query_helper/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: query_helper
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.18
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Evan McDaniel
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-11-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|