On 29 April 2013 01:03, Soichi Ishida <[email protected]> wrote:
>> Are you talking about making the display change automatically
>> immediately the user selects which sort of user he is?
>
> Not really.
> I was thinking that when users sign up, they are either one type or the
> other.  So, the required fields need to be set accordingly.  User model
> validations hopefully filter upon submitting.
>
>
>> If I recall correctly, some of the standard validation helpers will
>> take an "if" parameter, such that if the parameter evaluates to false,
>
> Seems great.  I will search for it.

Have a look at the Rails Guide on ActiveRecord Validations and
Callbacks.  Also check out the other guides.

Colin

>
> soichi
>
> --
> 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 unsubscribe from this group and stop receiving emails from it, send an 
> email to [email protected].
> To post to this group, send email to [email protected].
> For more options, visit https://groups.google.com/groups/opt_out.
>
>

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to