<%= form_for(item) do |f| %>
  <div>
    <%= f.label :name %>:
    <%= f.text_field :name %>
  </div>

  <div>
    <%= f.label :description %>:
    <%= f.text_field :description %>
  </div>

  <div>
    <%= f.label :image %>:
    <%= f.text_field :image %>
  </div>

  <div>
    <%= f.label :price %>:
    <%= f.text_field :price %>
  </div>

  <div>
    <%= f.label :quantity %>:
    <%= f.text_field :quantity %>
  </div>

  <div>
    <%= f.submit %>
  </div>
<% end %>

<% @item.errors.each do |error_array, error| %>
  <p><%= flash[:error] = error %><p>
<% end %>
<%= form_for(item) do |f| %>
  <div>
    <%= f.label :name %>:
    <%= f.text_field :name %>
  </div>

  <div>
    <%= f.label :description %>:
    <%= f.text_field :description %>
  </div>

  <div>
    <%= f.label :image %>:
    <%= f.text_field :image %>
  </div>

  <div>
    <%= f.label :price %>:
    <%= f.text_field :price %>
  </div>

  <div>
    <%= f.label :quantity %>:
    <%= f.text_field :quantity %>
  </div>

  <div>
    <%= f.label :category_id %>:
    <%= f.select(:category_id, [['Movies', 1], ['Shoes', 2]],{ :prompt => "Please select"})  %>
  </div>

  <div>
    <%= f.submit %>
  </div>
<% end %>

<% @item.errors.each do |error_array, error| %>
  <p><%= flash[:error] = error %><p>
<% end %>
Update new item form so that you can now choose a category for your item
Update new item form so that you can now choose a category for your item
