Hi,
I have two user models - PrivateUser and CorporateUser - in my Rails
1.2 application. Both are subclasses of User, created by
restful_authentication, which defines a user which can log in to my
application.
Now, I want to let both types of users register. They will need
different forms to fill out, but the logic is similar. So the use case
is
- User clicks Register link
- User chooses account type
- User fills out form
- User clicks Register to submit form
In the rest of the application, the two types of users are not very
similar - they have different roles and should get different views,
actions etc.
I am looking for the best way to keep my registration DRY - is there
something smart I can do here, or should I just make two completely
separate controllers whose code for ''new'' just happen to be
very
similar?
--~--~---------~--~----~------------~-------~--~----~
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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---