jhund / filterrific

Filterrific is a Rails Engine plugin that makes it easy to filter, search, and sort your ActiveRecord lists.
http://filterrific.clearcove.ca
MIT License
910 stars 124 forks source link

Allow arrays inside nested parameters #226

Closed neilvcarvalho closed 12 months ago

neilvcarvalho commented 12 months ago

When one scope is handled by multiple fields, we need to add each of those fields to the permitted params. However, when one of those inner fields includes multiple-select fields, we don't instruct Strong Parameters that those params expect arrays. As a result, those keys are dropped.

This commit fixes that, recursively handling each nested param, so that arrays and other nested fields are supported.

Fixes #225

neilvcarvalho commented 12 months ago

Closing in favor of #213