{% extends "base.html" %} {% block title %}持仓监控 - 国内期货监控系统{% endblock %} {% block extra_css %} {% endblock %} {% block content %}
{{ trading_mode_label }} {% if ctp_status.connected %}CTP 已连接{% else %}CTP 未连接{% endif %} {{ risk_status.status_label }} 权益 {{ '%.2f'|format(capital) }} {% if ctp_account.available is defined and ctp_status.connected %} 可用 {{ '%.2f'|format(ctp_account.available) }} {% endif %}
断线自动重连 · 开盘前 30 分钟自动连接

期货下单

计仓 {{ sizing_mode_label }} {% if sizing_mode == 'fixed' %} · {{ fixed_lots }} 手 {% elif sizing_mode in ('amount', 'risk') %} · {{ '%.0f'|format(fixed_amount) }} 元 {% endif %}

持仓监控

开仓后立即写入本地监控并显示;后台每秒同步 CTP 柜台更新盈亏与手数。刷新页面优先读本地缓存。

加载本地持仓…

品种推荐

最大手数 = floor(权益 × 保证金上限 {{ max_margin_pct }}% ÷ 1手保证金);当前权益 {{ '%.2f'|format(capital) }} 元。 {% if sizing_mode == 'fixed' %}仅显示最大手数 ≥ {{ fixed_lots }} 手的品种。{% endif %} 保证金优先读取 CTP 柜台合约信息。 {% if recommend_updated_at %}每日后台更新 · 最近 {{ recommend_updated_at }}{% else %}等待今日后台刷新…{% endif %}

走势说明:拉取近一周日线;最近三天 K 线高低价重叠度 ≥ 70% 判为震荡,否则按收盘方向判多头/空头;前段震荡、近期突破则标为转多/转空并优先排列。

{% if recommend_rows %} {% for r in recommend_rows %} {% endfor %} {% else %} {% endif %}
品种交易所走势参考价 参考止损参考止盈 1手保证金1手手续费最大手数状态
{{ r.name }} {{ r.main_code or r.ths }} {{ r.exchange }} {% if r.trend_label and r.trend_label != '—' %} {% if r.trend_transition %}★ {% endif %}{{ r.trend_label }} {% else %}—{% endif %} {% if r.price %}{{ r.price }}{% else %}—{% endif %} {% if r.ref_stop_loss %}{{ r.ref_stop_loss }}{% else %}—{% endif %} {% if r.ref_take_profit %}{{ r.ref_take_profit }}{% else %}—{% endif %} {% if r.margin_one_lot %}{{ r.margin_one_lot }}{% if r.margin_source == 'ctp' %} (柜台){% endif %}{% else %}—{% endif %} {% if r.open_fee_one_lot is defined and r.open_fee_one_lot is not none %}{{ r.open_fee_one_lot }}{% else %}—{% endif %} {% if r.max_lots is not none and r.max_lots > 0 %}{{ r.max_lots }}{% else %}—{% endif %} {{ r.status_label }}
等待今日后台刷新推荐…
{% endblock %} {% block extra_js %} {% endblock %}