index-tanked 0.1.12 → 0.1.13
Sign up to get free protection for your applications and to get access to all the features.
@@ -14,6 +14,7 @@ module IndexTanked
|
|
14
14
|
|
15
15
|
def add_all_to_index_tank(options={})
|
16
16
|
options[:batch_size] ||= 50
|
17
|
+
options[:select] ||= index_tanked.dependent_fields_for_select
|
17
18
|
count = 0
|
18
19
|
find_in_batches(options) do |instances|
|
19
20
|
documents = instances.map { |instance| instance.index_tanked.document_for_batch_addition }
|
@@ -52,7 +52,7 @@ module IndexTanked
|
|
52
52
|
|
53
53
|
def add_fields_to_query(query, options={})
|
54
54
|
return nil if query.blank? && options[:fields].blank?
|
55
|
-
[query, options[:fields] && options[:fields].to_a.join(
|
55
|
+
[query, options[:fields] && options[:fields].to_a.map {|pair| pair.join(':')}.join(' ')].compact.join(" ").strip
|
56
56
|
end
|
57
57
|
|
58
58
|
end
|
data/lib/index-tanked/version.rb
CHANGED
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: index-tanked
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 1
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 1
|
9
|
-
-
|
10
|
-
version: 0.1.
|
9
|
+
- 13
|
10
|
+
version: 0.1.13
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Adam Kittelson
|
@@ -16,7 +16,7 @@ autorequire:
|
|
16
16
|
bindir: bin
|
17
17
|
cert_chain: []
|
18
18
|
|
19
|
-
date: 2011-
|
19
|
+
date: 2011-04-01 00:00:00 -05:00
|
20
20
|
default_executable:
|
21
21
|
dependencies:
|
22
22
|
- !ruby/object:Gem::Dependency
|