Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions assets/scss/components/stencil/cart/_cart.scss
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,9 @@ $card-preview-zoom-bottom-offset: 6rem;
}
}

.cart-item-backorder-message {
margin-bottom: 0;
}
}

.cart-item-label {
Expand Down
2 changes: 2 additions & 0 deletions lang/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -727,6 +727,8 @@
"change_product_options": "Change options for {name}",
"quantity_decrease": "Decrease Quantity of {name}",
"quantity_increase": "Increase Quantity of {name}",
"quantity_backordered": "{quantity} will be backordered",
"quantity_on_hand": "{quantity} ready to ship",
"quantity_error_message":"The quantity should contain only numbers",
"purchase_units": "{quantity, plural, =0{0 units} one {# unit} other {# units}}",
"max_purchase_quantity": "Maximum Purchase:",
Expand Down
18 changes: 17 additions & 1 deletion templates/components/cart/content.html
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,23 @@ <h2 class="cart-item-name">
</button>
{{/if}}
</div>

{{#if stock_position}}
{{#if ../cart.inventory_settings.show_quantity_on_hand}}
{{#all stock_position.quantity_on_hand stock_position.backorder_message}}
<p class="cart-item-backorder-message">{{lang 'products.quantity_on_hand' quantity=stock_position.quantity_on_hand}}</p>
{{/all}}
{{/if}}
{{#if ../cart.inventory_settings.show_quantity_on_backorder}}
{{#if stock_position.quantity_backordered}}
<p class="cart-item-backorder-message">{{lang 'products.quantity_backordered' quantity=stock_position.quantity_backordered}}</p>
{{/if}}
{{/if}}
{{#if ../cart.inventory_settings.show_backorder_message}}
{{#if stock_position.backorder_message}}
<p class="cart-item-backorder-message">{{stock_position.backorder_message}}</p>
{{/if}}
{{/if}}
{{/if}}
</td>

<td class="cart-item-block cart-item-info">
Expand Down