0

How can i do a condition with is not empty, or has a value?

I tried but is not working

     <% if params[:search_num_letter].values.any?  and params[:search_letter_log].values.any? %>
          No data
     <% else %>
         <% if params[:search_num_letter] == ""  and params[:search_letter_log] == "" %>
            No data
         <% else %> 
            my code
         <% end %>
     <% end %>

I will really appreciate help.

4

1 に答える 1