Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
当我使用 devise 登录时,我会停留在相同的 /users/sign_in 页面上。我需要覆盖 Devise 会话控制器吗?还是有其他方法?
in your application_controller.rb file:
class ApplicationController < ActionController::Base ... def after_sign_in_path_for (resource) root_path # or whatever path you want! end ... end