You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am using daterangepicker version 2.1.25 and need to include a range option labeled "All".
When switching from "All" to a custom range, I set the date range from 10 years ago to today to prevent confusion. However, the issue is that we need to display today’s date when switching from "All" to a custom range.
Currently, I have set:
All: [moment().startOf('day'), moment().endOf('day')]
The problem is that when I try to filter using today’s date in the picker, it triggers the "All" range, causing it to fetch all data instead of just today's data.
How can I resolve this issue? Any guidance would be appreciated.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
I am using daterangepicker version 2.1.25 and need to include a range option labeled "All".
When switching from "All" to a custom range, I set the date range from 10 years ago to today to prevent confusion. However, the issue is that we need to display today’s date when switching from "All" to a custom range.
Currently, I have set:
All: [moment().startOf('day'), moment().endOf('day')]
The problem is that when I try to filter using today’s date in the picker, it triggers the "All" range, causing it to fetch all data instead of just today's data.
How can I resolve this issue? Any guidance would be appreciated.
Beta Was this translation helpful? Give feedback.
All reactions