Ir para o conteúdo principal
CloudStudio

Time Period Selection

Introduction

The platform allows time period selection in various situations, such as:

  • Dashboards
  • Widgets
  • Historical data visualization
  • Reports

In all cases, the user interface presents a component like the following:

Dropdown menu for selecting time periods with predefined and custom ranges

Choosing absolute and relative time periods

This component allows selecting a date range (including time, if applicable), both in absolute and relative form. Below is how this feature is used.

Absolute time periods

To specify an absolute time period, use the buttons to enter dates. You can choose a start date and time, as well as an end date and time.

Time selector dropdown menu highlighting calendar buttons to set date and time

When pressing the "Apply" button, the selector will display the selected period:

Time selector displaying an applied absolute date and time period

Relative time periods

To choose relative time periods, you can use the options bar on the right, as shown here, as well as enter arbitrary relative time expressions. The following image shows the list of predefined relative time options:

Date picker menu displaying the list of predefined relative time options

However, you can also enter any relative time period by typing it in the respective "From" and "To" fields, as shown in the following example:

Time period selector with relative expressions entered into From and To fields

The syntax for relative expressions is as follows:

  • now always represents the current date and time.
  • Then, you can add or subtract an arbitrary amount of seconds, minutes, hours, days, months, or years.
  • s represents seconds
  • m represents minutes
  • h represents hours
  • d represents days
  • M represents months
  • y represents years
  • Optionally, you can "round" the date to the beginning of the day, month, or year by adding any of the following modifiers:
  • /d represents the beginning of the day
  • /M represents the beginning of the month
  • /y represents the beginning of the year

Examples of relative expressions:

Start expressionEnd expressionMeaning
now/dnowFrom the beginning of today until now.
now/MnowFrom the beginning of the month until now.
now-1d/dnow/dYesterday.
now-6hnowThe last 6 hours.
now-30mnowThe last 30 minutes.
now-14/dnowThe last 15 days (including today).

Mixed time periods

You can also use a combination of fixed and relative periods. For example, to indicate the time period "from January 1, 2021 until now", you can enter the absolute date "January 1, 2021" in the "from" field, and then the relative expression "now" in the "to" field.

Última atualização em

Nesta página