This project is archived and is in readonly mode.
DateHelper patch
-
josh
- State changed from new to open
- Tag changed from actionpack, doc, enhancement, helper, patch, refactoring, tests to actionpack, patch, refactoring
Nice writeup. Will this close #606 Inconsistent functionality in date_helper.rb too?
-
josh
I think we are going start namespacing the private methods in helpers. So "build_options" becomes "_date_build_options".
However, I'd really like to start looking into some more presenter patterns for this stuff. Something like this.
DateSelector.new(date, options).select_day -
Repository
- State changed from open to resolved
(from [ff9f6fcc75526d9fd89be834982dec8624c909c5]) Refactor DateHelper and improve test coverage [#665 state:resolved]
Signed-off-by: Joshua Peek
-
Clemens Kofler
Josh:
This doesn't close #606 Inconsistent functionality in date_helper.rb just yet because the object-related methods still don't support the separators.
I like the approach with the Presenter pattern. It seems that the InstanceTag approach that's currently used by the object-related methods is a similar approach but IMO it tries to do too many jobs at once. It'd be great to have all date helper related functionality in one Presenter class and then have all helper methods, both "standard" and object-related ones, access the same functionality. I'll look into that and keep you posted.