search for: _contacts

Displaying 2 results from an estimated 2 matches for "_contacts".

Did you mean: contacts
2006 Mar 29
3
partial variable help
Can''t work this out: In list.rhtml: <% for employee in @employees -%> <%= render(:partial => "list_form", :object => employee) %> <% end -%> In _list_form.rhtml (partial): <%= employee.id %> In controller: @employees = Employee.find(:all) I get the following error: undefined local variable or method `employee'' I everything is correct
2007 Jun 28
1
complete stumper: variable exists in hidden_field_tag, but nil everywhere else
...71"/> So I read that to mean that @event.id is 771. Fine, good. However, if I change the line to this: <%= hidden_field_tag ''id'', @event.id, :id => ''event_id'' %> ...I get an error: RuntimeError in Controller#index Showing app/views/controller/_contacts.rhtml where line #81 raised: Called id for nil, which would mistakenly be 4 -- if you really wanted the id of nil, use object_id Furthermore, if I say this elsewhere in the same partial: the event id is: <%= @event && @event.id %>END ...I get this: the event is: END And finally...