I\'m going to create a multi user app, so, I will have a admin user that will have permission to create new ones.
I\'ve created the UsersController
but when
You could either override the default devise controller and add in your custom logic, or, It would probably be easier however to make a new (Admin) controller and simply create a user using one of it's actions.
@user = User.create!(:name => params[:foo], :email => params[:bar])
redirect_to @user
Devise has loads of guides on how to customise it's behaviour here: https://github.com/plataformatec/devise/wiki/_pages
This one in particular may be of interest to you: https://github.com/plataformatec/devise/wiki/How-To:-Manage-Users-with-an-Admin-Role-(CanCan-method) But make sure to have a look over the rest of the articles, there's a lot of them.