I'm using the Administrate gem to set up my Admin page. I have successfully done so and generated this Admin Page:
Now I want to create a Home Page that my login page will redirect to after users successfully logged in. How can I do that? Thanks!
I'm using the Administrate gem to set up my Admin page. I have successfully done so and generated this Admin Page:
Now I want to create a Home Page that my login page will redirect to after users successfully logged in. How can I do that? Thanks!
you can use gem Devise https://github.com/plataformatec/devise for authentication.
Devise will create some helpers to use inside your controllers and views. To set up a controller with user authentication, just add this before_action (assuming your devise model is 'User'):
before_action :authenticate_user!