sant0sk1 (owner)

Revisions

gist: 99827 Download_button fork
public
Public Clone URL: git://gist.github.com/99827.git
Embed All Files: show embed
pickup.rb #
1
2
3
4
5
6
7
8
9
10
class Pickup < ActiveRecord::Base
  validate_on_create :date_three_days_in_future
 
  private
 
  def date_three_days_in_future
    errors.add_to_base "must be at least 3 days from now" unless date >= 3.days.from_now.to_date
  end
 
end