% admin_breadcrumb(link_to plural_resource_name(Spree::Product), spree.admin_products_path) %>
<% admin_breadcrumb(plural_resource_name(Spree::Property)) %>
<% content_for :page_actions do %>
<% if can?(:create, Spree::Property) %>
<%= button_link_to t('spree.new_property'), new_admin_property_url, { remote: true, id: 'new_property_link' } %>
<% end %>
<% end %>
<% content_for :table_filter_title do %>
<%= t('spree.search') %>
<% end %>
<% content_for :table_filter do %>
<%= search_form_for [:admin, @search] do |f| %>
<%- locals = {f: f} %>
<%= f.label :name_cont, t('spree.name') %>
<%= f.text_field :name_cont, size: 15 %>
<%= button t('spree.search') %>
<% end %>
<% end %>
<% if @properties.any? %>
<%= Spree::Property.human_attribute_name(:name) %> |
<%= Spree::Property.human_attribute_name(:presentation) %> |
|
<% @properties.each do |property| %>
<%= property.name %> |
<%= property.presentation %> |
<% if can?(:update, property) %>
<%= link_to_edit(property, no_text: true) %>
<% end %>
<% if can?(:destroy, property) %>
<%= link_to_delete(property, no_text: true) %>
<% end %>
|
<% end %>
<% else %>
<%= render 'spree/admin/shared/no_objects_found',
resource: Spree::Property,
new_resource_url: new_object_url %>
<% end %>
<%= paginate @collection, theme: "solidus_admin" %>