Reporte de mínimos y máximos por punto de venta
<%= notice %>
Lista de productos
<%= hidden_field_tag 'title_for_print' %>
| # | Producto | Precio unitario |
Línea | Sublínea | Cantidad recomendada a comprar |
Total | <% total = 0 %> <% @products.each_with_index do |available, key| %> <% category = available.product.categories[0] %>
|---|---|---|---|---|---|---|
| <%= key += 1 %> | <%= available.product.full_display %> | <%= number_to_currency(available.product.price_base, precision: 2) %> | <%= category.parent_id.zero? ? category.category : category.parent.category %> | <%= category.category %> | <%= quantity = calculate_restock(available) %> | <%= number_to_currency((quantity * available.product.price_base), precision: 2) %> |
Total