Commit Graph

5 Commits (eb8895966017355774c72faff2aabc3c06afc16f)

Author SHA1 Message Date
Kirubakaran eb88959660 fix: analytics page 2025-09-20 21:14:30 +05:30
Kirubakaran 219fbd92b4 fix: average swap time in analytics page 2025-09-16 02:03:40 +05:30
Kirubakaran 7f0a93a80d feat(app): implement comprehensive analytics and reporting features
Analytics Page:
- Implemented a new, dynamic analytics page with date filtering.
- Added KPI summary tiles for total, completed, and aborted swaps, average swap time, and station uptime.
- Included three interactive charts: Swap Activity Over Time, Hourly Swap Distribution, and Swap Abort Reasons.
- Added a Slot Utilization Heatmap for at-a-glance diagnostics.
- Styled charts for the dark theme and fixed axis scaling issues.

Station Selection Page:
- Enhanced the station selection page to display live daily swap statistics on each station card.

Backend API:
- Created a new '/api/analytics' endpoint to serve all KPI and chart data.
- Created a new '/api/stations/daily-stats' endpoint.

Fixes & Refactoring:
- Centralized all common header logic into common-header.js to resolve script conflicts.
- Improved dashboard WebSocket handler to correctly process partial data payloads.
2025-09-15 03:56:47 +05:30
Kirubakaran f61af015ad fix: enhance the UI of status bar 2025-09-14 19:15:18 +05:30
Kirubakaran 526bc8e8fa feat(app): Implement station removal and refactor to common header
This major update introduces the ability to remove stations and significantly refactors the frontend architecture for better code reuse and maintainability.

### Features
- **Remove Station:** Implemented full-stack station removal functionality.
  - Added `DELETE /api/stations/<id>` endpoint to the backend.
  - The MQTT client for the removed station is now gracefully disconnected.
  - Added a trash can icon button to the station selection card for removal.
- **Enhanced UI:** Improved the UI on several pages.
  - Added icons for Product ID and Location on station cards.
  - Updated card layout to display Product ID directly under the station name.
  - Implemented a fully functional, dynamic header for the dashboard, logs, and analytics pages.
2025-09-14 05:34:57 +05:30