Clean up review charts: crop windows, simplify entry/exit markers.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
dekun
2026-10-21 17:27:49 +08:00
parent 39bff20d60
commit 11c14fbb21
4 changed files with 162 additions and 109 deletions
+3 -3
View File
@@ -63,15 +63,15 @@
<div class="card" style="margin-top:14px">
<h3>四周期 K 线(M1 / M5 / M15 / H1)</h3>
<p class="muted">
K 线由客户端上报后<strong>写入服务器 bars 表保存</strong>;打开复盘时按开/平仓时间窗口<strong>读取</strong>。
蓝线/点=入场,黄线/点=出场,紫虚线=入场→出场。
客户端上报写入服务器;复盘读取。蓝=入场,黄=出场(价差很小时合并为一条「入/出」线)。图内只显示成交前后一段 K 线。
</p>
<div class="chart-grid" style="margin-top:10px">
{% for tf in ['M1','M5','M15','H1'] %}
<div class="chart-box">
<h4>{{ tf }} · {{ charts[tf]|length }} 根</h4>
<h4>{{ tf }}</h4>
{% if charts[tf] %}
<canvas class="chart-canvas" id="chart-{{ tf }}"
data-tf="{{ tf }}"
data-bars='{{ charts[tf]|tojson }}'
data-open-ts="{{ trade.open_time or '' }}"
data-close-ts="{{ trade.close_time or '' }}"