Skip to content

Feature: Add "Last Updated" Timestamp to Dashboard and Analytics Pages #1008

@harshitha0539

Description

@harshitha0539

Description:

Currently, the dashboard and analytics pages display important information, but users cannot easily determine when the data was last refreshed or updated.

Adding a "Last Updated" timestamp will improve transparency and help users understand the freshness of the information being displayed. This is especially useful when monitoring compliance status, analytics, and other dynamic data.

Proposed Changes:

•Display a "Last Updated" label on relevant pages.

•Show the timestamp of the most recent successful data fetch.

•Update the timestamp whenever the page data is refreshed or reloaded.

•Format the timestamp in a user-friendly manner.

•Ensure the design remains consistent with the existing UI.

Example:

Last Updated: 11 Jun 2026, 10:30 AM

Files Likely to be Modified:

Frontend

•frontend/src/pages/Dashboard.tsx

Add state to track the last refresh time.

Display the timestamp in the dashboard UI.

•frontend/src/pages/Analytics.tsx

Show the timestamp when analytics data is loaded or refreshed.

Optional Utility File

•frontend/src/utils/date.ts

Add a reusable helper function for formatting timestamps.

Expected Code Changes:

  1. Store the current time after a successful API call or page refresh.

  2. Create a small UI element to display the timestamp.

  3. Format the date and time for readability.

  4. Reuse the logic across multiple pages if needed.

Benefits:

•Improves user awareness of data freshness.

•Enhances trust in displayed information.

•Provides a better user experience with minimal changes.

•Beginner-friendly contribution suitable for new contributors.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions