| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
In those version to_date call Fixnum#/, what will cause a failure
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Because DateTime#to_time returns self when it has a non-zero offset
and subtracting two DateTime instances returns a Rational then the
distance_of_time_in_words methods outputs an incorrect value.
This is fixed in master because we can rely on Ruby 1.9.3's
implementation of to_time but it can't be fixed on Ruby 1.8.7 as
there is no way to map the DateTime to a Time with a non-zero offset.
We can workaround the problem by casting to Float before doing
the subtraction in the distance_of_time_in_words method.
Closes #8390
|
|
|
|
|
|
|
|
|
|
| |
This commit fixes the output of distance_of_time_in_words when
using integer or duration arguments. Previously a distance of
more than 30 seconds would be output as 'Less than 1 minute'
when using integer arguments and '1 minute' when using two
Time instances more than 30 seconds apart.
Cherry picked from 5fdd4cd9e47be972f146a8a17a74c8f4700e2ac0
|
|
|
|
|
|
|
|
|
|
|
|
| |
we should take disabled option not only from `html_options` hash but from
`options` hash too like `build_select` method does it. So
datetime_select("post", "updated_at", { :discard_minute => true }, { :disabled => true })
datetime_select("post", "updated_at", :discard_minute => true , :disabled => true)
both these variants work now
closes #7431
|
|\
| |
| | |
datetime_select fix for dates of -infinity and +infinity
|
| | |
|
| | |
|
| |
| |
| |
| | |
Closes #4553 and #4633
|
| | |
|
|/
|
|
|
| |
date_select does not work when day is discarded, include blank option is
enabled and struct date itself is nil.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Added use_two_digit_numbers select_tag option for displaying months and days with leading zeros without affecting the values (useful for e.g. ISO-style dates, 2011-08-01).
Signed-off-by: José Valim <jose.valim@gmail.com>
Conflicts:
actionpack/CHANGELOG.md
|
|
|
|
|
|
|
|
|
|
| |
Inspired by dlt https://github.com/dlt/rails/commit/9e615634745dc81598e7b880d52411338d3a7a93
Closes #239.
Conflicts:
actionpack/CHANGELOG
|
|\
| |
| | |
Allow AM/PM format in datetime selectors
|
| | |
|
|/
|
|
| |
[#6074 state:resolved]
|
| |
|
|
|
|
| |
Signed-off-by: Santiago Pastorino <santiago@wyeworks.com>
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Conflicts:
activerecord/CHANGELOG
activerecord/lib/active_record/association_preload.rb
activerecord/lib/active_record/associations.rb
activerecord/lib/active_record/associations/class_methods/join_dependency.rb
activerecord/lib/active_record/associations/class_methods/join_dependency/join_association.rb
activerecord/lib/active_record/associations/has_many_association.rb
activerecord/lib/active_record/associations/has_many_through_association.rb
activerecord/lib/active_record/associations/has_one_association.rb
activerecord/lib/active_record/associations/has_one_through_association.rb
activerecord/lib/active_record/associations/through_association_scope.rb
activerecord/lib/active_record/reflection.rb
activerecord/test/cases/associations/has_many_through_associations_test.rb
activerecord/test/cases/associations/has_one_through_associations_test.rb
activerecord/test/cases/reflection_test.rb
activerecord/test/cases/relations_test.rb
activerecord/test/fixtures/memberships.yml
activerecord/test/models/categorization.rb
activerecord/test/models/category.rb
activerecord/test/models/member.rb
activerecord/test/models/reference.rb
activerecord/test/models/tagging.rb
|
| |
| |
| |
| |
| |
| | |
not Time.zone_default.
[#6410 state:committed]
|
| |
| |
| |
| | |
Signed-off-by: Santiago Pastorino <santiago@wyeworks.com>
|
|/
|
|
| |
Signed-off-by: Santiago Pastorino <santiago@wyeworks.com>
|
|
|
|
| |
Signed-off-by: Santiago Pastorino <santiago@wyeworks.com>
|
| |
|
|
|
|
| |
Signed-off-by: José Valim <jose.valim@gmail.com>
|
|
|
|
| |
's/[ \t]*$//' -i {} \;)
|
|
|
|
|
|
| |
true [#4856 state:resolved]
Signed-off-by: José Valim <jose.valim@gmail.com>
|
|
|
|
|
|
|
|
| |
* datetime_select and select_datetime should be consistent as much as possible
* date_select and select_date should be consistent as much as possible
* time_select and select_time should be consistent as much as possible
Signed-off-by: José Valim <jose.valim@gmail.com>
|
| |
|
|
|
|
|
|
|
|
| |
html_options specifies it. ht by Marc Schütz
[#3807 state:committed]
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
|
|
|
|
| |
Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
|
| |
|
|
|
|
|
|
|
| |
days return '2 days'.
Signed-off-by: Michael Koziarski <michael@koziarski.com>
[#3266 state:committed]
|
|
|
|
|
|
|
| |
about depending upon how many months have elapsed
Signed-off-by: Michael Koziarski <michael@koziarski.com>
[#3106 state:committed]
|
|
|
|
|
|
|
| |
:prompt option has been used
Signed-off-by: Michael Koziarski <michael@koziarski.com>
[#561 state:resolved]
|
| |
|
|
|
|
|
|
| |
[Josh, Frederick Cheung]
Signed-off-by: Frederick Cheung <frederick.cheung@gmail.com>
|
|
|
|
| |
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
|
|
|
|
|
|
| |
Pointer Exception when a nil date/datetime was passed and only month and year were displayed [#1289 state:committed]
Signed-off-by: David Heinemeier Hansson <david@loudthinking.com>
|
|
|
|
| |
Signed-off-by: Joshua Peek <josh@joshpeek.com>
|
|
|
|
| |
Signed-off-by: Joshua Peek <josh@joshpeek.com>
|
|
|
|
| |
Signed-off-by: Joshua Peek <josh@joshpeek.com>
|
|
|
|
| |
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
|
|
|
|
|
|
| |
[Pascal Ehlert]
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
|
|
|
|
| |
the instance variable so others can override the methods.
|
| |
|
| |
|
|
|
|
| |
Time.current as default; respects hash settings when time falls in system local spring DST gap
|
|
|
|
| |
set; otherwise returns Date.today. ActionView date_helper uses Date.current to determine locale-appropriate default
|