File tree Expand file tree Collapse file tree 1 file changed +9
-12
lines changed
Expand file tree Collapse file tree 1 file changed +9
-12
lines changed Original file line number Diff line number Diff line change 1- /*
2- * jQuery Timepicker Addon
3- * By: Trent Richardson [http://trentrichardson.com]
4- *
5- * Copyright 2013 Trent Richardson
6- * You may use this project under MIT license.
7- * http://trentrichardson.com/Impromptu/MIT-LICENSE.txt
8- */
9-
1+ /*! jQuery Timepicker Addon - v1.6.1 - 2015-11-14
2+ * http://trentrichardson.com/examples/timepicker
3+ * Copyright (c) 2015 Trent Richardson; Licensed MIT */
104( function ( factory ) {
115 if ( typeof define === 'function' && define . amd ) {
126 define ( [ 'jquery' , 'jquery-ui' ] , factory ) ;
2822 */
2923 $ . extend ( $ . ui , {
3024 timepicker : {
31- version : "@@version "
25+ version : "1.6.1 "
3226 }
3327 } ) ;
3428
291285 }
292286
293287 if ( tp_inst . _defaults . minDate === 0 || tp_inst . _defaults . minDateTime === 0 ) {
294- tp_inst . _defaults . minDate = new Date ( ) ;
288+ var coeff = 1000 * 60 * 5 ;
289+ var date = new Date ( ) ; //or use any other date
290+ var rounded = new Date ( Math . round ( date . getTime ( ) / coeff ) * coeff )
291+ tp_inst . _defaults . minDate = rounded ;
295292 }
296293 if ( tp_inst . _defaults . maxDate === 0 || tp_inst . _defaults . maxDateTime === 0 ) {
297294 tp_inst . _defaults . maxDate = new Date ( ) ;
22642261 /*
22652262 * Keep up with the version
22662263 */
2267- $ . timepicker . version = "@@version " ;
2264+ $ . timepicker . version = "1.6.1 " ;
22682265
22692266} ) ) ;
You can’t perform that action at this time.
0 commit comments