aboutsummaryrefslogtreecommitdiffstats
path: root/actionview/lib/action_view/helpers/form_tag_helper.rb
diff options
context:
space:
mode:
Diffstat (limited to 'actionview/lib/action_view/helpers/form_tag_helper.rb')
-rw-r--r--actionview/lib/action_view/helpers/form_tag_helper.rb19
1 files changed, 3 insertions, 16 deletions
diff --git a/actionview/lib/action_view/helpers/form_tag_helper.rb b/actionview/lib/action_view/helpers/form_tag_helper.rb
index 82f2fd30c7..f1375570f2 100644
--- a/actionview/lib/action_view/helpers/form_tag_helper.rb
+++ b/actionview/lib/action_view/helpers/form_tag_helper.rb
@@ -685,21 +685,6 @@ module ActionView
text_field_tag(name, value, options.merge(type: :time))
end
- # Creates a text field of type "datetime".
- #
- # === Options
- # * <tt>:min</tt> - The minimum acceptable value.
- # * <tt>:max</tt> - The maximum acceptable value.
- # * <tt>:step</tt> - The acceptable value granularity.
- # * Otherwise accepts the same options as text_field_tag.
- def datetime_field_tag(name, value = nil, options = {})
- ActiveSupport::Deprecation.warn(<<-MESSAGE.squish)
- datetime_field_tag is deprecated and will be removed in Rails 5.1.
- Use datetime_local_field_tag instead.
- MESSAGE
- text_field_tag(name, value, options.merge(type: :datetime))
- end
-
# Creates a text field of type "datetime-local".
#
# === Options
@@ -707,10 +692,12 @@ module ActionView
# * <tt>:max</tt> - The maximum acceptable value.
# * <tt>:step</tt> - The acceptable value granularity.
# * Otherwise accepts the same options as text_field_tag.
- def datetime_local_field_tag(name, value = nil, options = {})
+ def datetime_field_tag(name, value = nil, options = {})
text_field_tag(name, value, options.merge(type: 'datetime-local'))
end
+ alias datetime_local_field_tag datetime_field_tag
+
# Creates a text field of type "month".
#
# === Options