diff --git a/static/hub.js b/static/hub.js index 62fd580..b0ca8ed 100644 --- a/static/hub.js +++ b/static/hub.js @@ -112,13 +112,20 @@ const items = list.slice(0, 8).map(function (p) { const id = p.inst_id || ""; const sheets = escapeHtml(String(p.sheets != null ? p.sheets : "—")); + const lev = Number(p.contract_leverage != null ? p.contract_leverage : p.leverage); + const levTxt = + Number.isFinite(lev) && lev > 0 + ? " · 约" + lev.toFixed(1) + "×" + : ""; const fromCond = tagOpen && (!opened || opened === id); return ( "
  • " + escapeHtml(id) + " · " + sheets + - "张 · " + + "张" + + escapeHtml(levTxt) + + " · " + fmtPnlHtml(p.pnl_usdt) + (fromCond ? '条件单' : "") + "
  • " diff --git a/templates/dashboard.html b/templates/dashboard.html index ecb4c21..b035552 100644 --- a/templates/dashboard.html +++ b/templates/dashboard.html @@ -15,6 +15,6 @@
    {% endblock %} {% block scripts %} - + {% endblock %}