Align instance dashboard with hub snapshot+SSE pattern.
Background poll builds a memory snapshot; the page reads snapshot and refreshes on SSE instead of hitting heavy exchange APIs on each load. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -9520,12 +9520,19 @@ register_trade_records_api(
|
||||
app_tz=APP_TZ,
|
||||
)
|
||||
|
||||
def _dashboard_enrich_orders(items):
|
||||
from lib.instance.instance_dashboard_lib import enrich_order_items_with_marks
|
||||
|
||||
return enrich_order_items_with_marks(items, get_price=get_price)
|
||||
|
||||
|
||||
from lib.instance.instance_dashboard_register import register_instance_dashboard_routes
|
||||
|
||||
register_instance_dashboard_routes(
|
||||
app,
|
||||
login_required=login_required,
|
||||
get_db=get_db,
|
||||
enrich_orders=_dashboard_enrich_orders,
|
||||
hedge_enabled=False,
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user