forked from DebaucheryLibrarian/traxxx
Added fallback createdAt date to date range.
This commit is contained in:
parent
1ec2b3ac36
commit
029099d4a5
|
@ -7,12 +7,12 @@ const dateRanges = {
|
||||||
latest: () => ({
|
latest: () => ({
|
||||||
after: '1900-01-01',
|
after: '1900-01-01',
|
||||||
before: dayjs.utc().toDate(),
|
before: dayjs.utc().toDate(),
|
||||||
orderBy: 'DATE_DESC',
|
orderBy: ['DATE_DESC', 'CREATED_AT_DESC'],
|
||||||
}),
|
}),
|
||||||
upcoming: () => ({
|
upcoming: () => ({
|
||||||
after: dayjs.utc().toDate(),
|
after: dayjs.utc().toDate(),
|
||||||
before: '2100-01-01',
|
before: '2100-01-01',
|
||||||
orderBy: 'DATE_ASC',
|
orderBy: ['DATE_ASC', 'CREATED_AT_ASC'],
|
||||||
}),
|
}),
|
||||||
new: () => ({
|
new: () => ({
|
||||||
after: '1900-01-01 00:00:00',
|
after: '1900-01-01 00:00:00',
|
||||||
|
@ -22,7 +22,7 @@ const dateRanges = {
|
||||||
all: () => ({
|
all: () => ({
|
||||||
after: '1900-01-01',
|
after: '1900-01-01',
|
||||||
before: '2100-01-01',
|
before: '2100-01-01',
|
||||||
orderBy: 'DATE_DESC',
|
orderBy: ['DATE_DESC', 'CREATED_AT_DESC'],
|
||||||
}),
|
}),
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue