"modifica", :sign_up => "inregistreaza", :sig...">

Unexpected Rails Routes

Here are my .rb routes

scope :path_names => {:new => "creaza", :edit => "modifica", :sign_up => "inregistreaza", :sign_in => "autentificare", :sign_out => "iesire", :show => "vezi"} do
resources :nota, :only => [:new, :create]


And here is the output of the rake routes:

nota POST   /nota(.:format)                                          nota#create
new_notum GET    /nota/creaza(.:format)                                   nota#new


What? Notum? Where does notum come from?



source to share

1 answer

"notum" is Rails' attempt to de-plan "nota". This question contains some information on how to override these plurals, and here's an article on adapting the inflector for languages ​​other than English. See also this section in the routing guide.



All Articles