Hi,
I am using the date picker from OutSystems UI (version 2.18.4), and I have disabled the weekends with a client action in the "initialized" event using the "DatePickerDisableWeekDays" action. I have also set today's date as the initial date. However, I am encountering an issue: when I select a date, I can only choose dates within the same week. If I try to select a date from another week, it doesn't allow me to do so. If I remove the "DatePickerDisableWeekDays" action, I am able to select any dates I want. I have included a brief video to demonstrate this odd behavior.
Has anyone else experienced this?
Hi @Andrea Caselli
Sorry about the misunderstanding. I got confused by the title.That is a known issue we have on our backlog to tackle as soon as possible, under the code ROU-4902 (for future reference in the release notes).Unfortunately, we can't provide a workaround or ETA.
Cheers,GM
This seems the exact scenario already asked and answered in this post.
Hi @Gonçalo Martins
Thank you for pointing me to that discussion.
While it seems similar, the issue I described in my other post (the one you linked) involved the date range picker component, where a range could not be selected if there were disabled dates in between.
In this current scenario, my challenge is with the standard date picker. Specifically, I am unable to select a single date (not a range) from a different week. I believe that I should be able to select any date, with the obvious exception of the weekdays that I have disabled, don't you think?
No worries Gonçalo, I will mark your reply as the solution and in the meantime I just won't use the "disableWeekdays" until the issue is fixed.
Hi everyone,
I've found a way to consistently reproduce this potential bug in OutSystems UI's date picker, and I wanted to ask the community for help in confirming it. I've attached an OML file with a simple reactive app designed specifically to test this behavior.
The bug occurs only the second time you select a date in the date picker. Here's how to reproduce it:
I've tested this on two Macs, using both Google Chrome and Firefox, and the same odd behavior occurs in both cases. I'll be testing on a Windows machine tomorrow, but in the meantime, it would be great if someone could help verify this bug.
Please let me know if you can reproduce the issue using the attached OML.
Thank you!
I encountered the same problem.
You might have some success instead of using the restrictions apply the CSS
.rangeMode .flatpickr-day:nth-of-type(1),.rangeMode .flatpickr-day:nth-of-type(7),.rangeMode .flatpickr-day:nth-of-type(8),.rangeMode .flatpickr-day:nth-of-type(14),.rangeMode .flatpickr-day:nth-of-type(15),.rangeMode .flatpickr-day:nth-of-type(21),.rangeMode .flatpickr-day:nth-of-type(22),.rangeMode .flatpickr-day:nth-of-type(28),.rangeMode .flatpickr-day:nth-of-type(29),.rangeMode .flatpickr-day:nth-of-type(35),.rangeMode .flatpickr-day:nth-of-type(36),.rangeMode .flatpickr-day:nth-of-type(42) { margin-top: 1px; background: darkred !important; cursor: not-allowed !important; border-radius: 0px !important; color:white !important; user-select:none !important; pointer-events: none !important;}
Then it's possible to do this
With restrictions I mean the DisabledDays