feat: 趋势户开仓类型大分歧A/B/小分歧,自动联动趋势波段与复盘

下单监控增加 entry_model 下拉;平仓写入短标签并预填复盘。Binance/OKX 用趋势 profile,Gate 日内仍用手选 trade_style。

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
dekun
2026-07-06 00:18:38 +08:00
parent 21894334f8
commit ea429b2694
20 changed files with 29324 additions and 28549 deletions
+1
View File
@@ -64,6 +64,7 @@
}
if (tab === "trade") {
if (typeof global.refreshOrderDefaults === "function") global.refreshOrderDefaults();
if (typeof global.initOrderEntryModelSelect === "function") global.initOrderEntryModelSelect();
if (global.ManualOrderRrPreview && typeof global.ManualOrderRrPreview.wire === "function") {
global.ManualOrderRrPreview.wire();
}
+1 -1
View File
@@ -1,4 +1,4 @@
*{margin:0;padding:0;box-sizing:border-box}
.order-trade-style-hint{font-size:.78rem;color:#8fc8ff;margin-left:4px;white-space:nowrap}
body{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,sans-serif;background:#0b0d14;color:#eaeaea;padding:14px 20px}
.container{width:100%;max-width:min(1440px,94vw);margin:0 auto;padding:0 clamp(8px,1.5vw,20px)}
.header{display:flex;flex-direction:column;align-items:center;gap:8px;margin-bottom:12px}
+29
View File
@@ -0,0 +1,29 @@
(function (global) {
function syncOrderEntryModelTradeStyle() {
var sel = document.getElementById("order-entry-model");
var hidden = document.getElementById("order-trade-style-hidden");
var hint = document.getElementById("order-trade-style-hint");
if (!sel || !hidden) return;
var map = global.ORDER_ENTRY_MODEL_TRADE_STYLE || {};
var labels = { trend: "趋势单", swing: "波段单" };
var ts = map[sel.value] || "trend";
hidden.value = ts;
if (hint) hint.textContent = labels[ts] || ts;
}
function initOrderEntryModelSelect() {
var sel = document.getElementById("order-entry-model");
if (!sel || sel.dataset.entryModelWired === "1") return;
sel.dataset.entryModelWired = "1";
sel.addEventListener("change", syncOrderEntryModelTradeStyle);
syncOrderEntryModelTradeStyle();
}
global.initOrderEntryModelSelect = initOrderEntryModelSelect;
if (document.readyState === "loading") {
document.addEventListener("DOMContentLoaded", initOrderEntryModelSelect);
} else {
initOrderEntryModelSelect();
}
})(typeof window !== "undefined" ? window : globalThis);