Devise single sign in for two models

Hi All,

I have a requirement.

A person will sign up to my site and send invitations to some users. The
person who sign-up will be taken as admin and will be stored in admin
table.

Other users who get invitations through mail will be stored in user
table.

I used devise for admin sign-up.

Now as normal users no need to sign-up I dint use devise.

The problem here is that there will be only one sign-in form which both
admin and user will use. How should this be done in devise?

If devise is not applicable can somebody suggest some ideas…

Waiting for ur thoughts…

Thanks,

P.Angeline

On 13 September 2012 11:36, angel david [email protected] wrote:

table.
It is usually best in this sort of situation to have just one table
for both. Often a gem like cancan is used to allocate different roles
to individual users (admin, normal user for example), though in a
simple case perhaps just a flag is needed.

I used devise for admin sign-up.

Now as normal users no need to sign-up I dint use devise.

The problem here is that there will be only one sign-in form which both
admin and user will use. How should this be done in devise?

If you have only one table then the problem may disappear. You just
need to provide for the two roles.

Colin