<div class="page-header">
 <ol class="breadcrumb">
  <li class="breadcrumb-item"><a href="<%= root_path %>"><%= t("views.right_panel.button.home") %></a></li>
  <li class="breadcrumb-item active"><%= t :inventory %></li>
  <span class="float-right">
    <%= link_to t('.back', :default => t("views.btn.back")), dashboard_path %>
  </span>
</ol>
</div>

<div class="row ">
      <div class="col-lg-4 col-md-4 col-sm-4" style="padding-left: 17px;">
      <%= form_tag inventory_path, :id => "filter_form", :method => :get do %>
        <!-- col-lg-4 col-md-4 col-sm-4 -->
        <!-- <label class="font-14"><%= t("views.right_panel.detail.product") %></label> -->
        <input type="text" class="form-control" name="filter" id="Product" type="text" placeholder="Product" style="height: 32px;">
      </div>

      <div class="col-lg-2 col-md-2 col-sm-2 text-">
        <input type="submit" value="Filter" class='btn btn-primary'>
      </div>
      <% end %>

      <div class="col-lg-6 col-md-6 col-sm-6" style="padding-right: 15px;">
         <!-- m-b-10 clearfix -->
          <!-- <button id="stock_check_report" type="button" class="btn bg-blue float-right waves-effect" style='margin-left:5px;'> <%= t("views.btn.stock_check_report") %>
          </button> -->
          <button id="stock_taking" type="button" class="btn bg-blue float-right waves-effect" style='margin-left:5px;'> <%= t("views.btn.stock_taking") %></button>
          <button id='new_inventory_product' class='btn btn-primary  float-right waves-effect' style='margin-left:5px;'><%= (t :track) +" "+ t("views.btn.new") + " " %> <%= t("views.right_panel.detail.item") %>
         </button>
    </div>
</div>

<div class="row">
  <div class="col-xs-12 col-sm-12 col-md-12 col-lg-12">
      <div class="card">
        <%= render 'inventory_list' %>
      </div>
  </div>
  <!-- <div class="col-xs-12 col-sm-12 col-md-3 col-lg-3">
    <div class="card">
      <div class="body">
        <h5><i class="material-icons md-18">list <%= t("views.right_panel.header.button_lists") %></i> </h5>
        <p>
        1) <%= (t :track) +" "+ t("views.btn.new") + " " + (t :inventory) %> - <%= t("views.right_panel.detail.create_btn_txt") %> <%= t("views.right_panel.detail.inventory") %> <br>
        </p>
        <p>
        2) <%= t("views.right_panel.detail.stock_taking") %> - <%= t("views.right_panel.detail.create_btn_txt") %> <%= t("views.right_panel.detail.stock_taking_txt") %> <br>
        </p>
        <<p>
        3) <%= t("views.right_panel.detail.stock_check_report") %> - <%= t("views.right_panel.detail.back_txt") %> <%= t("views.right_panel.detail.stock_check_report_txt") %> <br>
        </p>
        <h5><i class="material-icons md-18">list <%= t("views.right_panel.header.link_lists") %></i> </h5>
        <p>
          1) <%= t("views.right_panel.button.home") %> - <%= t("views.right_panel.detail.home_txt") %> <br>
          2) <%= t("views.right_panel.button.back") %> - <%= t("views.right_panel.detail.back_txt") %> <%= t("views.right_panel.detail.dashboard_txt") %> <br>
          </p>
      </div>
    </div>
  </div> -->
</div>


<script>
  $('#stock_taking').on('click', function () {
    window.location.href = '<%= inventory_stock_checks_path %>';
  });

  // $('#stock_check_report').on('click', function () {
  //   window.location.href = '<%= reports_stock_check_index_path %>';
  // });

  $('#new_inventory_product').on('click',function(){
   window.location.href = '/inventory/inventory_definitions/new';
  });

</script>
