From c109598e4e208a71ac78842bc270ec67c3270cf1 Mon Sep 17 00:00:00 2001 From: fish Date: Tue, 28 Jul 2026 14:59:19 +0800 Subject: [PATCH] =?UTF-8?q?=E5=90=88=E7=BA=A6=E7=AE=A1=E7=90=86=E6=94=AF?= =?UTF-8?q?=E6=8C=81=E6=8C=89=E4=BA=A4=E6=98=93=E6=89=80=E7=AD=9B=E9=80=89?= =?UTF-8?q?=E5=93=81=E7=A7=8D=EF=BC=9B=E5=93=81=E7=A7=8D=E5=88=97=E8=A1=A8?= =?UTF-8?q?=E6=8C=89=E4=BA=A4=E6=98=93=E6=89=80=E5=88=86=E7=BB=84=E5=B1=95?= =?UTF-8?q?=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Opus 4.7 --- ft-app/app/templates/admin.html | 87 ++++++++++++++++++++++++--------- 1 file changed, 63 insertions(+), 24 deletions(-) diff --git a/ft-app/app/templates/admin.html b/ft-app/app/templates/admin.html index fa5e71f..678d5c0 100644 --- a/ft-app/app/templates/admin.html +++ b/ft-app/app/templates/admin.html @@ -118,25 +118,38 @@ {% if products %} -
- - - {% for p in products %} - - - - - - - - - {% endfor %} -
代码名称交易所每点合约数操作
{{ p.code }}{{ p.name }}{{ exchange_names.get(p.exchange, p.exchange) }}{{ p.point_value }}{{ p.contracts|length }} -
- -
-
+ {% for ex in exchanges %} + {% set ex_products = products | selectattr('exchange', 'equalto', ex[0]) | list %} + {% if ex_products %} +
+
+ + {{ ex[1] }} + {{ ex_products|length }} 个品种 +
+
+ {% endif %} + {% endfor %} {% else %}
暂无品种,请先新建。
{% endif %} @@ -146,16 +159,22 @@
{% if products %} {# ── Add contract form ── #} -
+
添加合约
+
+ + +
- +
@@ -208,6 +227,26 @@