daily pastebin goal


a guest Apr 22nd, 2018 49 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. # This is a namespace
  2. map.namespace(:admin) do |admin|
  3.   admin.resources :orders # To get at an order, you want admin_orders_path(@order)
  4. end
  5. ##
  6. # These are nested routes
  7. map.resources :polls do |poll|
  8.   poll.resource :options      # To get a poll option, you want poll_options_path(@poll,@option)
  9. end
  10. # A nested resource requires an argument for each level of nesting; a namespace does not.
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand