1. 26 5月, 2014 2 次提交
  2. 25 5月, 2014 4 次提交
  3. 24 5月, 2014 4 次提交
  4. 23 5月, 2014 1 次提交
  5. 14 5月, 2014 2 次提交
  6. 05 5月, 2014 1 次提交
  7. 02 5月, 2014 1 次提交
  8. 01 5月, 2014 1 次提交
  9. 11 4月, 2014 1 次提交
    • A
      Only make deeply nested routes shallow when parent is shallow · e10f26f9
      Andrew White 提交于
      Since `:shallow` may be set at any point in the resource nesting we should
      only make the new and collection routes shallow when the parent is shallow.
      
      This is a bit of a hack but until the mapper is refactored to an object graph
      instead of a hash of merged values it's the best we can do.
      
      Fixes #14684.
      e10f26f9
  10. 21 3月, 2014 1 次提交
  11. 16 3月, 2014 1 次提交
  12. 09 3月, 2014 4 次提交
    • A
      Copy shallow options from normal options when using scope · af4c9b78
      Andrew White 提交于
      If the options :shallow_prefix and :shallow_path are not set in the
      scope options then copy them from the normal :as and :path options
      if they are set.
      af4c9b78
    • A
      Pull namespace defaults out of the options hash · 8711086f
      Andrew White 提交于
      If a developer has specified either :path or :as in the options hash then
      these should be used as the defaults for :shallow_path and :shallow_prefix.
      
      Fixes #14241.
      8711086f
    • A
      Only use shallow nested scope when depth is > 1 · dcc91a04
      Andrew White 提交于
      By tracking the depth of resource nesting we can push the need for nested
      shallow scoping to only those routes that are nested more than one deep.
      This allows us to keep the fix for #12498 and fix the regression in #14224.
      
      Fixes #14224.
      dcc91a04
    • A
      Move setting :scope_level_resource to resource_scope · ed0fb4ae
      Andrew White 提交于
      Originally with_scope_level was exclusively for managing scope levels with
      resources, however it is now used for other things so it makes more sense
      to move the responsibility for setting the :scope_level_resource to the
      resource_scope method. This eliminates repeatedly setting it to the same
      resource as each resource method scope is evaluated.
      ed0fb4ae
  13. 10 2月, 2014 1 次提交
    • A
      Set the :shallow_path as each scope is generated · 462d7cb3
      Andrew White 提交于
      If we set :shallow_path when shallow is called it can result in incorrect
      paths if the resource is inside a namespace because namespace itself sets
      the :shallow_path option to the namespace path.
      
      We fix this by removing the :shallow_path option from shallow as that should
      only be turning shallow routes on and not otherwise affecting the scope.
      To do this we need to treat the :shallow option to resources differently to
      other scope options and move it to before the nested block is called.
      
      This change also has the positive side effect of making the behavior of the
      :shallow option consistent with the shallow method.
      
      Fixes #12498.
      462d7cb3
  14. 25 1月, 2014 1 次提交
  15. 20 1月, 2014 2 次提交
  16. 06 1月, 2014 1 次提交
  17. 30 12月, 2013 1 次提交
  18. 11 12月, 2013 1 次提交
    • P
      Fix mounting engines inside a resources block · e6c602da
      Piotr Sarnacki 提交于
      When a route is mounted inside a resources block, it's automatically
      prefixed, so a following code:
      
          resources :users do
            mount Blog::Engine => '/blog'
          end
      
      will generate a user_blog path helper.
      
      In order to access engine helpers, we also use "mounted_helpers", a list
      of helpers associated with each mounted engine, so a path to blog's post
      can be generated using user_blog.post_path(user, post).
      
      The problem I'm fixing here is that mount used a raw :as option, without
      taking nestings into account. As a result, blog was added to a route set
      as a `user_blog`, but helper was generated for just `blog`.
      
      This commit applies the proper logic for defining a helper for a mounted
      engine nested in resources or resource block.
      
      (closes #8533)
      e6c602da
  19. 15 11月, 2013 4 次提交
  20. 12 11月, 2013 1 次提交
  21. 05 11月, 2013 1 次提交
    • G
      Improve Errors when Controller Name or Action isn't specfied · 834eb80b
      Gaurish Sharma 提交于
      These errors occur when, there routes are wrongly defined.
      
      example, the following line would cause a missing :action error
      
          root "welcomeindex"
      
      Mostly beginners are expected to hit these errors, so lets improve the error message a bit to make their learning experience bit better.
      834eb80b
  22. 13 9月, 2013 2 次提交
  23. 09 9月, 2013 2 次提交