Align trade record verify/edit UX with Binance instance single-row prompts.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
dekun
2026-06-30 22:02:48 +08:00
parent b6b7bfb248
commit 32838daae0
5 changed files with 259 additions and 139 deletions
+26
View File
@@ -47,6 +47,9 @@
html += '</div>';
html += '<div class="records-detail-actions">';
if (data.id) {
html += '<button type="button" class="btn-records-action review-edit-btn" disabled>核对修改</button>';
}
if (data.fill_review_url) {
html += '<a href="' + data.fill_review_url + '" class="btn-fill">填入复盘</a>';
}
@@ -56,6 +59,29 @@
html += '</div>';
body.innerHTML = html;
var reviewBtn = body.querySelector('.review-edit-btn');
if (reviewBtn && data.id) {
reviewBtn.setAttribute('data-trade-edit', JSON.stringify({
id: data.id,
symbol_name: data.symbol_name || data.symbol,
monitor_type: data.monitor_type,
direction: data.direction_code || (data.direction === '做多' ? 'long' : 'short'),
entry_price: data.entry_price,
close_price: data.close_price,
stop_loss: data.stop_loss,
take_profit: data.take_profit,
lots: data.lots,
margin: data.margin,
holding_minutes: data.holding_minutes,
open_time: data.open_time,
close_time: data.close_time,
pnl: data.pnl,
result: data.result
}));
}
if (typeof window.toggleTradeReviewMode === 'function') {
window.toggleTradeReviewMode();
}
mask.classList.add('show');
}