Ruby on rails RubyonRails:如何以observer_形式传递变量?
我有 在控制器中的响应方法中,向自己证明它为零Ruby on rails RubyonRails:如何以observer_形式传递变量?,ruby-on-rails,Ruby On Rails,我有 在控制器中的响应方法中,向自己证明它为零 有什么想法吗?有了这个助手,我相信您需要通过:With选项传递所有参数。比如: puts "NTHDEONUTHDOEDEUU#{params[:user].nil?}||" 0.5,:update=>“报告”, :url=>{ :action=>'filter_reports', :仅_path=>false}, :with=>“'search='+encodeURIComponent(value)+'&user='{@user.id}
有什么想法吗?有了这个助手,我相信您需要通过
:With
选项传递所有参数。比如:
puts "NTHDEONUTHDOEDEUU#{params[:user].nil?}||"
0.5,:update=>“报告”,
:url=>{
:action=>'filter_reports',
:仅_path=>false},
:with=>“'search='+encodeURIComponent(value)+'&user='{@user.id}”
事实证明,我更新了错误的html内容,现在我的问题是没有过滤任何内容
puts "NTHDEONUTHDOEDEUU#{params[:user].nil?}||"
<%= observe_field :tb_search,
:frequency=>0.5, :update=>'reports',
:url=>{
:action=>'filter_reports',
:only_path=>false},
:with=>"'search='+encodeURIComponent(value)+'&user='#{@user.id}"