aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/CHANGELOG.md
Commit message (Collapse)AuthorAgeFilesLines
...
| * Action Pack VariantsŁukasz Strzałkowski2013-12-041-0/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | By default, variants in the templates will be picked up if a variant is set and there's a match. The format will be: app/views/projects/show.html.erb app/views/projects/show.html+tablet.erb app/views/projects/show.html+phone.erb If request.variant = :tablet is set, we'll automatically be rendering the html+tablet template. In the controller, we can also tailer to the variants with this syntax: class ProjectsController < ActionController::Base def show respond_to do |format| format.html do |html| @stars = @project.stars html.tablet { @notifications = @project.notifications } html.phone { @chat_heads = @project.chat_heads } end format.js format.atom end end end The variant itself is nil by default, but can be set in before filters, like so: class ApplicationController < ActionController::Base before_action do if request.user_agent =~ /iPad/ request.variant = :tablet end end end This is modeled loosely on custom mime types, but it's specifically not intended to be used together. If you're going to make a custom mime type, you don't need a variant. Variants are for variations on a single mime types.
| * Changelog improvements [ci skip]Carlos Antonio da Silva2013-12-031-5/+5
| |
| * Merge branch 'format_localized_template' of https://github.com/acapilleri/railsGuillermo Iguaran2013-12-031-0/+9
| |\ | | | | | | | | | | | | Conflicts: actionpack/CHANGELOG.md
| | * Fix header Content-Type: #<Mime::NullType:...> in localized templateAngelo capilleri2013-12-031-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | This PR fixes #13064 regression bug introduced by the #8085 Now in _process_format when the format is a Mime::NullType nothing is written in self.content_type. In this way the method Response#assign_default_content_type_and_charset can write the the default mime_type.
| * | Try to escape each part of a path redirect route correctlyAndrew White2013-12-021-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A path redirect may contain any and all parts of a url which have different escaping rules for each part. This commit tries to escape each part correctly by splitting the string into three chunks - path (which may also include a host), query and fragment; then it applies the correct escape pattern to each part. Whilst using `URI.parse` would be better, unfortunately the possible presence of %{name} parameters in the path redirect string prevents us from using it so we have to use a regular expression instead. Fixes #13110.
* | | Fix stream closing when sending file with `ActionController::Live` included.Lauro Caetano2013-11-301-0/+6
|/ / | | | | | | Fixes #12381
* / first pass through CHANGELOGS to extract 4_1_release_notes. [ci skip]Yves Senn2013-11-281-5/+1
|/ | | | | | | | | | | | Extract **notable changes**, **deprecations** and **removals** from each CHANGELOG. I tried to reference the commits and pull requests for new features and deprecations. In the process I also made some minor changes to the CHANGELOGS. The 4_1_release_notes guide is declared WIP.
* Better error message for typos in assert_response argument.Victor Costan2013-11-251-0/+8
| | | | | This commit makes it really easy to debug errors due to typos like "assert_response :succezz".
* Improve changelogsCarlos Antonio da Silva2013-11-221-1/+1
| | | | | Also make Action Mailer changelog format more consistent with the others [ci skip]
* unify punctuation in Action Pack changelog. [ci skip]Yves Senn2013-11-211-5/+7
|
* Fix for routes taskSıtkı Bağdat2013-11-211-0/+4
| | | | This commit fixes formatting issue for `rake routes` task, when a section is shorter than a header.
* Fix CHANGELOG typo [ci skip]chocoby2013-11-151-1/+1
|
* Take Hash with options inside Array in #url_forAndrey Ognevsky2013-11-151-0/+9
|
* session#fetch doesn't behave exactly like Hash#fetch.Damien Mathieu2013-10-301-1/+3
| | | | | | | | | Mention it in the changelog and add a test checking for regressions. Hash#fetch isn't adding the defaultly returned value. However, in the session, saving it is the behavior we should expect. See discussion in #12692
* add the fetch method to sessionsDamien Mathieu2013-10-291-0/+12
|
* Add a changelog entry for #12656 [ci skip]Robin Dupret2013-10-271-0/+8
|
* Merge pull request #10471 from andyw8/button_to_paramsRafael Mendonça França2013-10-241-0/+5
|\ | | | | | | | | | | | | Add params option for button_to Conflicts: actionpack/CHANGELOG.md
| * Add params option for button_toAndy Waite2013-09-181-0/+5
| | | | | | | | | | | | The parameters are rendered as hidden form fields within the generated form. This is useful for when a record has multiple buttons associated with it, each of which target the same controller method, but which need to submit different attributes.
* | Improve the CHANGELOG entry [ci skip]Rafael Mendonça França2013-10-241-10/+9
| |
* | update CHANGELOGTima Maslyuchenko2013-10-241-0/+16
| |
* | Respect `SCRIPT_NAME` when using `redirect` with a relative pathAndrew White2013-10-101-0/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Example: # application routes.rb mount BlogEngine => '/blog' # engine routes.rb get '/admin' => redirect('admin/dashboard') This now redirects to the path `/blog/admin/dashboard`, whereas before it would've generated an invalid url because there would be no slash between the host name and the path. It also allows redirects to work where the application is deployed to a subdirectory of a website. Fixes #7977
* | add dots after `Fixes #YYYYY` in actionpack CHANGELOG. [ci skip]Yves Senn2013-10-091-12/+12
| |
* | Fixing repond_with working directly on the options hashBlueHotDog2013-10-091-0/+9
| | | | | | | | | | | | | | | | This fixes an issue where the respond_with worked directly with the given options hash, so that if a user relied on it after calling respond_with, the hash wouldn't be the same. Fixes #12029
* | Add changlog entry for #10844Andrew White2013-09-301-0/+7
| |
* | Strong parameters should permit nested number as key. Closes #12293kennyj2013-09-271-0/+6
| |
* | Fix regex used to find URI schemes in redirect_toDerek Prior2013-09-191-0/+5
| | | | | | | | | | The previous regex was allowing `_` in the URI scheme, which is not allowed by RFC 3986. This change brings the regex in line with the RFC.
* | Fix incorrect assert_redirected_to failure messageDerek Prior2013-09-191-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In some instances, `assert_redirected_to` assertion was returning an incorrect and misleading failure message when the assertion failed. This was due to a disconnect in how the assertion computes the redirect string for the failure message and how `redirect_to` computes the string that is actually used for redirection. I made the `_compute_redirect_to_loaction` method used by `redirect_to` public and call that from the method `assert_redirect_to` uses to calculate the URL. The reveals a new test failure due to the regex used by `_compute_redirect_to_location` allow `_` in the URL scheme.
* | Fix an issue where router can't recognize downcased url encoding path.kennyj2013-09-191-0/+6
| |
* | Custom flash should be defined only for the class that defines it and it's ↵Ricardo de Cillo2013-09-131-0/+7
| | | | | | | | subclasses.
* | Add CHANGELOG entry for #12149Rafael Mendonça França2013-09-121-0/+6
| | | | | | | | [ci skip]
* | Remove BasicRendering and remove template functionality from AbsC::RenderingJosé Valim2013-09-091-5/+0
| |
* | Improve AP changelog regarding AV extraction [ci skip]Carlos Antonio da Silva2013-08-261-2/+2
| |
* | Update AP changelogŁukasz Strzałkowski2013-08-251-0/+9
|/
* Display exceptions in text format for xhr requestKir Shatrov2013-08-221-0/+4
|
* Execute conditional procs on controller filters only for current action.Nicholas Jakobsen2013-08-101-0/+7
| | | | | | :only and :except options for controller filters are now added before :if and :unless. This prevents running :if and :unless procs when not on the specified. Closes #11786.
* Pass assert_dom_equal message arg to underlying assertionRyan McGeary2013-08-041-0/+7
| | | | | #assert_dom_equal and #assert_dom_not_equal both take a "failure" message argument, but this argument was not utilized.
* Allow overriding of all headers from passed environment hashAndrew White2013-07-251-0/+7
| | | | | | | Allow REMOTE_ADDR, HTTP_HOST and HTTP_USER_AGENT to be overridden from the environment passed into `ActionDispatch::TestRequest.new`. Fixes #11590
* Clear named routes when routes.rb is reloadedAndrew White2013-07-211-0/+8
| | | | | | | | Fix an issue where Journey was failing to clear the named routes hash when the routes were reloaded and since it doesn't overwrite existing routes then if a route changed but wasn't renamed it kept the old definition. This was being masked by the optimised url helpers so it only became apparent when passing an options hash to the url helper.
* Skip Rack applications and redirects when generating urlsAndrew White2013-07-161-0/+7
| | | | | | | | | | When generating an unnamed url (i.e. using `url_for` with an options hash) we should skip anything other than standard Rails routes otherwise it will match the first mounted application or redirect and generate a url with query parameters rather than raising an error if the options hash doesn't match any defined routes. Fixes #8018
* move `MissingHelperError` out of the `ClassMethods` module.Yves Senn2013-07-121-0/+4
|
* Show real LoadError on helpers requirePiotr Niełacny2013-07-101-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | When helper try to require missing file rails will throw exception about missing helper. # app/helpers/my_helper.rb require 'missing' module MyHelper end And when we try do load helper class ApplicationController helper :my end Rails will throw exception. This is wrong because there is a helper file. Missing helper file helpers/my_helper.rb Now when helper try to require non-existed file rails will throw proper exception. No such file to load -- missing
* Use Request#raw_post instead Request#bodyPaul Nikitochkin2013-07-081-0/+7
| | | | | | | | In order to get raw_post to be not empty after ParamsParser#parse_formatted_parameters, added rewinding of body stream input on parsing json params. Closes #11345
* Space is not required for Set-Cookie headerYamagishi Kazutoshi2013-07-051-0/+4
|
* Remove deprecated Rails application fallback for integration testingCarlos Antonio da Silva2013-07-021-0/+5
| | | | Set ActionDispatch.test_app instead.
* Remove `page_cache_extension` deprecated methodFrancesco Rodriguez2013-07-011-0/+4
|
* Remove deprecated constants from Action ControllerCarlos Antonio da Silva2013-07-011-0/+12
| | | | | | | | | | ActionController::AbstractRequest => ActionDispatch::Request ActionController::Request => ActionDispatch::Request ActionController::AbstractResponse => ActionDispatch::Response ActionController::Response => ActionDispatch::Response ActionController::Routing => ActionDispatch::Routing ActionController::Integration => ActionDispatch::Integration ActionController::IntegrationTest => ActionDispatch::IntegrationTest
* Merge pull request #11000 from sbeckeriv/accept_headerCarlos Antonio da Silva2013-06-251-0/+8
|\ | | | | | | Fix undefined method `ref' for nil:NilClass for bad accept headers
| * Fix undefined method `ref' for nil:NilClass for bad accept headersStephen Becker IV2013-06-191-0/+4
| |
* | Fixing Issue #11083Akshay Khole2013-06-251-1/+1
| | | | | | | | Removing other occurrences of `the` appearing twice
* | Fix shorthand routes where controller and action are in the scopeAndrew White2013-06-251-0/+9
| | | | | | | | | | | | | | | | | | Merge `:action` from routing scope and assign endpoint if both `:controller` and `:action` are present. The endpoint assignment only occurs if there is no `:to` present in the options hash so should only affect routes using the shorthand syntax (i.e. endpoint is inferred from the the path). Fixes #9856