Sha256: c5bdf150e0641d91982170098ae94aa349ec35af68b2e0d77a71512a59732aee

Contents?: true

Size: 1.79 KB

Versions: 4

Compression:

Stored size: 1.79 KB

Contents

<table class="table table-bordered">
  <tbody id='line-items'>
  <tr>
    <%= hook :order_details_line_items_headers do %>
      <th><%= t('item_description') %></th>
      <th class="price"><%= t('price') %></th>
      <th class="qty"><%= t('qty') %></th>
      <th class="total"><span><%= t('total') %></span></th>
    <% end %>
  </tr>

  <% @order.line_items.each do |item| %>
    <tr>
      <%- locals = {:item => item} %>
      <%= hook :order_details_line_item_row, locals do %>
        <td width="300"><%=item.variant.product.name%> <%= "(" + variant_options(item.variant) + ")" unless item.variant .option_values.empty? %></td>
        <td class="price"><%= number_to_currency item.price %></td>
        <td class="qty"><%=item.quantity%></td>
        <td class="total"><span><%= number_to_currency (item.price * item.quantity)%></span></td>
      <% end %>
    </tr>
  <% end %>
  </tbody>
  <%= hook :order_details_subtotal do %>
    <tbody id='subtotal'>
    <tr class="total" id="subtotal-row">
      <td colspan="3"><b><%= t('subtotal') %>:</b></td>
      <td class="total"><span><%= number_to_currency @order.item_total %></span></td>
    </tr>
    </tbody>
  <% end %>
  <%= hook :order_details_adjustments do %>
    <tbody id="order-charges">
    <% @order.adjustments.each do |adjustment| %>
      <tr class="total">
        <td colspan="3"><strong><%= adjustment.label %></strong></td>
        <td class="total"><span><%= number_to_currency adjustment.amount %></span></td>
      </tr>
    <% end %>
    </tbody>
  <% end %>
  <%= hook :order_details_total do %>
    <tbody id='order-total'>
    <tr class="total">
      <td colspan="3"><b><%= t('order_total') %>:</b></td>
      <td class="total"><span id="order_total"><%= number_to_currency @order.total %></span></td>
    </tr>
    </tbody>
  <% end %>
</table>

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
synergy_bootstrap_theme-0.0.4 app/views/shared/_order_details.html.erb
synergy_bootstrap_theme-0.0.3 app/views/shared/_order_details.html.erb
synergy_bootstrap_theme-0.0.2 app/views/shared/_order_details.html.erb
synergy_bootstrap_theme-0.0.1 app/views/shared/_order_details.html.erb