Sha256: c4e3a799228647bee9677f834f9ba9cce467dbf7c4baba9957881fce779e2c13

Contents?: true

Size: 1.61 KB

Versions: 16

Compression:

Stored size: 1.61 KB

Contents

<% variant = line_item.variant -%>
<%= order_form.fields_for :line_items, line_item do |item_form| -%>
  <tr class="<%= cycle('', 'alt') %> line-item">
    <td class="cart-item-image" data-hook="cart_item_image">
      <% if variant.images.length == 0 %>
        <%= link_to image_tag(variant.product.display_image.attachment(:small)), variant.product %>
      <% else %>
        <%= link_to image_tag(variant.images.first.attachment.url(:small)), variant.product %>
      <% end %>
    </td>
    <td class="cart-item-description" data-hook="cart_item_description">
      <h4><%= link_to line_item.name, product_path(variant.product) %></h4>
      <%= variant.options_text %>
      <% if line_item.insufficient_stock? %>
        <span class="out-of-stock">
          <%= Spree.t(:out_of_stock) %>&nbsp;&nbsp;<br />
        </span>
      <% end %>
      <span class="line-item-description" data-hook="line_item_description">
        <%= line_item_description_text(line_item.description) %>
      </span>
    </td>
    <td class="cart-item-price" data-hook="cart_item_price">
      <%= line_item.single_money.to_html %>
    </td>
    <td class="cart-item-quantity" data-hook="cart_item_quantity">
      <%= item_form.number_field :quantity, min: 0, class: "line_item_quantity", size: 5 %>
    </td>
    <td class="cart-item-total" data-hook="cart_item_total">
      <%= line_item.display_amount.to_html unless line_item.quantity.nil? %>
    </td>
    <td class="cart-item-delete" data-hook="cart_item_delete">
      <%= link_to image_tag('icons/delete.png'), '#', class: 'delete', id: "delete_#{dom_id(line_item)}" %>
    </td>
  </tr>
<% end -%>

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
solidus_frontend-2.4.2 app/views/spree/orders/_line_item.html.erb
solidus_frontend-2.2.2 app/views/spree/orders/_line_item.html.erb
solidus_frontend-2.4.1 app/views/spree/orders/_line_item.html.erb
solidus_frontend-2.3.1 app/views/spree/orders/_line_item.html.erb
solidus_frontend-2.4.0 app/views/spree/orders/_line_item.html.erb
solidus_frontend-2.4.0.rc1 app/views/spree/orders/_line_item.html.erb
solidus_frontend-2.4.0.beta1 app/views/spree/orders/_line_item.html.erb
solidus_frontend-2.3.0 app/views/spree/orders/_line_item.html.erb
solidus_frontend-2.3.0.rc3 app/views/spree/orders/_line_item.html.erb
solidus_frontend-2.3.0.rc2 app/views/spree/orders/_line_item.html.erb
solidus_frontend-2.3.0.rc1 app/views/spree/orders/_line_item.html.erb
solidus_frontend-2.3.0.beta1 app/views/spree/orders/_line_item.html.erb
solidus_frontend-2.2.1 app/views/spree/orders/_line_item.html.erb
solidus_frontend-2.2.0 app/views/spree/orders/_line_item.html.erb
solidus_frontend-2.2.0.rc1 app/views/spree/orders/_line_item.html.erb
solidus_frontend-2.2.0.beta1 app/views/spree/orders/_line_item.html.erb