I am trying to create a simple inventory application, and I wanted to have a page with a list of items, only with a name label and an editable field to update the number of installations and one update button to update all of them.
My model is called an element and two fields, name and instock
I'm not sure if you need more information, thanks.
* After playing with it, I can create a form, but when I click on the update, it gives an error: Could not find an element with ID = edit_multiple
Here is a part of my controller:
def edit_multiple @items = Item.find(params[:id])
And here are my .rb routes
resources :items do collection do get :search post :edit_multiple put :update_multiple end
If anyone has pointers or help, I would appreciate it.
thanks,
source share