[ruby-it] [Rails] map.resources :news

Antonio Cangiano acangiano a gmail.com
Sab 5 Set 2009 15:47:48 CEST


2009/9/5 Yuri Redaelli <y.redaelli a gmail.com>

> Ciao a tutti,
>
> ho un problemino con il routing di un modello uncountable ovvero il
> classico "news".
>
> Specificano: "map.resources :news" mi trovo con un, ovvio, conflitto di
> metodi quando si tratta di richiamare: "news_path()"
>

Usa l'argomento :singular:

map.resources :news, :singular => :news_instance

Ciao,
Antonio
-- 
Zen and the Art of Programming: http://AntonioCangiano.com
Mathematics is wonderful: http://math-blog.com
Coming soon... : http://ThinkCode.TV
Aperiodico di resistenza informatica: http://stacktrace.it/
Author of "Ruby on Rails for Microsoft Developers": http://bit.ly/rorforms


More information about the Ml mailing list