Sha256: 9f9b22a21a85725d9f1d08d90c88d9d8e4ba2e9e1d902a65065b81bd188c6d98
Contents?: true
Size: 688 Bytes
Versions: 20
Compression:
Stored size: 688 Bytes
Contents
module ActiveScaffold module DateSelectExtension def datetime_selector_with_name(options, html_options) options.merge!(:prefix => options[:name].gsub(/\[[^\[]*\]$/,'')) if options[:name] datetime_selector_without_name(options, html_options) end def self.included(base) base.class_eval do alias_method_chain :datetime_selector, :name private :datetime_selector_without_name, :datetime_selector_with_name, :datetime_selector end end end end (defined?(ActionView::Helpers::Tags::DateSelect) ? ActionView::Helpers::Tags::DateSelect : ActionView::Helpers::InstanceTag).class_eval do include ActiveScaffold::DateSelectExtension end
Version data entries
20 entries across 20 versions & 2 rubygems