search for: options_with_prefix

Displaying 3 results from an estimated 3 matches for "options_with_prefix".

2005 May 08
3
Overriding date_select in local project to use custom value rather than blank for starting option...
I would like to have a date control on a page and I would like a behavior similar to what you get using date_select with the :include_blank => true option where the first value in the dropdown is "- Month -", "- Day -", or "- Year -" rather than a blank value for the respective month, day, and year select fields. I took a look at the ruby source for
2006 Feb 05
0
How can i specify default time to datetime_select tag
...looking at rails helper code ----------------------------------------------------------------------- module ActionView module Helpers module DateHelper def to_datetime_select_tag(options = {}) defaults = { :discard_type => true } options = defaults.merge(options) options_with_prefix = Proc.new { |position| options.merge(:prefix => "#{@object_name}[#{@method_name}(#{position}i)]") } datetime = options[:include_blank] ? (value || nil) : (value || Time.now) datetime_select = select_year(datetime, options_with_prefix.call(1)) datetime_sel...
2008 Jun 26
2
Problem with date_select after Rails 2.1 upgrade
.... ---- If I dig into DateHelper with the debugger, this appears to be the line that''s bombing out: /Users/wgray/Documents/Sources/Rails/tempo/vendor/rails/actionpack/lib/ action_view/helpers/date_helper.rb:655 date_or_time_select.insert(0, self.send("select_#{param}", datetime, options_with_prefix(position[param], options.merge(:use_hidden => discard[param])), html_options)) (rdb:1) eval self.send("select_#{param}", datetime, options_with_prefix(position[param], options.merge(:use_hidden => discard[param])), html_options) ArgumentError Exception: wrong number of arguments (3...