searchkick 1.3.0 → 1.3.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +2 -1
- data/CHANGELOG.md +5 -0
- data/README.md +3 -3
- data/lib/searchkick.rb +1 -1
- data/lib/searchkick/index.rb +2 -0
- data/lib/searchkick/version.rb +1 -1
- data/test/aggs_test.rb +1 -1
- data/test/gemfiles/activerecord50.gemfile +7 -0
- metadata +21 -19
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8305aa9120f165e3db35f1dc1a5662ac29f97b0c
|
4
|
+
data.tar.gz: 3dc530c3469c997ac3be7d579a56b3f3e7e63501
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0f72db4715189311702fbfdb14ab8a4d7757ba8de1774af53ccbea564ac187ed74ade723f4aa14d9a5221ec0c1e15cd98e6d7f5aa39312c734607baa02b47483
|
7
|
+
data.tar.gz: 3b9bdbbb2e189abb6226d69b45ffd20c42ac1b272b90b20beb8357de6b3b180818aa76879952585d3c8ddba5b18058650310c62dd397800bd95b1deafccad417
|
data/.travis.yml
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
language: ruby
|
2
|
-
rvm: 2.2
|
2
|
+
rvm: 2.2.5
|
3
3
|
services:
|
4
4
|
- elasticsearch
|
5
5
|
- mongodb
|
@@ -14,6 +14,7 @@ notifications:
|
|
14
14
|
on_failure: change
|
15
15
|
gemfile:
|
16
16
|
- Gemfile
|
17
|
+
- test/gemfiles/activerecord50.gemfile
|
17
18
|
- test/gemfiles/activerecord41.gemfile
|
18
19
|
- test/gemfiles/activerecord40.gemfile
|
19
20
|
- test/gemfiles/activerecord32.gemfile
|
data/CHANGELOG.md
CHANGED
data/README.md
CHANGED
@@ -515,7 +515,7 @@ Product.search "milk", boost_where: {orderer_ids: current_user.id}
|
|
515
515
|
|
516
516
|
Autocomplete predicts what a user will type, making the search experience faster and easier.
|
517
517
|
|
518
|
-
![Autocomplete](
|
518
|
+
![Autocomplete](https://raw.githubusercontent.com/ankane/searchkick/gh-pages/autocomplete.png)
|
519
519
|
|
520
520
|
**Note:** If you only have a few thousand records, don’t use Searchkick for autocomplete. It’s *much* faster to load all records into JavaScript and autocomplete there (eliminates network requests).
|
521
521
|
|
@@ -570,7 +570,7 @@ Then add the search box and JavaScript code to a view.
|
|
570
570
|
|
571
571
|
### Suggestions
|
572
572
|
|
573
|
-
![Suggest](
|
573
|
+
![Suggest](https://raw.githubusercontent.com/ankane/searchkick/gh-pages/recursion.png)
|
574
574
|
|
575
575
|
```ruby
|
576
576
|
class Product < ActiveRecord::Base
|
@@ -589,7 +589,7 @@ products.suggestions # ["peanut butter"]
|
|
589
589
|
|
590
590
|
[Aggregations](https://www.elastic.co/guide/en/elasticsearch/reference/current/search-facets.html) provide aggregated search data.
|
591
591
|
|
592
|
-
![Aggregations](
|
592
|
+
![Aggregations](https://raw.githubusercontent.com/ankane/searchkick/gh-pages/facets.png)
|
593
593
|
|
594
594
|
```ruby
|
595
595
|
products = Product.search "chuck taylor", aggs: [:product_type, :gender, :brand]
|
data/lib/searchkick.rb
CHANGED
data/lib/searchkick/index.rb
CHANGED
data/lib/searchkick/version.rb
CHANGED
data/test/aggs_test.rb
CHANGED
@@ -42,7 +42,7 @@ class AggsTest < Minitest::Test
|
|
42
42
|
agg = Product.search("Product", aggs: {store_id: {limit: 1}}).aggs["store_id"]
|
43
43
|
assert_equal 1, agg["buckets"].size
|
44
44
|
# assert_equal 3, agg["doc_count"]
|
45
|
-
assert_equal(1, agg["sum_other_doc_count"])
|
45
|
+
assert_equal(1, agg["sum_other_doc_count"]) unless Searchkick.server_below?("1.4.0")
|
46
46
|
end
|
47
47
|
|
48
48
|
def test_ranges
|
metadata
CHANGED
@@ -1,97 +1,97 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: searchkick
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.3.
|
4
|
+
version: 1.3.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Andrew Kane
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-07-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activemodel
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- -
|
17
|
+
- - '>='
|
18
18
|
- !ruby/object:Gem::Version
|
19
19
|
version: '0'
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
|
-
- -
|
24
|
+
- - '>='
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '0'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: elasticsearch
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- -
|
31
|
+
- - '>='
|
32
32
|
- !ruby/object:Gem::Version
|
33
33
|
version: '1'
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
|
-
- -
|
38
|
+
- - '>='
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: '1'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: hashie
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
|
-
- -
|
45
|
+
- - '>='
|
46
46
|
- !ruby/object:Gem::Version
|
47
47
|
version: '0'
|
48
48
|
type: :runtime
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
|
-
- -
|
52
|
+
- - '>='
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '0'
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
56
|
name: bundler
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
|
-
- -
|
59
|
+
- - ~>
|
60
60
|
- !ruby/object:Gem::Version
|
61
61
|
version: '1.6'
|
62
62
|
type: :development
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
|
-
- -
|
66
|
+
- - ~>
|
67
67
|
- !ruby/object:Gem::Version
|
68
68
|
version: '1.6'
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
70
|
name: rake
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
72
72
|
requirements:
|
73
|
-
- -
|
73
|
+
- - '>='
|
74
74
|
- !ruby/object:Gem::Version
|
75
75
|
version: '0'
|
76
76
|
type: :development
|
77
77
|
prerelease: false
|
78
78
|
version_requirements: !ruby/object:Gem::Requirement
|
79
79
|
requirements:
|
80
|
-
- -
|
80
|
+
- - '>='
|
81
81
|
- !ruby/object:Gem::Version
|
82
82
|
version: '0'
|
83
83
|
- !ruby/object:Gem::Dependency
|
84
84
|
name: minitest
|
85
85
|
requirement: !ruby/object:Gem::Requirement
|
86
86
|
requirements:
|
87
|
-
- -
|
87
|
+
- - '>='
|
88
88
|
- !ruby/object:Gem::Version
|
89
89
|
version: '0'
|
90
90
|
type: :development
|
91
91
|
prerelease: false
|
92
92
|
version_requirements: !ruby/object:Gem::Requirement
|
93
93
|
requirements:
|
94
|
-
- -
|
94
|
+
- - '>='
|
95
95
|
- !ruby/object:Gem::Version
|
96
96
|
version: '0'
|
97
97
|
description: Intelligent search made easy
|
@@ -101,8 +101,8 @@ executables: []
|
|
101
101
|
extensions: []
|
102
102
|
extra_rdoc_files: []
|
103
103
|
files:
|
104
|
-
-
|
105
|
-
-
|
104
|
+
- .gitignore
|
105
|
+
- .travis.yml
|
106
106
|
- CHANGELOG.md
|
107
107
|
- Gemfile
|
108
108
|
- LICENSE.txt
|
@@ -131,6 +131,7 @@ files:
|
|
131
131
|
- test/gemfiles/activerecord32.gemfile
|
132
132
|
- test/gemfiles/activerecord40.gemfile
|
133
133
|
- test/gemfiles/activerecord41.gemfile
|
134
|
+
- test/gemfiles/activerecord50.gemfile
|
134
135
|
- test/gemfiles/apartment.gemfile
|
135
136
|
- test/gemfiles/mongoid2.gemfile
|
136
137
|
- test/gemfiles/mongoid3.gemfile
|
@@ -169,17 +170,17 @@ require_paths:
|
|
169
170
|
- lib
|
170
171
|
required_ruby_version: !ruby/object:Gem::Requirement
|
171
172
|
requirements:
|
172
|
-
- -
|
173
|
+
- - '>='
|
173
174
|
- !ruby/object:Gem::Version
|
174
175
|
version: '0'
|
175
176
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
176
177
|
requirements:
|
177
|
-
- -
|
178
|
+
- - '>='
|
178
179
|
- !ruby/object:Gem::Version
|
179
180
|
version: '0'
|
180
181
|
requirements: []
|
181
182
|
rubyforge_project:
|
182
|
-
rubygems_version: 2.
|
183
|
+
rubygems_version: 2.0.0
|
183
184
|
signing_key:
|
184
185
|
specification_version: 4
|
185
186
|
summary: Searchkick learns what your users are looking for. As more people search,
|
@@ -197,6 +198,7 @@ test_files:
|
|
197
198
|
- test/gemfiles/activerecord32.gemfile
|
198
199
|
- test/gemfiles/activerecord40.gemfile
|
199
200
|
- test/gemfiles/activerecord41.gemfile
|
201
|
+
- test/gemfiles/activerecord50.gemfile
|
200
202
|
- test/gemfiles/apartment.gemfile
|
201
203
|
- test/gemfiles/mongoid2.gemfile
|
202
204
|
- test/gemfiles/mongoid3.gemfile
|