Module: ValidatesTimeliness::ValidationMethods::ClassMethods
- Defined in:
- lib/validates_timeliness/validation_methods.rb
Instance Method Summary collapse
- #validates_date(*attr_names) ⇒ Object
- #validates_datetime(*attr_names) ⇒ Object
- #validates_time(*attr_names) ⇒ Object
Instance Method Details
#validates_date(*attr_names) ⇒ Object
16 17 18 19 20 |
# File 'lib/validates_timeliness/validation_methods.rb', line 16 def validates_date(*attr_names) configuration = attr_names. configuration[:type] = :date validates_timeliness_of(attr_names, configuration) end |
#validates_datetime(*attr_names) ⇒ Object
22 23 24 25 26 |
# File 'lib/validates_timeliness/validation_methods.rb', line 22 def validates_datetime(*attr_names) configuration = attr_names. configuration[:type] = :datetime validates_timeliness_of(attr_names, configuration) end |
#validates_time(*attr_names) ⇒ Object
10 11 12 13 14 |
# File 'lib/validates_timeliness/validation_methods.rb', line 10 def validates_time(*attr_names) configuration = attr_names. configuration[:type] = :time validates_timeliness_of(attr_names, configuration) end |