Commit Graph

2 Commits

Author SHA1 Message Date
37cea90b4e Refactor CPU statistics formatting for improved precision
Some checks failed
CI / ci (push) Has been cancelled
- Updated JavaScript to ensure CPU total, free, and usage values are formatted as numbers with one decimal place for consistency.
- Modified HTML template to apply float formatting to the displayed free CPU value, enhancing clarity in metrics presentation.
2026-02-12 14:38:40 +03:00
6a27fecb13 Add dashboard statistics module and refactor views for metrics handling
All checks were successful
CI / ci (push) Successful in 14s
- Introduced a new `stats.py` module to encapsulate dashboard statistics building and cache key constants.
- Refactored `views.py` to utilize the new `build_stats` function for constructing metrics context, improving code organization and readability.
- Updated Prometheus query handling to streamline metrics fetching with a new `fetch_dashboard_metrics` function.
- Enhanced test cases to reflect changes in metrics fetching and context building, ensuring accurate functionality.
- Added new HTML templates for displaying detailed resource allocation and flavor statistics on the dashboard.
2026-02-07 18:39:28 +03:00