*Hi Frederick Cheung* ** NoMethodError in WizardController#wizard You have a nil object when you didn't expect it! You might have expected an instance of ActiveRecord::Base. The error occurred while evaluating nil.save
I can't understand the bugs.So please help me *Frederick Cheung* Thanks & Regards Balaji On 12/4/08, balaji rajagopal <[EMAIL PROTECTED]> wrote: > > *Hi Frederick Cheung* > ** > *im using the same code and final change code(remove the hide )* > *.......* > *end* > ** > @resort_basic.save() > @resort_contactdetail.save() > @resort_address.save() > @resort_additionaldetail.save() > @resort_accomodation.save() > > > I got the bugs: > NoMethodError in WizardController#wizard > > You have a nil object when you didn't expect it! > You might have expected an instance of ActiveRecord::Base. > The error occurred while evaluating nil.save > > RAILS_ROOT: D:/RubyProjects/TestEcohols > Application Trace <http://localhost:3000/wizard/wizard?stage=2#> | Framework > Trace <http://localhost:3000/wizard/wizard?stage=2#> | Full > Trace<http://localhost:3000/wizard/wizard?stage=2#> > > app/controllers/wizard_controller.rb:117:in `wizard' > :1:in `start' > > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/base.rb:1158:in > `perform_action' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/filters.rb:697:in > `call_filters' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/filters.rb:689:in > `perform_action_with_filters' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/benchmarking.rb:68:in > `perform_action_with_benchmark' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/1.8/benchmark.rb:293:in `measure' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/benchmarking.rb:68:in > `perform_action_with_benchmark' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/rescue.rb:199:in > `perform_action_with_rescue' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/caching.rb:678:in > `perform_action_with_caching' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/activerecord-2.0.2/lib/active_record/connection_adapters/abstract/query_cache.rb:33:in > `cache' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/activerecord-2.0.2/lib/active_record/query_cache.rb:8:in > `cache' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/caching.rb:677:in > `perform_action_with_caching' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/base.rb:524:in > `process' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/filters.rb:685:in > `process_with_filters' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/session_management.rb:123:in > `process_with_session_management_support' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/base.rb:388:in > `process' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/dispatcher.rb:171:in > `handle_request' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/dispatcher.rb:115:in > `dispatch' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/dispatcher.rb:126:in > `dispatch_cgi' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/dispatcher.rb:9:in > `dispatch' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/rails-2.0.2/lib/webrick_server.rb:112:in > `handle_dispatch' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/rails-2.0.2/lib/webrick_server.rb:78:in > `service' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/1.8/webrick/httpserver.rb:104:in `service' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/1.8/webrick/httpserver.rb:65:in `run' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/1.8/webrick/server.rb:173:in `start_thread' > > app/controllers/wizard_controller.rb:117:in `wizard' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/base.rb:1158:in > `perform_action' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/filters.rb:697:in > `call_filters' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/filters.rb:689:in > `perform_action_with_filters' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/benchmarking.rb:68:in > `perform_action_with_benchmark' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/1.8/benchmark.rb:293:in `measure' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/benchmarking.rb:68:in > `perform_action_with_benchmark' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/rescue.rb:199:in > `perform_action_with_rescue' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/caching.rb:678:in > `perform_action_with_caching' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/activerecord-2.0.2/lib/active_record/connection_adapters/abstract/query_cache.rb:33:in > `cache' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/activerecord-2.0.2/lib/active_record/query_cache.rb:8:in > `cache' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/caching.rb:677:in > `perform_action_with_caching' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/base.rb:524:in > `process' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/filters.rb:685:in > `process_with_filters' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/session_management.rb:123:in > `process_with_session_management_support' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/base.rb:388:in > `process' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/dispatcher.rb:171:in > `handle_request' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/dispatcher.rb:115:in > `dispatch' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/dispatcher.rb:126:in > `dispatch_cgi' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/dispatcher.rb:9:in > `dispatch' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/rails-2.0.2/lib/webrick_server.rb:112:in > `handle_dispatch' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/gems/1.8/gems/rails-2.0.2/lib/webrick_server.rb:78:in > `service' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/1.8/webrick/httpserver.rb:104:in `service' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/1.8/webrick/httpserver.rb:65:in `run' > D:/Program Files/NetBeans > 6.1/ruby2/jruby-1.1/lib/ruby/1.8/webrick/server.rb:173:in `start_thread' > :1:in `start' > > Request > > *Parameters*: > > {"authenticity_token"=>"09ab9bb40356d304564035a6b4a160d49dfccd66", > "firstname"=>"raja", > "lastname"=>"ram", > "designation"=>"director", > "email_id"=>"[EMAIL PROTECTED]", > "mobile"=>"9458289369", > "telephone1"=>"41252452", > "telephone2"=>"452865858", > "fax"=>"425828825", > "commit"=>"Next", > "stage"=>"2"} > > I can't understand the bugs.So please help me *Frederick Cheung* > > Thanks & Regards > > Balaji > > On 12/4/08, Frederick Cheung <[EMAIL PROTECTED]> wrote: >> >> >> >> On 4 Dec 2008, at 09:01, balaji rajagopal wrote: >> > >> > Request >> > Parameters: >> > >> > {"authenticity_token"=>"09ab9bb40356d304564035a6b4a160d49dfccd66", >> > "firstname"=>"balaji", >> > "lastname"=>"raja", >> > "designation"=>"director", >> > "email_id"=>"[EMAIL PROTECTED]", >> > "mobile"=>"999946936", >> > "telephone1"=>"4586854756", >> > "telephone2"=>"458269556", >> > "fax"=>"458256259", >> > "commit"=>"Next", >> > "stage"=>"2"} >> > >> > >> Stage 2 tries to access (among other things) params[:district] >> [:districtid] which is not one of the parameters submitted. >> >> Fred >> >> >> >> > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---

