effective_datatables 4.32.3 → 4.33.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4fd39e83bcebfbf1f8dbe2b17d3d54027859a029171415cc474967fc86393748
|
4
|
+
data.tar.gz: 695f261ebd015f4caa869f8324576826a6189281e8beefcce2f7981b4787f800
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e81d92cd5969c55cac79164365927833cea5468eb6c5fc9e0490637b04ee409791f6c9146702b086d48817f00cfedfd4d15447560a42cafc9910e28441e85a9c
|
7
|
+
data.tar.gz: ce1c67eab48ee5f3099046beaed44a9c92e2a1dfca154e1847093feef0d00ba4215e00776153190a4d924942695c5bb76e30b9aa1f94827cb499db94287011f3
|
@@ -201,15 +201,20 @@ module Effective
|
|
201
201
|
# Nothing to do. We're just a string search.
|
202
202
|
elsif search[:as] == :select && search[:collection].kind_of?(Array)
|
203
203
|
# Nothing to do. We already loaded the custom parameterized collection above.
|
204
|
-
elsif
|
204
|
+
elsif search[:as] == :select && search[:collection].blank? && array_collection? && opts[:resource].present?
|
205
205
|
# Assigns { as: :select, collection: [...] }
|
206
206
|
search.reverse_merge!(search_resource.search_form_field(name, collection.first[opts[:index]]))
|
207
|
-
elsif
|
207
|
+
elsif search[:as] == :select && search[:collection].blank?
|
208
208
|
# Load the defaults from effective_resources
|
209
209
|
# Assigns { as: :string } or { as: :select, collection: [...] }
|
210
210
|
search.reverse_merge!(search_resource.search_form_field(name, opts[:as]))
|
211
|
-
|
211
|
+
elsif [:belongs_to, :belongs_to_polymorphic, :has_and_belongs_to_many, :has_many, :has_one].include?(opts[:as])
|
212
|
+
# Do not eager load the collection. Treat this as a string search.
|
212
213
|
search.reverse_merge!({ as: :string })
|
214
|
+
else
|
215
|
+
# Load the defaults from effective_resources
|
216
|
+
# Assigns { as: :string } or { as: :select, collection: [...] }
|
217
|
+
search.reverse_merge!(search_resource.search_form_field(name, opts[:as]))
|
213
218
|
end
|
214
219
|
|
215
220
|
# Assign default search operation
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: effective_datatables
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.
|
4
|
+
version: 4.33.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Code and Effect
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2025-04-
|
11
|
+
date: 2025-04-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|