Note that there are some explanatory texts on larger screens.

plurals
  1. PORake routes giving false information
    primarykey
    data
    text
    <p>I guess this thing has amused me even before writing I feel it has something to do with asset pipeline feature in Rails 3.1+. </p> <p>I have defined a routes in routes.rb file with name assets. Here is the routes.rb file:</p> <pre><code>resources :assets do member do get 'remove_template' get 'all_sticker' get 'download_sticker' end collection do get 'failed_asset' end end </code></pre> <p>Now when ran <code>rake routes</code>:</p> <pre><code>sample_template_sticker_template GET /sticker_templates/:id/sample_template(.:format) sticker_templates#sample_template update_copy_sticker_template PUT /sticker_templates/:id/update_copy(.:format) sticker_templates#update_copy sticker_templates GET /sticker_templates(.:format) sticker_templates#index POST /sticker_templates(.:format) sticker_templates#create new_sticker_template GET /sticker_templates/new(.:format) sticker_templates#new edit_sticker_template GET /sticker_templates/:id/edit(.:format) sticker_templates#edit sticker_template GET /sticker_templates/:id(.:format) sticker_templates#show PUT /sticker_templates/:id(.:format) sticker_templates#update DELETE /sticker_templates/:id(.:format) sticker_templates#destroy thank_you /thank_you(.:format) home#thank_you home /welcome(.:format) home#index new_user_session GET /users/sign_in(.:format) devise/sessions#new user_session POST /users/sign_in(.:format) devise/sessions#create destroy_user_session DELETE /users/sign_out(.:format) devise/sessions#destroy user_password POST /users/password(.:format) devise/passwords#create new_user_password GET /users/password/new(.:format) devise/passwords#new edit_user_password GET /users/password/edit(.:format) devise/passwords#edit PUT /users/password(.:format) devise/passwords#update login GET / devise/sessions#new logout GET /logout(.:format) devise/sessions#destroy 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 PUT /users/:id(.:format) users#update DELETE /users/:id(.:format) users#destroy products GET /products(.:format) products#index POST /products(.:format) products#create new_product GET /products/new(.:format) products#new edit_product GET /products/:id/edit(.:format) products#edit product GET /products/:id(.:format) products#show PUT /products/:id(.:format) products#update DELETE /products/:id(.:format) products#destroy create_sticker_stickers GET /stickers/create_sticker(.:format) stickers#create_sticker stickers GET /stickers(.:format) stickers#index POST /stickers(.:format) stickers#create new_sticker GET /stickers/new(.:format) stickers#new edit_sticker GET /stickers/:id/edit(.:format) stickers#edit sticker GET /stickers/:id(.:format) stickers#show PUT /stickers/:id(.:format) stickers#update DELETE /stickers/:id(.:format) stickers#destroy </code></pre> <p>As you can see I can't find any routes define for assets resources even though I can access all of the available routes I define for assets in <code>routes.rb</code>.</p> <p>Can anyone explain why the output of <code>rake routes</code> does not contain information for assets resources.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload