diff --git a/myproject/orders/templates/orders/order_list.html b/myproject/orders/templates/orders/order_list.html new file mode 100644 index 0000000..78fff84 --- /dev/null +++ b/myproject/orders/templates/orders/order_list.html @@ -0,0 +1,203 @@ +{% extends 'base.html' %} + +{% block title %}Заказы{% endblock %} + +{% block content %} +
| Номер | +Клиент | +Дата доставки | +Тип | +Статус | +Сумма | +Оплата | +Создан | +Действия | +
|---|---|---|---|---|---|---|---|---|
| + + {{ order.order_number }} + + | +{{ order.customer.name }} | +
+ {% if order.delivery_date %}
+ {{ order.delivery_date|date:"d.m.Y" }}
+ {% if order.delivery_time_start %}
+ {{ order.delivery_time_window }} + {% endif %} + {% else %} + Не указано + {% endif %} + |
+ + {% if order.is_delivery %} + Доставка + {% else %} + Самовывоз + {% endif %} + | ++ {% if order.status == 'new' %} + Новый + {% elif order.status == 'confirmed' %} + Подтвержден + {% elif order.status == 'in_assembly' %} + В сборке + {% elif order.status == 'in_delivery' %} + В доставке + {% elif order.status == 'delivered' %} + Доставлен + {% elif order.status == 'cancelled' %} + Отменен + {% endif %} + | +{{ order.total_amount }} руб. | ++ {% if order.payment_status == 'paid' %} + Оплачен + {% elif order.payment_status == 'partial' %} + Частично + {% else %} + Не оплачен + {% endif %} + | +{{ order.created_at|date:"d.m.Y H:i" }} | ++ + + + + + + | +