Hi All,

Im using devise with rails 3.

My requirement in this is,

There are two scenarios.

1. User send reset password for their email id.

2. Admin send reset password for the user mail id, where the user is not
active. When this scenario is generated, the reset instruction mail
should be delivered to the admin email id and not to the actual user
mail id.


This is tricky but this is what my requirement is.

Can this be done in devise?
Or is there any other possibilities?

Can anyone share your thoughts on this?



Regards,

--
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

  • Dave Aronson at Feb 1, 2012 at 3:48 pm

    On Wed, Feb 1, 2012 at 02:33, angel david wrote:

    2. Admin send reset password for the user mail id, where the user is not
    active. When this scenario is generated, the reset instruction mail
    should be delivered to the admin email id and not to the actual user
    mail id. ...
    Or is there any other possibilities?

    Can anyone share your thoughts on this?
    Since you asked for our thoughts... mine are that this requirement
    doesn't make much sense. The only reason I can think of for doing
    this, is that what the customer (the person asking you to write the
    app, not the user of the app) really wants, is for the admin to have
    some way to set a user's password. The requirement is poorly written,
    dictating *how* something will be done, not just *what* is to be done.

    If it's absolutely necessary that there be an email, such as for an
    audit trail, that can be done by adding that to the admin's password
    reset feature.

    -Dave

    --
    Dave Aronson:  Available Cleared Ruby on Rails Freelancer
    (NoVa/DC/Remote) -- see www.DaveAronson.com, and blogs at
    www.Codosaur.us, www.Dare2XL.com, www.RecruitingRants.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.
  • Don at Feb 2, 2012 at 3:53 pm
    Devise does have the capability to override the default controllers (there
    is an example of this in the Devise readme.) One approach would be to
    override the controller that handles the password email notifications with
    your own customized controller. In your new controller, it should be
    simple to check the user activity state and set the destination email
    address to the user or the admin as required.

    I switched out a controller a while back to get some customized control,
    and it was pretty straight forward, except for getting the routes right.
    I'm not good with Rails routing so that took a while.

    Don
    On Wednesday, February 1, 2012 12:33:02 AM UTC-7, Ruby-Forum.com User wrote:

    2. Admin send reset password for the user mail id, where the user is not
    active. When this scenario is generated, the reset instruction mail
    should be delivered to the admin email id and not to the actual user
    mail id.


    This is tricky but this is what my requirement is.

    Can this be done in devise?
    Or is there any other possibilities?

    Can anyone share your thoughts on this?

    Regards,

    --
    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 view this discussion on the web visit https://groups.google.com/d/msg/rubyonrails-talk/-/EobBdy273cAJ.
    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
postedFeb 1, '12 at 7:33a
activeFeb 2, '12 at 3:53p
posts3
users3
websiterubyonrails.org
irc#RubyOnRails

3 users in discussion

Don: 1 post Angel david: 1 post Dave Aronson: 1 post

People

Translate

site design / logo © 2021 Grokbase