Added date picker filter.

This commit is contained in:
Mike Cao 2020-09-16 16:28:54 -07:00
parent 81789d6723
commit 60b17363e1
4 changed files with 71 additions and 13 deletions

View file

@ -89,7 +89,7 @@ export function getDateRange(value) {
export function getDateRangeValues(startDate, endDate) {
let unit = 'year';
if (differenceInHours(endDate, startDate) <= 72) {
if (differenceInHours(endDate, startDate) <= 48) {
unit = 'hour';
} else if (differenceInCalendarDays(endDate, startDate) <= 90) {
unit = 'day';