「Time.now.strftime」関数の目的で、60 秒ごとにページを更新する単純な小さな関数を作成しました。ただし、検索を実行すると、最終的に検索結果でページが更新され、次のエラーが表示されます。
nil を String に変換できません
app/models/product.rb:37:in `+'
app/models/product.rb:37:in `fuzzy_search'
app/controllers/products_controller.rb:92:in `search'
def self.fuzzy_search(search_string)
    (LINE 37)   search_string = "%" + search_string + "%"
        self.find(:all, :conditions => ["title LIKE ?", search_string])
    end
(LINE 92) @products = Product.fuzzy_search(params[:search_string])
        if @products.empty?
            flash.now[:alert] = "No records found - displaying all records..."
            @products = Product.find :all, :order => 'title'
        end
        render :action => "index"
どんな助けでも感謝しますありがとう