Files
phone-store/templates/checkout.html
T

62 lines
2.5 KiB
HTML
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
{% extends "base.html" %}
{% block title %}Оформление заказа{% endblock %}
{% block content %}
<section class="checkout-section">
<div class="container">
<h1 class="page-title">Оформление заказа</h1>
<div class="checkout-layout">
<div class="checkout-form-wrapper">
<form method="POST" class="checkout-form" id="checkout-form">
<div class="form-group">
<label for="name">Имя покупателя *</label>
<input type="text" id="name" name="name" required
value="{{ name or '' }}"
placeholder="Иван Иванов"
minlength="2">
</div>
<div class="form-group">
<label for="phone">Номер телефона *</label>
<input type="tel" id="phone" name="phone" required
value="{{ phone or '' }}"
placeholder="+7 (999) 123-45-67"
minlength="10">
</div>
<div class="form-group">
<label for="address">Адрес доставки *</label>
<textarea id="address" name="address" required
rows="3"
placeholder="Город, улица, дом, квартира"
minlength="5">{{ address or '' }}</textarea>
</div>
<button type="submit" class="btn btn-primary btn-large btn-block">
Подтвердить заказ
</button>
</form>
</div>
<div class="order-summary">
<h3>Ваш заказ</h3>
<ul class="order-items">
{% for item in items %}
<li>
<span>{{ item.name }} × {{ item.quantity }}</span>
<span>{{ "{:,.0f}".format(item.price * item.quantity).replace(',', ' ') }} ₽</span>
</li>
{% endfor %}
</ul>
<div class="order-total">
<span>Итого:</span>
<span>{{ "{:,.0f}".format(total).replace(',', ' ') }} ₽</span>
</div>
</div>
</div>
</div>
</section>
{% endblock %}