で空白のデバイス サインアップ フォームを送信すると/signup
、ユーザーは にリダイレクトされます/users/signup
。
空白のデバイス ログインおよびパスワード リセット フォーム ( /login
to/sessions/user
および/password/new
to /users/secret
) を送信すると、同じことが起こります。
どうすれば/signup
もう一度リダイレクトできますか?
私のルートファイル:
resources :users
devise_scope :user do
get "login", :to => "devise/sessions#new"
get "logout", :to => "devise/sessions#destroy"
get "signup", :to => "devise/registrations#new"
get "password/new", :to => "devise/passwords#new"
match 'users/secret', to: "devise/passwords#create", via: :post
match 'sessions/user', to: 'devise/sessions#create', via: :post
match 'users/signup', to: 'devise/registrations#create', via: :post
end
devise_for :users, :path => '', :path_names => { :sign_in => 'login', :sign_out => 'logout',
:password => 'password', :confirmation => 'verification',
:unlock => 'unblock', :registration => 'signup',
:sign_up => 'new' }
root 'home#index'
get 'users/new'
編集1
意味不明なので削除。
編集2
レーキルート:
Prefix Verb URI Pattern Controller#Action
users GET /users(.:format) users#index
POST /users(.:format) users#create
new_user GET /users/new(.:format) users#new
edit_user GET /users/:id/edit(.:format) users#edit
user GET /users/:id(.:format) users#show
PATCH /users/:id(.:format) users#update
PUT /users/:id(.:format) users#update
DELETE /users/:id(.:format) users#destroy
sessions GET /sessions(.:format) sessions#index
POST /sessions(.:format) sessions#create
new_session GET /sessions/new(.:format) sessions#new
edit_session GET /sessions/:id/edit(.:format) sessions#edit
session GET /sessions/:id(.:format) sessions#show
PATCH /sessions/:id(.:format) sessions#update
PUT /sessions/:id(.:format) sessions#update
DELETE /sessions/:id(.:format) sessions#destroy
new_user_session GET /login(.:format) devise/sessions#new
user_session POST /login(.:format) devise/sessions#create
destroy_user_session DELETE /logout(.:format) devise/sessions#destroy
user_password POST /password(.:format) devise/passwords#create
new_user_password GET /password/new(.:format) devise/passwords#new
edit_user_password GET /password/edit(.:format) devise/passwords#edit
PATCH /password(.:format) devise/passwords#update
PUT /password(.:format) devise/passwords#update
cancel_user_registration GET /signup/cancel(.:format) devise/registrations#cancel
user_registration POST /signup(.:format) devise/registrations#create
new_user_registration GET /signup/new(.:format) devise/registrations#new
edit_user_registration GET /signup/edit(.:format) devise/registrations#edit
PATCH /signup(.:format) devise/registrations#update
PUT /signup(.:format) devise/registrations#update
DELETE /signup(.:format) devise/registrations#destroy
login GET /login(.:format) devise/sessions#new
logout GET /logout(.:format) devise/sessions#destroy
signup GET /signup(.:format) devise/registrations#new
password_new GET /password/new(.:format) devise/passwords#new
users_secret POST /users/secret(.:format) devise/passwords#create
sessions_user POST /sessions/user(.:format) devise/sessions#create
users_signup POST /users/signup(.:format) devise/registrations#create
root GET / home#index
users_new GET /users/new(.:format) users#new