<%= render :partial => 'admin/shared/product_sub_menu' %>

<%= "#{t("actions.listing")} #{t("products")}" %>

<%= hook :admin_products_index_headers do %> <% end %> <% @collection.each do |product| %> id="<%= dom_id product %>"> <%- locals = {:product => product} %> <%= hook :admin_products_index_rows, locals do %> <% end %> <% end %>
<%= t("sku") %> <%= sort_link @search,:name, t("name"), {}, {:title => 'admin_products_listing_name_title'} %> <%= sort_link @search,:master_price, t("master_price") %> <%= hook :admin_products_index_header_actions %>
<%= product.sku %> <%= product.name %> <%= product.price %> <%= hook :admin_products_index_row_actions, locals do %> <%= link_to_edit product, :class => 'edit' unless product.deleted? %>   <%= link_to_clone product, :class => 'clone' %>   <%= link_to_delete product unless product.deleted? %> <% end %>
<%= will_paginate(:previous_label => "« #{t('previous')}", :next_label => "#{t('next')} »") %> <% content_for :sidebar do %> <%= form_for [:admin, @search] do |f| %>

<%= t(:search) %>

<%- locals = {:f => f} %> <%= hook :admin_products_index_search, locals do %>

<%= f.label :name_contains, t("name") %>
<%= f.text_field :name_contains, :size => 15 %>

<%= f.label :variants_including_master_sku_contains, t("sku") %>
<%= f.text_field :variants_including_master_sku_contains, :size => 15 %>

<%= f.label :deleted_at_is_null, t("show_deleted") %>
<%= f.check_box :deleted_at_is_null, {:checked => params[:search][:deleted_at_is_null].blank?}, "", "1" %>

<% end %> <%= hook :admin_products_index_search_buttons, locals do %>

<%= button t("search") %>

<% end %>
<% end %> <%= form_tag import_from_yandex_market_path, :method => :get do %>

Импорт с Яндекс.Маркет

<%= label_tag :model_id, "ID товара на ЯМ" %>
<%= text_field_tag :model_id %>

<%= check_box_tag :available %> <%= label_tag :available, "сделать доступным" %>

<%= button "Импорт" %>

<% end %> <% end %>