378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
|
# File 'lib/active_scaffold/finder.rb', line 378
def datetime_from_to(column, value)
conversion = datetime_conversion_for_condition(column)
case value['opt']
when 'RANGE'
values = datetime_from_to_for_range(column, value)
values.collect!(&conversion) if conversion != :to_time
values
when 'PAST', 'FUTURE'
values = datetime_from_to_for_trend(column, value)
values.collect!(&conversion) if conversion != :to_time
values
else
%w[from to].collect { |field| condition_value_for_datetime(column, value[field], conversion) }
end
end
|