2012-10-21 18:32:17 +00:00
|
|
|
<div class="nothidden">
|
2012-12-21 23:07:13 +00:00
|
|
|
<%= form_for @item || Item.new, url: items_path do |form| %>
|
2012-10-24 06:47:08 +00:00
|
|
|
<h3>Add Topic</h3>
|
2012-09-24 01:30:48 +00:00
|
|
|
<label for="category">Category</label>
|
2012-10-24 06:47:08 +00:00
|
|
|
<%= select_tag "category", options_from_collection_for_select(ItemCategory.order("name ASC").all, "id", "name") %>
|
2012-09-24 01:30:48 +00:00
|
|
|
<label for="item_name">Title</label>
|
|
|
|
<%= form.text_field :name %>
|
|
|
|
<label for="item_desc">Description</label>
|
|
|
|
<%= form.text_area :desc, class: "description", :rows => 5 %>
|
|
|
|
<label for="item_link">Link</label>
|
|
|
|
<%= form.text_field :link, class: "link" %>
|
2012-10-26 10:04:52 +00:00
|
|
|
<label for="item_permission">Permission</label>
|
|
|
|
<%= form.select(:permission, options_for_select(['commons', 'public', 'private'])) %>
|
2012-10-30 03:48:17 +00:00
|
|
|
<%= form.submit "Add Topic", class: "addTopic", id: "addTopic" %>
|
2012-10-21 18:32:17 +00:00
|
|
|
<% end %>
|
|
|
|
</div>
|