Unusual, I have a render partial with :locals set up but the partial is not recognizing the var being set. <%= render ''/shared/dynamic_attributes'', :locals => {:obj => @equipment } %> Error: undefined local variable or method `obj'' for #<ActionView::Base: 0x26bad44> -- 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 rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Either do <%= render :partial => ''/shared/dynamic_attributes'', :locals => {:obj => @equipment } %> OR <%= render ''/shared/dynamic_attributes'', :obj => @equipment %> -- Posted via http://www.ruby-forum.com/. -- 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 rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Thanks. I am not sure why but when I was doing CTRL+R to reload it was having issues. When I went back to the index and went to my edit page it works just fine. doh... On Jul 3, 9:24 pm, Kenneth <li...-fsXkhYbjdPsEEoCn2XhGlw@public.gmane.org> wrote:> Either do > > <%= render :partial => ''/shared/dynamic_attributes'', :locals => {:obj => > @equipment } %> > > OR > > <%= render ''/shared/dynamic_attributes'', :obj => @equipment %> > -- > Posted viahttp://www.ruby-forum.com/.-- 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 rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.