Topic: Time picker disabled hours
                  
                  vitticeps
                  free
                  asked 6 years ago
                
Is it possible to have the same/similar option in time picker than we have in date picker in terms of disabling selected values? In date picker it is possible to disable dates - so users cannot select them. Would be nice to have the same future in time picker.
It is possible in bootstrap timepicker by providing an array like:
hoursDisabled: [0, 1, 2, 3, 4, 5, 6, 7, 8, 18, 19, 20, 21, 22, 23]
So I guess - it is not a huge changes to implement
Thank you guys in advance BR, Laszlo
                      
                      zubair husnain
                      free
                        answered 5 years ago
                    
Hi Sir/Madam can i disable specific few hours in timepicker
Arkadiusz Idzikowski staff commented 5 years ago
If you use version 9.2.0 or newer, you can set min and max time with min and max inputs. Please take a look at the API of the timepicker component: https://mdbootstrap.com/docs/angular/forms/time-picker/#docsTabsAPI
                      
                      vitticeps
                      free
                        answered 6 years ago
                    
OK. Next update.
I modified the way it works. I added a [CLEAR] button and made it response when the minute is selected.
http://vttcps.com/timePickerV2.mov
A bit of styling is still missing for the footer of the 'modal'.. and yeah.. the disabled hours.. :) ..we are on the way
                      
                      vitticeps
                      free
                        answered 6 years ago
                    
I went into your time picker component and modified few things. Now the input field acts like an input field.
See video at https://vttcps.com/timePickerLabel.mov
I can pass the code via email if you want - what I modified so you can put into development / production mode of your package..
vitticeps free commented 6 years ago
In the code you provide... There is no [CLEAR] button.. And no option to close the time picker when the minutes are selected..
                      
                      Arkadiusz Idzikowski
                      staff
                        answered 6 years ago
                    
Hello,
Thank you for your suggestion. We will add this feature to our nice-to-have list and consider implementing it in the future.
FREE CONSULTATION
Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.
Resolved
- ForumUser: Free
 - Premium support: No
 - Technology: MDB Angular
 - MDB Version: 7.5.4
 - Device: any
 - Browser: any
 - OS: any
 - Provided sample code: No
 - Provided link: No