Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[ShopBundle] Show shipping promotions on checkout summary page
[AdminBundle] Show shipping promotions on order show page
- Loading branch information
Showing
3 changed files
with
53 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
{% import "@SyliusShop/Common/Macro/money.html.twig" as money %} | ||
|
||
{% set orderShippingPromotionAdjustment = constant('Sylius\\Component\\Core\\Model\\AdjustmentInterface::ORDER_SHIPPING_PROMOTION_ADJUSTMENT') %} | ||
|
||
<td colspan="2" id="promotion-shipping-discounts"> | ||
{% set orderShippingPromotions = sylius_aggregate_adjustments(order.getAdjustmentsRecursively(orderShippingPromotionAdjustment)) %} | ||
{% if not orderShippingPromotions is empty %} | ||
<div class="ui relaxed divided list"> | ||
{% for label, amount in orderShippingPromotions %} | ||
<div class="item"> | ||
<div class="content"> | ||
<div class="header">{{ label }}</div> | ||
<div class="description"> | ||
{{ money.convertAndFormat(amount) }} | ||
</div> | ||
</div> | ||
</div> | ||
{% endfor %} | ||
</div> | ||
{% endif %} | ||
</td> | ||
<td colspan="4" class="right aligned" id="shipping-total"> | ||
{{ 'sylius.ui.shipping_total'|trans }}: | ||
{{ money.format(order.shippingTotal, order.currencyCode) }} | ||
</td> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters