I create the project in scaffold but I cant able to edit it and update
th values
I gort the error in no action required I attach the image bellow
and my codeing the controller is :
@department = Department.find(params[:id])
respond_to do |format|
if @department.update_attributes(params[:departments])
flash[:notice] = 'Department was successfully updated.'
format.html { redirect_to(@department) }
format.xml { head :ok }
else
format.html { render :action => "edit" }
format.xml { render :xml => @department.errors, :status =>
:unprocessable_entity }
end
end
Attachments:
http://www.ruby-forum.com/attachment/8184/edit.jpg
--
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 unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
No comments:
Post a Comment