Skip to content

Instantly share code, notes, and snippets.

@DriesS
Created September 20, 2011 08:44
Show Gist options
  • Select an option

  • Save DriesS/1228664 to your computer and use it in GitHub Desktop.

Select an option

Save DriesS/1228664 to your computer and use it in GitHub Desktop.
Problem activerecord searchlogic
search = Product
search = search.where(:product_type => "jeans")
search = search.where(:brand => "levis")
@products = search.all
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment