Ruby on Rails | Screencasts | Download | Documentation | Weblog | Community | Source

Changeset 1815

Show
Ignore:
Timestamp:
07/11/05 07:49:56 (3 years ago)
Author:
david
Message:

Fixed that auto_complete_for didn't force the input string to lower case even as the db comparison was

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/actionpack/CHANGELOG

    r1814 r1815  
    11*1.9.1* (11 July, 2005) 
     2 
     3* Fixed that auto_complete_for didn't force the input string to lower case even as the db comparison was 
    24 
    35* Fixed that Action View should always use the included Builder, never attempt to require the gem, to ensure compatibility 
  • trunk/actionpack/lib/action_controller/auto_complete.rb

    r1814 r1815  
    3434        define_method("auto_complete_for_#{object}_#{method}") do 
    3535          find_options = {  
    36             :conditions => [ "LOWER(#{method}) LIKE ?", '%' + params[object][method] + '%' ],  
     36            :conditions => [ "LOWER(#{method}) LIKE ?", '%' + params[object][method].downcase + '%' ],  
    3737            :order => "#{method} ASC", 
    3838            :limit => 10 }.merge!(options)