Created
October 11, 2020 19:47
-
-
Save NandoKstroNet/0a15886fd4fe3413b9a9326341576045 to your computer and use it in GitHub Desktop.
Tela Obrigado por Sua Compra - Curso Symfony 5 Mastery http://codeexperts.com.br
This file contains hidden or 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
{% extends 'front.html.twig' %} | |
{% block title %}Obrigado por sua compra!{% endblock %} | |
{% block body %} | |
<div class="row mt-5"> | |
<div class="col-12"> | |
<div class="row"> | |
<div class="col-12"> | |
<h4>Obrigado por sua compra!</h4> | |
<hr> | |
</div> | |
</div> | |
</div> | |
<div class="col-12 pt-5"> | |
<div class="row d-flex justify-content-between align-items-center"> | |
<div class="col-6"><h5>Pedido</h5></div> | |
<div class="col-6 text-right"><h5>N˚ #122233</h5></div> | |
</div> | |
<div class="row"> | |
<div class="col-12"> | |
<hr> | |
</div> | |
{% set total = 0 %} | |
{% for item in cart %} | |
<div class="col-12"> | |
<p> | |
{% set subtotal = item.amount*item.price %} | |
{% set total = total + subtotal %} | |
{{ item.amount }}x {{ item.name }} (R$ {{ item.price|number_format(2, ',', '.') }}) - Subtotal: R$ {{ subtotal|number_format('2', ',', '.') }} | |
</p> | |
</div> | |
{% endfor %} | |
<div class="col-12"> | |
<hr> | |
<strong>Total: R$ {{ total|number_format(2, ',', '.') }}</strong> | |
</div> | |
</div> | |
</div> | |
</div> | |
{% endblock %} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment