module ActionView::Helpers::EnhancedDateSelectTagHelper

Public Instance Methods

enhanced_datetime_selector(options, html_options) click to toggle source
# File lib/enhanced_date_select.rb, line 23
def enhanced_datetime_selector(options, html_options)
  datetime = options[:value] || value(object) || default_datetime(options)

  @auto_index ||= nil

  options = options.dup
  options[:field_name] = @method_name
  options[:include_position] = true
  options[:prefix] ||= @object_name
  options[:index] = @auto_index if @auto_index && !options.key?(:index)

  EnhancedDateTimeSelector.new(datetime, options, html_options)
end
to_enhanced_date_select_tag(options, html_options) click to toggle source
# File lib/enhanced_date_select.rb, line 19
def to_enhanced_date_select_tag(options, html_options)
  enhanced_datetime_selector(options, html_options).enhanced_select_date.html_safe
end