我的控制器中的方法是
def userDirections
if user_signed_in?
redirect_to admin_user_path(admin_user_url)
else
redirect_to new_user_session_path
end
end
答案 0 :(得分:2)
这应该有效
def userDirections
if user_signed_in?
redirect_to admin_user_path(current_user)
else
redirect_to new_user_session_path
end
end