Sha256: 1f076c649bdeaaf0c392600f8e14df48782375ea50134e53011b90f4d4261b17
Contents?: true
Size: 253 Bytes
Versions: 1
Compression:
Stored size: 253 Bytes
Contents
class Datagrid::Filters::DateFilter < Datagrid::Filters::BaseFilter #TODO: more smart date normalizer def format(value) return value unless value.is_a?(String) value.blank? ? nil : Date.parse(value) rescue ArgumentError nil end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
datagrid-0.0.3 | lib/datagrid/filters/date_filter.rb |