Sha256: 8fe17ecc28eb7185a891e81e45a0c357b2f526630df7f9ed58b0c25cec947314
Contents?: true
Size: 576 Bytes
Versions: 5
Compression:
Stored size: 576 Bytes
Contents
module Searchgasm module Condition class NotHaveKeywords < Base class << self def condition_names_for_column super + ["not_have_keywords", "not_keywords", "not_have_kw", "not_kw", "not_have_kwwords", "not_kwwords"] end end def to_conditions(value) keywords = Keywords.new(klass, options) keywords.value = value conditions = keywords.to_conditions return conditions if conditions.blank? conditions.first.gsub!(" LIKE ", " NOT LIKE ") conditions end end end end
Version data entries
5 entries across 5 versions & 1 rubygems