Guest User

Untitled

a guest
Jul 18th, 2018
86
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.43 KB | None | 0 0
  1. # corrected routes file
  2.  
  3. Rails.application.routes.draw do
  4.  
  5. mount_at = Cheese::Engine.config.mount_at
  6.  
  7. match mount_at => 'cheese/widgets#index'
  8.  
  9. scope mount_at do
  10.  
  11. resources :widgets, :only => [ :index, :show ],
  12. :controller => "cheese/widgets",
  13. :as => "cheese_widgets"
  14.  
  15. end
  16.  
  17. end
  18.  
  19. # this produces:
  20.  
  21. # cheese /cheese(.:format)
  22. # cheese_widgets GET /cheese/widgets(.:format)
  23. # cheese_widget GET /cheese/widgets/:id(.:format)
Add Comment
Please, Sign In to add comment