aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/activerecord/polymorphic_routes_test.rb
Commit message (Collapse)AuthorAgeFilesLines
* Consistent routing languageJoshua Peek2010-03-301-82/+82
|
* Stop setting UrlFor using SharedTestHelpersCarlhuda2010-02-261-1/+1
|
* Rename named_url_helpers to url_helpers and url_helpers to url_forCarlhuda2010-02-261-3/+3
|
* Fix all of AP's tests with the non global routerCarlhuda2010-02-251-3/+3
|
* Use ActionDispatch::Routing everywhereMartin Schürrer2010-02-211-3/+3
|
* From now on, parameters defined in default_url_options can be absent from ↵José Valim2010-01-071-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | named routes. This allows the following setup to work: # app/controllers/application_controller.rb class ApplicationController def default_url_options(options=nil) { :locale => I18n.locale } end end # From your views and controllers: I18n.locale #=> :en users_url #=> "/en/users" users_url(:pl) #=> "/pl/users" user_url(1) #=> "/en/users/1" user_url(:pl, 1) #=> "/pl/users/1" user_url(1, :locale => :pl) #=> "/pl/users/1" If you provide all expected parameters, it still works as previously. But if any parameter is missing, it tries to assign all possible ones with the hash returned in default_url_options or the one passed straight to the named route method. Beware that default_url_options in ApplicationController is not shared with ActionMailer, so you are required to always give the locale in your email views.
* Make polymorphic_url work with symbols again and refactor it [#1384 ↵José Valim2009-10-281-8/+6
| | | | | | status:resolved] Signed-off-by: Joshua Peek <josh@joshpeek.com>
* Polymorphic routes generates collection URL from model class [#1089 ↵Niklas Holmgren2009-08-081-0/+31
| | | | | | | state:resolved] Signed-off-by: Dan Pickett <dpickett@enlightsolutions.com> Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
* Add destroyed? to ActiveRecord, include tests for polymorphic urls for ↵José Valim2009-08-071-1/+23
| | | | destroyed objects and refactor mime responds tests and documentation.
* Fix polymorphic_path doesn't modify options hash [#2099 state:resolved]=?utf-8?q?Mislav=20Marohni=C4=87?=2009-06-211-3/+6
| | | | Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
* Merge commit 'origin/master'Yehuda Katz + Carl Lerche2009-05-141-0/+1
| | | | | | Conflicts: actionpack/lib/action_controller/abstract/base.rb actionpack/lib/action_controller/routing.rb
* Remove excess mocking from polymorphic_url tests [#2330 state:resolved]Mike Gunderloy2009-04-211-0/+394
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>