I've got a DateTimeInput component in a view and it seems that I cannot select a date older than 10 years from today or 10 years into the future.
Example: for today January 12 2024 I cannot select dates prior to January 12 2014, or beyond January 12 2034.
Any idea why this limitation is there and how we can allow any selection of any date?
I'm developing an interface to a database that has some pretty old dates that can't be edited if needed due to this limitation.
You'e about to enter a very slippery area which is going to require some tinkering with the stylesheet.css resource.
By default, the component goes ten years in either direction when no minDate
or maxDate
is set. When those two properties ARE set, the year dropdown will supply years up to those dates. Now, the problem occurs when you start allowing years all of the way back to, say, 1900. Now you have a dropdown list which is 133 items long. This doesn't display well. You'll need to tinker with the CSS settings for the options of the year dropdown to make it manageable for your users.
2 Likes
OK that makes sense. I can manage the min and max appropriately for the interaction.
Thanks for shedding some light on this.
1 Like