Skip to content

Commit 9db860f

Browse files
Document the :ignore_date option on time_select (rails#49017)
* Document the :ignore_date option on time_select * split documentation comment into two lines Co-authored-by: Rafael Mendonça França <[email protected]>
1 parent c18bcd5 commit 9db860f

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

actionview/lib/action_view/helpers/date_helper.rb

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -320,6 +320,10 @@ def date_select(object_name, method, options = {}, html_options = {})
320320
# # You can set :ampm option to true which will show the hours as: 12 PM, 01 AM .. 11 PM.
321321
# time_select 'game', 'game_time', { ampm: true }
322322
#
323+
# # You can set :ignore_date option to true which will remove the hidden inputs for day,
324+
# # month, and year that are set by default on this helper when you only want the time inputs
325+
# time_select 'game', 'game_time', { ignore_date: true }
326+
#
323327
# The selects are prepared for multi-parameter assignment to an Active Record object.
324328
#
325329
# Note: If the day is not included as an option but the month is, the day will be set to the 1st to ensure that

0 commit comments

Comments
 (0)