This is a migrated thread and some comments may be shown as answers.

Disable any specific day of the week (Fri/Sat/Sun) in DateTimePicker control

3 Answers 87 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Sanjay
Top achievements
Rank 1
Sanjay asked on 23 Apr 2020, 08:16 AM

Hi Team,

We are looking for some option in DateTimePicker control, which can disable any specific day of the week (eg Fri/Sat/Sun) in  DateTimePicker control.

 

Regards,

Sanjay

3 Answers, 1 is accepted

Sort by
0
Stefan
Telerik team
answered on 23 Apr 2020, 02:40 PM

Hello, Sanjay,

This is currently in our ToDo list.

I have made a public item for it in GitHub which can be followed for the status:

https://github.com/telerik/kendo-react/issues/559

Regards,
Stefan
Progress Telerik

Progress is here for your business, like always. Read more about the measures we are taking to ensure business continuity and help fight the COVID-19 pandemic.
Our thoughts here at Progress are with those affected by the outbreak.
0
Sanjay
Top achievements
Rank 1
answered on 24 Apr 2020, 09:50 AM

Hi Stefan,

As per the github item, the task is for customizing the datetimepicker. Do this change support all the default properties of datetime picker like min date and max date, etc.

Also, if there is one property in datetimepicker like RestrictedDays=[0, 6] (Sturday and Sunday) which will restrict the specific days without customizing the whole datetime picker.

Regards,

Sanjay

 

 

0
Stefan
Telerik team
answered on 24 Apr 2020, 01:44 PM

Hello, Sanjay,

We try to follow this content for customization based on the React idea for reusable components.

We provide customization options that accept components like in this case.

I will share an example to illustrate why we have this approach.

We provide a custom Calednar option that shows Saturday and Sunday as disabled in a reusable component and used it in multiple places. Then when we have new requirements that a specific day has to be made disabled. If we have property RestrictedDays, we have to go and make the change in all places where if we use custom reusable Calendar, we made the change only on that component, and all pickers that use it will have the new functionality.

The same example can be seen in the Calendar:

https://www.telerik.com/kendo-react-ui/components/dateinputs/calendar/custom-rendering/#toc-overriding-the-default-properties

Regards,
Stefan
Progress Telerik

Progress is here for your business, like always. Read more about the measures we are taking to ensure business continuity and help fight the COVID-19 pandemic.
Our thoughts here at Progress are with those affected by the outbreak.
Tags
General Discussions
Asked by
Sanjay
Top achievements
Rank 1
Answers by
Stefan
Telerik team
Sanjay
Top achievements
Rank 1
Share this question
or