Fix so altField(if set) show both Date and Time

master
Vorapoap L. 2010-12-16 09:07:52 -08:00
parent 27815082b5
commit 2ec0a4e021
1 changed files with 7 additions and 1 deletions

View File

@ -518,7 +518,13 @@ $.extend(Timepicker.prototype, {
if (this._defaults.timeOnly === true) formattedDateTime = this.formattedTime;
else if (this._defaults.timeOnly !== true && (this._defaults.alwaysSetTime || timeAvailable)) {
if (this.$altInput) this.$altInput.val(this.formattedTime);
if (this.$altInput) {
if (this._defaults.timeOnly !== true) {
this.$altInput.val(this.$altInput.val() + ' ' + this.formattedTime);
} else {
this.$altInput.val(this.formattedDateTime);
}
}
else formattedDateTime += ' ' + this.formattedTime;
}