Skip to content

Commit 99d3217

Browse files
committed
feat: move apply_search method after @query is initialized
1 parent c3a936f commit 99d3217

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

Diff for: app/controllers/avo/base_controller.rb

+3-2
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,7 @@ def index
2525
end
2626
add_breadcrumb @resource.plural_name.humanize
2727

28-
# Apply the search query if configured on the resource
2928
set_index_params
30-
apply_search
3129
set_filters
3230
set_actions
3331
set_query
@@ -37,6 +35,9 @@ def index
3735
@query = @query.includes(*@resource.includes)
3836
end
3937

38+
# Apply the search query if configured on the resource
39+
apply_search
40+
4041
# Eager load attachments
4142
if @resource.attachments.present?
4243
@resource.attachments.each do |attachment|

0 commit comments

Comments
 (0)