Multiple search forms and search engines

Hello. I have a search form with two search engines (sphinx,
elasticsearch), I need to add filters by parameters (name, cost,
direction,
country). Something like this Notion – The all-in-one workspace for your notes, tasks, wikis, and databases.. The
problem
is, I don’t know how to pass all this queries from the form to the one
search query so that I can handle filters inside the search engine (f.e.
filters are working if search query passed to one search form).

Not sure if I explained it well.

Here’s an example:
I enter “lorem” in the main search field, then in the “Name” field I
enter
“Australia” all this goes to the one search query (it is in
params[:query]), so result is - only first tour should be displayed.
Again, it works when there is one field.

tours_controller: Paste2.org - Viewing Paste CZXHdMO1

Thanks.