Wap Addon wrote:
> Frederick Cheung wrote:
>> On Aug 11, 10:23�am, Wap Addon <[email protected]>
>> wrote:
>>> i got error
>>> �ActiveRecord::RecordNotFound in AdminsController#update
>>>
>>> Couldn't find Admin with ID=cateupdate
>>>
>>> i have pro_categories table edit file display record but when i press
>>> update i give me above error
>> 
>> in a restful world when you add actions you need to add them to your
>> routes file (see the :member and :collection options to map.resources)
>> 
>> Fred
> 
> i am not understand your suggestion.

i have to fix my problem like this
<div align="center">
  <h3>Product category</h3>
  <% form_for( :pro_categorie, :url => {:action => 'updatecate',:id => 
@pro_categorie.id}) do |f| %>
  <%= f.error_messages %>
  <table>
  </tr>
  <td><lable>Category Name :</lable></td>
    <td><%= f.text_field :pcate_name %></td>
  </tr>
  <tr>
    <td><lable>Category Desc :</lable></td>
    <td><%= f.text_field :pcate_desc %></td>
  </tr>
  <tr>
    <td colspan="2" align="center"><%= f.submit 'Update' 
%>&nbsp;&nbsp;&nbsp;&nbsp;<%= link_to 'Back', admins_path %></td>
  </tr>
  </table>
  <%end%>
</div>
-- 
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 [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
-~----------~----~----~----~------~----~------~--~---

Reply via email to