fix: trade_policy 宏使用 with context 修复 500
Jinja imported macros did not receive trade_policy from render context, causing Internal Server Error on all instance pages. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -24,7 +24,7 @@
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
<form id="trend-pullback-form" action="{{ url_for('preview_trend_pullback') }}" method="post" class="form-row">
|
||||
{% from 'trade_policy_fields.html' import trade_policy_symbol, trade_policy_direction %}
|
||||
{% from 'trade_policy_fields.html' import trade_policy_symbol, trade_policy_direction with context %}
|
||||
{{ trade_policy_symbol('symbol', 'trend-symbol', placeholder='BTC 或 ETH/USDT') }}
|
||||
{{ trade_policy_direction('direction', 'trend-direction') }}
|
||||
<input name="leverage" type="number" min="1" step="1" placeholder="杠杆(必填)" required>
|
||||
|
||||
Reference in New Issue
Block a user