diff --git a/mofin_db.py b/mofin_db.py index 88f55098..677ef214 100644 --- a/mofin_db.py +++ b/mofin_db.py @@ -1557,7 +1557,7 @@ def flush_rec_digest(max_items=5): _mid = f"{(_el+_eh)/2:.2f}" if _el > 0 and _eh > _el else "—" _badge = "💰可执行" if it['code'] in _exec_codes else "⏳排队" lines.append(f"• {_badge} {it.get('name') or it['code']}({it['code']}) {it['signal']}" - f" 区{_el or '—'}~{_eh or '—'}(中{_mid})" + f" 区{_el or '—'}→{_mid}←{_eh or '—'}" f" 损{it.get('stop_loss') or '—'} 盈{it.get('take_profit') or '—'}" f" {_rr_txt} 仓位{it.get('position') or '—'}") if it.get('_stale_warn'): @@ -1615,7 +1615,7 @@ def push_recommend_alert(conn, code: str): from alert_helper import notify, ACTION _mid_xmpp = f"{(el+eh)/2:.2f}" if el > 0 and eh > el else "—" msg = (f"📈 {name or code}({code}) 价{price}→12维{sig}!" - f"区间{el}~{eh}(中{_mid_xmpp}) 损{sl} 盈{tp} RR={rr or 0} 仓位{pos or '-'}") + f"区间{el}→{_mid_xmpp}←{eh} 损{sl} 盈{tp} RR={rr or 0} 仓位{pos or '-'}") return notify("买入信号", msg, ACTION) except Exception as e: print(f" [ALERT] {code} 推送异常: {e}", flush=True) diff --git a/static/index.html b/static/index.html index f35d5eb8..d3ba001b 100644 --- a/static/index.html +++ b/static/index.html @@ -462,8 +462,8 @@ function renderWatchlist() {
${stocks.map(s => { const el = s.entry_low||0, eh = s.entry_high||0; - const mid = (el > 0 && eh > el) ? ('(中' + ((el+eh)/2).toFixed(2) + ')') : ''; - const buyZone = el + '~' + eh + mid; + const mid = (el > 0 && eh > el) ? (' ' + ((el+eh)/2).toFixed(2) + ' ') : '~'; + const buyZone = el + mid + eh; const rr = s.rr_ratio || 0; const sl = s.stop_loss || 0; const tp = s.take_profit || 0; @@ -745,7 +745,7 @@ async function openStock(code) {