Filter options
Reading time:
Go to Dimension -> Filter
Single selection / Multi selection
If this option is enabled, you can choose only a single value from filter
If this opion is disabled, you can choose multiple values from filter.
Default value
You can set first value, last value or a specific value as default value,For the calendar type filter, you can set interval to default value, and then define the start date and the end date.
You can enter a static date or a dynamic date.
For static date, you can entre like '2024-01-01',
For dynamic date, we use moment.js (https://momentjs.com/docs/#/manipulating/)
Here some example :
Current year :Â Â Â Â Â Â Â Â Â Â Â Â Â Â
- startdate :Â moment().startOf('year');Â Â Â Â
- Enddate :Â moment().subtract('days',1).format();Â
Last year :Â Â Â Â Â Â Â Â Â Â Â Â Â Â
- startdate :Â moment().subtract(1,'year').startOf('year').format();Â Â Â Â
- Enddate :Â moment().subtract(1,'year').endOf('year').format();Â
Current month :Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â
- startdate :Â moment().startOf('months');Â ;Â Â Â Â
- Enddate :Â moment().subtract('days',1).format();Â
Last month :Â Â Â Â Â Â Â Â Â Â Â Â Â Â
- startdate :Â moment().subtract('months',1).startOf('month').format();Â Â Â Â
- Enddate :Â moment().subtract('months',1).endOf('month').format();
Last 10 years :Â Â Â Â Â Â Â
- startdate :Â Â moment().startOf('year').subtract(10, 'years');Â Â Â Â Â Â Â Â Â Â
- Enddate :Â moment().endOf('year').subtract(10, 'years');
A sliding year:
- Startdate : moment().subtract('Year',1);
- Enddate :Â moment().format();
A sliding month:
- Startdate : moment().subtract(1, 'months');
- Enddate :Â moment().format();
Enable search
When a large number of filters are available, locating a specific field can become difficult. We can enable this option to improve usability and help users find fields more quickly.
