I'm in the process of upgrading from a Rails 2.3.14 app to Rails 3.2.1 So far, the only issue is an inability to specify routes to our legacy assets resources.
In config/application.rb:
config.assets.enabled = false
The following works (with an incorrect path):
resources :company_assets, :controller => 'assets', :as => :assets
But, of course, the path is '/company_assets/*'.
As soon as I try to make the path so it's '/assets/*', the routes fail to generate. By "fail to generate", I mean running:
rake routes | grep assets
Shows me nothing.
Here's an example of routes that fail to correctly generate:
resources :company_assets, :controller => 'assets', :as => :assets, :path => 'assets'
# or
resources :assets
When I poke around in the Rails console, it appears there are asset related routes, but they seem to be equivalent to having specified:
resource :assets
Instead of:
resources :assets
(Note singular vs. plural)
Is it possible to maintain backward compatibility here without mangling existing paths?