This project is archived and is in readonly mode.
Some issues with separators in ActionView::Helpers::DateHelper
Reported by squirrel | June 20th, 2008 @ 06:05 PM
First issue
:date_separator does not work in select_date. Mainly because it is not used when iterating over all elements of the date.
My little solution would be changing
options[:order].each do |o|
  select_date << self.send("select_#{o}", date, options)
end
to
separator = ''
options[:order].each do |o|
  select_date << separator + self.send("select_#{o}", date, options)
  separator = options[:date_separator] || ''
end
So, separator is '' for the first date element, and :date_separator for the next elements.
Second issue
The documentation for the usage of :date_separator is incorrectly placed in the comment block for select_datetime and not select_date.
Third issue
There is no documentation for :datetime_separator in select_datetime.
PS: I hope the formatting of this ticket is correct. A preview function would be great. :/
Comments and changes to this ticket
- 
        

fluxin June 26th, 2008 @ 07:24 PM
- no changes were found...
 
 - 
            
        

fluxin June 26th, 2008 @ 07:24 PM
- Tag set to actionpack, helper, tiny
 
here's a patch along with tests
 - 
        

josh August 7th, 2008 @ 06:48 AM
- Assigned user set to josh
 - State changed from new to open
 - Milestone cleared.
 
 - 
        

josh August 7th, 2008 @ 04:50 PM
- State changed from open to resolved
 
Being rolled into http://github.com/josh/rails/tre...
 
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile »
<h2 style="font-size: 14px">Tickets have moved to Github</h2>
The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>