[OutSystems UI Style Guide Preview] Datepicker configurations

Forge Component
(7)
Published on 7 Mar (2 weeks ago) by OutSystems R&D
7 votes
Published on 7 Mar (2 weeks ago) by OutSystems R&D

Hi Team,

Why setDefaultDate: true is not an input of this webblock? this way is not possible to have an empty field if we want.

Regards,

Marcelo


Hey Marcelo!

It is possible to have an empty input if you want, it's just an advanced format :)

So if you go inside the AdvancedFormat you see there's something called AdvancedFormatJSON where you can add:

"{
        beginEmpty: true

}"

This will make the input be empty when the page initializes.


The reason why this is not the default behavior is while we were researching the datepicker component the feedback that we got was that the default date should be the current date or the date that is picked in the input parameter InitialDate, and not an empty one. 

Hope this clears it up,

Cheers.


Hi Rita,

Thanks for the fast answer. I already tried that and it doesn't work for me. Attached a simple test and I'm using the latest version 1.5.3. this is the page after opening it.

Sry now I saw I added this comment to the preview component instead of the component itself.

Regards,

Marcelo

Hey Marcelo,

You're absolutely right, this is a typo in our description. Once I changed it from 'b' to 'B' it started working:

"{
        BeginEmpty: true

}"

Sorry about this and we'll fix it :)

Hi Rita,

Thanks for the info, it took me a quite a couple of days to figure out why my calendar was not starting empty.

I think you guys should update the documentation to help others.


Below is the documentation i was using 

https://success.outsystems.com/Documentation/11/Developing_an_Application/Design_UI/Patterns/Using_Web_Patterns/Controls/DatePicker