Displaying 3 results from an estimated 3 matches for "the_time".
Did you mean:
ae_time
2007 Oct 09
1
validate two dates, 2date - 1date > 1month
Hello,
I have a model with date field, i need to compare this date with current
system time. The date that inputed from web-form should be at least one
month later than current system time.
What the best way to do it?
Thanks
--
Posted via http://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
2007 Feb 13
7
Specs of code that use Time.now
Hi
Just trying to spec a Rails model that defaults a valid_until date to
this time tomorrow. I''ve done something similar involving Dates, and
you can stub the :today method to return something fixed. But when I
tried this with Time, I found that RSpec calls Time.now four times
per spec. So there''s no way to spec code like 1.days.from_now . The
best I can come up
2008 Apr 17
0
Having problem with validates_presence_of fields in form when trying to also use ActiveScaffold (x-posted at ActiveScaffold group)
...odels Event and
DateAndTime, so an event that happens more than once (like a high
school play) can have more than one date_and_time. The Event model
has_many date_and_times, and the DateAndTime model belongs_to event.
The Event model validates_presence_of two submission form variables,
the_date and the_time, and those variable values then get used to
create a new date_and_time object once the form is submitted.
My ActiveScaffold problem is that when the update form for the Event
model displays, it shows all the correct dates and times in drop-down
lists (with the ability to either edit or delete them...