commerce-cart-flyout-offcanvas-contents-items.html.twig in Commerce Cart Flyout 8
<table class="cart-block--offcanvas-cart-table table">
<tbody>
<% _.each(cart.order_items, function(orderItem, key) { %>
<tr>
<td class="cart-block--offcanvas-cart-table__title"><%- orderItem.title %></td>
<td class="cart-block--offcanvas-cart-table__quantity">
<input type="number" data-key="<% print(key) %>" min="1" value="<% print(parseInt(orderItem.quantity)) %>" style="width: 35px" />
</td>
<td class="cart-block--offcanvas-cart-table__price"><%= orderItem.total_price.formatted %></td>
<td class="cart-block--offcanvas-cart-table__remove">
<button value="<% print(JSON.stringify([cart.order_id, orderItem.order_item_id])) %>" class="button btn">x</button>
</td>
</tr>
<% }) %>
</tbody>
<tfoot>
<tr>
<td></td>
<td colspan="3">
<button type="submit" class="cart-block--offcanvas-contents__update button btn btn-primary">{{ 'Update quantities'|t }}</button>
</td>
</tr>
</tfoot>
</table>
File
templates/commerce-cart-flyout-offcanvas-contents-items.html.twig
View source
- <table class="cart-block--offcanvas-cart-table table">
- <tbody>
- <% _.each(cart.order_items, function(orderItem, key) { %>
- <tr>
- <td class="cart-block--offcanvas-cart-table__title"><%- orderItem.title %></td>
- <td class="cart-block--offcanvas-cart-table__quantity">
- <input type="number" data-key="<% print(key) %>" min="1" value="<% print(parseInt(orderItem.quantity)) %>" style="width: 35px" />
- </td>
- <td class="cart-block--offcanvas-cart-table__price"><%= orderItem.total_price.formatted %></td>
- <td class="cart-block--offcanvas-cart-table__remove">
- <button value="<% print(JSON.stringify([cart.order_id, orderItem.order_item_id])) %>" class="button btn">x</button>
- </td>
- </tr>
- <% }) %>
- </tbody>
- <tfoot>
- <tr>
- <td></td>
- <td colspan="3">
- <button type="submit" class="cart-block--offcanvas-contents__update button btn btn-primary">{{ 'Update quantities'|t }}</button>
- </td>
- </tr>
- </tfoot>
- </table>