Home > front end >  How to change tktimepicker default clock type from 12-hours to 24-hours?
How to change tktimepicker default clock type from 12-hours to 24-hours?

Time:11-26

The tktimepicker default clock type is 12 hours. How do I change tktimepicker clock type from 12-hours to 24-hours?

CodePudding user response:

Per the documentation, there are two ways:

  1. Pass an argument type=constants.HOURS24 to the constructor of your class.
  2. use the configure_24HrsTime method on SpinTimePickerModern and SpinTimePickerOld objects.

The code is available here if you need to refer to it.

  • Related