{% extends "admin/base.html" %} {% block title %}订单管理 - 太白购物商城管理后台{% endblock %} {% block page_title %}订单管理{% endblock %} {% block page_description %}管理系统中的所有订单{% endblock %} {% block extra_css %} {% endblock %} {% block content %}
{{ order_stats.get(0, {}).get('count', 0) + order_stats.get(1, {}).get('count', 0) + order_stats.get(2, {}).get('count', 0) + order_stats.get(3, {}).get('count', 0) + order_stats.get(4, {}).get('count', 0) + order_stats.get(5, {}).get('count', 0) + order_stats.get(6, {}).get('count', 0) + order_stats.get(7, {}).get('count', 0) }}
总订单
{{ order_stats.get(1, {}).get('count', 0) }}
待支付
{{ order_stats.get(2, {}).get('count', 0) }}
待发货
{{ order_stats.get(3, {}).get('count', 0) }}
待收货
{{ order_stats.get(5, {}).get('count', 0) }}
已完成
{{ order_stats.get(6, {}).get('count', 0) }}
已取消
重置
订单列表
{% if orders.items %}
{% for order in orders.items %} {% endfor %}
订单号 用户信息 订单金额 订单状态 支付方式 创建时间 操作
{{ order.order_sn }}
ID: {{ order.id }}
{{ order.user.username }}
{% if order.user.phone %} {{ order.user.phone }} {% endif %}
¥{{ "%.2f"|format(order.actual_amount) }}
{% if order.shipping_fee > 0 %} 含运费: ¥{{ "%.2f"|format(order.shipping_fee) }} {% endif %}
{{ order.get_status_text() }} {% if order.payment_method %} {{ order.payment_method }} {% else %} 未设置 {% endif %}
{{ order.created_at.strftime('%Y-%m-%d') }}
{{ order.created_at.strftime('%H:%M:%S') }}
详情 {% if order.status == 2 %} {% endif %} {% if order.status in [2, 3] %} {% endif %} {% if order.can_cancel() %} {% endif %}
{% if orders.pages > 1 %} {% endif %} {% else %}

暂无订单数据

{% endif %}
{% endblock %} {% block extra_js %} {% endblock %}