fix default hour,minute,second by changing init order
This commit is contained in:
parent
9efeb990d2
commit
b2a1d9440a
13
jquery-ui-timepicker-addon.js
vendored
13
jquery-ui-timepicker-addon.js
vendored
|
@ -108,13 +108,6 @@ $.extend(Timepicker.prototype, {
|
||||||
var tp_inst = new Timepicker(),
|
var tp_inst = new Timepicker(),
|
||||||
inlineSettings = {};
|
inlineSettings = {};
|
||||||
|
|
||||||
tp_inst.hour = tp_inst._defaults.hour;
|
|
||||||
tp_inst.minute = tp_inst._defaults.minute;
|
|
||||||
tp_inst.second = tp_inst._defaults.second;
|
|
||||||
tp_inst.ampm = '';
|
|
||||||
tp_inst.$input = $input;
|
|
||||||
|
|
||||||
|
|
||||||
for (var attrName in this._defaults) {
|
for (var attrName in this._defaults) {
|
||||||
var attrValue = $input.attr('time:' + attrName);
|
var attrValue = $input.attr('time:' + attrName);
|
||||||
if (attrValue) {
|
if (attrValue) {
|
||||||
|
@ -145,6 +138,12 @@ $.extend(Timepicker.prototype, {
|
||||||
timepicker: tp_inst // add timepicker as a property of datepicker: $.datepicker._get(dp_inst, 'timepicker');
|
timepicker: tp_inst // add timepicker as a property of datepicker: $.datepicker._get(dp_inst, 'timepicker');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
tp_inst.hour = tp_inst._defaults.hour;
|
||||||
|
tp_inst.minute = tp_inst._defaults.minute;
|
||||||
|
tp_inst.second = tp_inst._defaults.second;
|
||||||
|
tp_inst.ampm = '';
|
||||||
|
tp_inst.$input = $input;
|
||||||
|
|
||||||
if (o.altField)
|
if (o.altField)
|
||||||
tp_inst.$altInput = $(o.altField)
|
tp_inst.$altInput = $(o.altField)
|
||||||
.css({ cursor: 'pointer' })
|
.css({ cursor: 'pointer' })
|
||||||
|
|
Loading…
Reference in a new issue