Missing attribute: reorder

I am trying to use an integer object as a flag item for displaying a
link on a page called reorder that is a column in my PlanProcedures

I’m getting an error that says
The Header is NoMethodError in Manage_plan_procedures#list
missing attribute: reorder

Here is what my model looks like:


=> [“id”, “plan_id”, “procedure_id”, “platform_id”, “plugin_id”,
“user_id”, “release_id”, “iteration_id”, “minimum_priority”,
“procedure_iteration”, “position”, “created_on”, “updated_on”,
“updated_by”, “version”, “reorder”]

Reorder is an integer value
Here is the code that is balked about:

<% if plan_procedure.reorder == 1 %>
<%= link_to(image_tag(“blue_sync.png”), { :controller =>
‘manage_plan_procedures’, :action => ‘reorder’, :id =>
plan_procedure.id}, {:border => 0, :title => “Reorder Cases”, :class
=> “image_link”}) %>
<% end %>

I am setting this with an update_all
PlanProcedure.update_all(“reorder = 1”,“procedure_id =

and the reorder field is properly being set.

Has anyone seen something like this before and have any ideas?

On 12 Oct 2007, at 21:47, Will wrote:

Are you sure plan_procedure is really a instance of what you think it
is ?


Tracing through the code again I found the problem. The code I was
working with was using a find_by_sql statement and it did not include
the reorder field withing the object it created. I added it to the
code and it works like a charm now. Thanks


On Oct 13, 7:01 am, Frederick C. [email protected]

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs