yumoqing 99e6fed5ef refactor: replace JS polling with RefreshWidget
- Delete dashboard_refresh.js (no longer needed)
- Add api/dashboard_content.dspy returns dynamic UI with live data
  (queries llmusage + users tables server-side, returns full widget tree)
- Simplify index.ui to use RefreshWidget with period_seconds=10
- ChartBar in dashboard_content.dspy auto-fetches top models via data_url
- load_path.py updated separately in sage repo
2026-05-24 16:31:29 +08:00

30 lines
713 B
XML

{
"widgettype": "VBox",
"options": {
"width": "100%",
"height": "100%",
"padding": "20px",
"bgcolor": "#f0f2f5"
},
"subwidgets": [
{
"widgettype": "Text",
"options": {
"text": "Dashboard",
"fontSize": "24px",
"fontWeight": "bold",
"color": "#333",
"marginBottom": "20px"
}
},
{
"widgettype": "RefreshWidget",
"id": "dashboard_refresh",
"options": {
"period_seconds": 10,
"url": "{{entire_url('api/dashboard_content.dspy')}}"
}
}
]
}