Skip to content

Format dates in Product analytics dashboard values and tooltips

Elwyn Benson requested to merge 440212-dashboard-date-formatting into master

What does this MR do and why?

Formats dates within analytics dashboards in a human friendly format:

  • within chart tooltip titles
    • line charts
    • column charts
  • within visualization values themselves

Dates are formatted with our default formatDate format, and include times along with dates, since we don't know which type of date/time data might be displayed in any given dashboard.

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Screenshots or screen recordings

Before After Notes
image image Chart tooltip titles
image image Visualization values

How to set up and validate locally

  1. Follow these instructions to setup Product Analytics in GDK.
  2. Onboard Product Analytics by setting up the feature at Project > Analytics > Analytics dashboards.
  3. Generate some events for this project so your dashboards have data.

Verify chart tooltips:

  1. Open a dashboard, e.g. Project > Analytics > Analytics dashboards > Behaviour.
  2. Hover over a point in a line or column chart, view the tooltip title

Verify visualization data:

Generate a visualization which displays date values, e.g.:

  1. Visit the visualization designer at Project > Analytics > Analytics dashboards > Visualization designer.
  2. If you have AI enabled, prompt session start times, otherwise select measures/dimensions to get startTime or endTime or derivedTStamp ro some such
  3. Select data table visualization type
  4. Verify rendered date values are formatted

Related to #440212

Edited by Elwyn Benson

Merge request reports