adding discount section in cart on Brooklyn theme

Highlighted
Tourist
3 0 1

hi there . i'm trying to add a discont section on the cart in the Brooklyn theme . I set the cart in page mode . I found this code on the documentation but doesn't seems to work .

<!-- Cart subtotal -->
Subtotal: {{ cart.items_subtotal_price | money }}
<!-- Cart level discounts -->
{%- if cart.cart_level_discount_applications != blank -%}
Discounts:
<ul>
{%- for discount_application in cart.cart_level_discount_applications -%}
<li>{{- discount_application.title -}}
-{{ discount_application.total_allocated_amount | money }}</li>
{%- endfor -%}
</ul>
{%- endif -%}
<!-- Final cart total -->
Total: {{ cart.total_price | money }}

thanks for the help .

0 Likes
Highlighted
Tourist
3 0 1

so apparently this code work just for 'automatic discount' for code discount you need to install an app

0 Likes