Posted in: SPARK UI Toolkit Controls
Mikael ErikssonNovember 9, 2016 at 4:15 am #3022
In our datepickers we want to have the format “yyyy-mm-dd” for presenting. However we have a request that the users should be able to ender the dates without the dashes eg. 20161109. I have tried to find a configuration or using events to handle this but have not succeded.
Do you have any ideas/suggestions on how such a thing could be handled with a Datepicker? (Or some simple way to do it with a combo of textfield and datepicker)
When experimenting a bit around this I also came up with two issues:
Issue 1 – It seem that the datepicker requires some separator between the different parts of the date. I set the format to yyyymmdd, then the output date was formatted correctly after chosing a date in the calendar view. But if I changed the date in the textfield I always got a format error even if the date should parse.
Issue 2 – I had the datepicker in a horizontal layout. If the horizontal layout have its layout as “Justified” the error message from the datepicker i shown correctly but if the layout is “Left” the error message is partly hidden. See the attached pictures for this.
/MikaelSPARK SupportNovember 16, 2016 at 10:54 am #3085
I was able to replicate your first issue. The issue with the Date Picker control flagging the “yyyymmdd” format as invalid has been logged as a bug and will be fixed in an upcoming version.
I was not able to replicate the issue with Horizontal Layout clipping the error message text. You may wish to try specifying some additional height and change the vertical alignment. Please provide more details on your configuration if you would like for me to take a look at it.
Stephen P.Mikael ErikssonNovember 18, 2016 at 8:03 am #3118
I did not do anything special for the configuraation, just a horizontal layout with three elements, the last beeing the datepicker.
Thank you for the Feedback. That is a great suggestion. I will ad this to our backlog as a Feature Request.
The Date Picker does have the option for placeholder text, but it does not write the dashes for the user.
You must be logged in to reply to this topic.