pg_search for an advanced search
问题 I'm trying to figure out how to pass multiple parameters to my search using pg_search_gem and the pg_search_scope This is my simple search include PgSearch pg_search_scope :simple_search, against: [:title, :description], using: { tsearch: { dictionary: "spanish"} } def self.search(search) if search.present? simple_search(search) else find(:all) end end But now I'm trying to do something like this include PgSearch pg_search_scope :simple_search, against: [:title, :place, :category], using: {