我收到一个错误:
NoMethodError in Devise/registrations#new
undefined method 'user_registration_path'
在这一行:
<%= form_for(resource, :as => resource_name, :url => registration_path(resource_name)) do |f| %>
这是我的路线:
devise_for :user, :controllers => { :registrations => "devise/registrations" }, :skip => [:registrations, :sessions] do
# devise/registrations
get 'signup' => 'devise/registrations#new', :as => :new_user_registration
post 'signup' => 'devise/registrations#create', :as => :custom_user_registration
end
耙路线:
new_user_registration GET /signup(.:format) devise/registrations#new
custom_user_registration POST /signup(.:format) devise/registrations#create
为什么我会收到user_registration_path
错误消息?