Module: FilterMixin
- Included in:
- FilteredStringField, FilteredTextField
- Defined in:
- lib/yodel/models/core/fields/filter_mixin.rb
Instance Method Summary collapse
Instance Method Details
#typecast(value, record) ⇒ Object
2 3 4 |
# File 'lib/yodel/models/core/fields/filter_mixin.rb', line 2 def typecast(value, record) Hpricot(value.to_s).search('text()').collect(&:to_s).collect(&:strip).join(' ').strip end |
#untypecast(value, record) ⇒ Object
6 7 8 |
# File 'lib/yodel/models/core/fields/filter_mixin.rb', line 6 def untypecast(value, record) value.to_s end |