Rails 为网页(rhtml)初始化数据

清华大佬耗费三个月吐血整理的几百G的资源,免费分享!....>>>

class HelloController < ApplicationController
  def there
    @data_hash = params[:cruncher]
    @cruncher = Cruncher.new(@data_hash[:crunch])

    @data = @cruncher.crunch
  end

  def input
        @cruncher = Cruncher.new("AAA")
  end
end