nazrin 1.0.0 → 1.0.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
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d560f4c38f13496421fa20bb64e450dbee131d2e
|
4
|
+
data.tar.gz: b498261e0352df15be55ee57ec6cb5199e2b18bb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 37214c620df676ccd4d0ef3889f66155ecd422d4843a78cbe98a3115eb2cd233da629c22737d777de19bf9a71d2b869609a3d0b9b2060e26afd64247b6be3e3f
|
7
|
+
data.tar.gz: 026985a90a6bae6ed4f913ebe6f9a00e29694e0b915e53158c1a76e266b499c2f4fe136fc6c36a475bc0b87b0d96c3580dee4713c10401554decfa4f53c92a5c
|
@@ -7,10 +7,11 @@ module Nazrin
|
|
7
7
|
rescue LoadError
|
8
8
|
abort "Missing dependency 'kaminari' for pagination"
|
9
9
|
end
|
10
|
-
Kaminari.config.max_pages = options[:last_page]
|
11
10
|
Kaminari.paginate_array(collection, total_count: options[:total_count])
|
12
11
|
.page(options[:current_page])
|
13
|
-
.per(options[:per_page])
|
12
|
+
.per(options[:per_page]).tap do |paginate_array|
|
13
|
+
paginate_array.max_pages_per(options[:last_page])
|
14
|
+
end
|
14
15
|
end
|
15
16
|
end
|
16
17
|
end
|
data/lib/nazrin/search_client.rb
CHANGED
@@ -8,6 +8,7 @@ module Nazrin
|
|
8
8
|
attr_reader :parameters
|
9
9
|
|
10
10
|
def initialize
|
11
|
+
# @see http://docs.aws.amazon.com/sdkforruby/api/Aws/CloudSearchDomain/Client.html aws-sdk
|
11
12
|
@client = Aws::CloudSearchDomain::Client.new(
|
12
13
|
endpoint: Nazrin.config.search_endpoint,
|
13
14
|
region: Nazrin.config.region,
|
data/lib/nazrin/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: nazrin
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tomohiro Suwa
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2016-06-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: aws-sdk
|