app/helpers/application_helper.rb
# for query bar with @queries (given by item names) of @def_items
for query bar with @queries (given by item names) of @def_items
for query bar with @queries ( given by item names ) of @def_items
def query_items(items = @def_items, q_items = @queries)
    q_items.map do |q|
      [items[q].view_name, q]
    end
  end
def query_items ( items = @def_items , q_items = @queries ) q_items . map do | q | [ items [ q ] . view_name , q ] end end
for query bar with @queries (given by item names) of @def_items
for query bar with @queries ( given by item names ) of @def_items
items
<not_specific>
q_items
<not_specific>