Different devise confirmation behaviour for same model

Hi,

I want to have different email confirmation behaviour for same model
depending on certain conditions.

Case 1: User signs up on his own using an email and password, gets
Mail
Template 1 (the mail only asks for email confirmation, he has already
set
the password)

Case 2: A new user is added in model explicitly by another registered
user. The new user gets Mail Template 2, which asks him to reset the
password (reset should by default confirm his account as well)

Is this possible to achieve?

I was going through Devise
pagehttps://github.com/plataformatec/devise/wiki/How-To:-Override-confirmations-so-users-can-pick-their-own-passwords-as-part-of-confirmation-activationwhere
we can override confirmation process to let user set the password and
auto-confirm the account during this process. But I think this will
happen
for all users added in model. I want to customize this.

Thanks.

Regards,
Ankur

On Apr 25, 2014, at 11:19 PM, Ankur K. wrote:

Have you looked at Devise Invitable yet? That lets current members
invite other members, but does not set their password, so they have to
choose one before they are fully brought into the fold.

Walter

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs