hi im new in ruby on rails development im just wonder if you guys can
help me with my little project which is a reservation system

i have a date,start_time and end_time and i want to validate if the time
is taken in the particular date. i read about scope validation validates
:date ,:uniqueness => { :scope => :timeEnd, :timeStart } but i guess i
have to do something else i think this is a implementation problem not
technically a logic problem or error bugs like that stuffs

do guys have suggestions for how can i solve this? thank in advance more
power to us all

--
Posted via http://www.ruby-forum.com/.

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.

Search Discussions

  • Leoncio Caminha at Apr 23, 2012 at 2:30 am
    read about it method call date_example.between?(start_date,end_date) this method verify if your date is on this range and return a boolean

    check out more on apidock.com

    thats it?
    On 22/04/2012, at 22:21, ruby LED wrote:

    hi im new in ruby on rails development im just wonder if you guys can
    help me with my little project which is a reservation system

    i have a date,start_time and end_time and i want to validate if the time
    is taken in the particular date. i read about scope validation validates
    :date ,:uniqueness => { :scope => :timeEnd, :timeStart } but i guess i
    have to do something else i think this is a implementation problem not
    technically a logic problem or error bugs like that stuffs

    do guys have suggestions for how can i solve this? thank in advance more
    power to us all

    --
    Posted via http://www.ruby-forum.com/.

    --
    You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
    To post to this group, send email to rubyonrails-talk@googlegroups.com.
    To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
    --
    You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
    To post to this group, send email to rubyonrails-talk@googlegroups.com.
    To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouprubyonrails-talk @
categoriesrubyonrails
postedApr 23, '12 at 1:21a
activeApr 23, '12 at 2:30a
posts2
users2
websiterubyonrails.org
irc#RubyOnRails

2 users in discussion

ruby LED: 1 post Leoncio Caminha: 1 post

People

Translate

site design / logo © 2021 Grokbase