Sha256: acf41d5260a237112383cb5a52572138b25203e8728048ce636b27d597222f6b

Contents?: true

Size: 501 Bytes

Versions: 152

Compression:

Stored size: 501 Bytes

Contents

module Avo
  module Filters
    class BaseFilter
      class_attribute :name, default: "Filter"
      class_attribute :component, default: "boolean-filter"
      class_attribute :default, default: ""
      class_attribute :template, default: "avo/base/select_filter"

      def apply_query(request, query, value)
        value.symbolize_keys! if value.is_a? Hash

        apply(request, query, value)
      end

      def id
        self.class.name.underscore.tr("/", "_")
      end
    end
  end
end

Version data entries

152 entries across 152 versions & 1 rubygems

Version Path
avo-1.25.2 lib/avo/filters/base_filter.rb
avo-2.3.1.pre.6 lib/avo/filters/base_filter.rb
avo-2.3.1.pre.5 lib/avo/filters/base_filter.rb
avo-2.3.1.pre.4 lib/avo/filters/base_filter.rb
avo-2.3.1.pre.3 lib/avo/filters/base_filter.rb
avo-2.3.1.pre.2 lib/avo/filters/base_filter.rb
avo-2.3.0 lib/avo/filters/base_filter.rb
avo-2.2.2 lib/avo/filters/base_filter.rb
avo-2.2.1 lib/avo/filters/base_filter.rb
avo-2.2.0 lib/avo/filters/base_filter.rb
avo-2.1.2.pre2 lib/avo/filters/base_filter.rb
avo-2.1.2.pre1 lib/avo/filters/base_filter.rb
avo-1.25.1 lib/avo/filters/base_filter.rb
avo-2.1.1 lib/avo/filters/base_filter.rb
avo-2.1.0 lib/avo/filters/base_filter.rb
avo-2.0.0 lib/avo/filters/base_filter.rb
avo-1.25.0 lib/avo/filters/base_filter.rb
avo-1.24.2 lib/avo/filters/base_filter.rb
avo-1.24.1 lib/avo/filters/base_filter.rb
avo-1.24.0 lib/avo/filters/base_filter.rb