Fix datepicker error,"hour is undefined" from et2_widget_date

This commit is contained in:
Hadi Nategh 2013-09-13 13:06:46 +00:00
parent b8341e48a1
commit 5517a29d47

View File

@ -104,7 +104,7 @@ var et2_date = et2_inputWidget.extend(
d.setHours(inst.hour);
d.setMinutes(inst.minute);
}
else if(inst && (typeof inst.hour === 'undefined'))
else if(inst && (typeof inst.hour === 'undefined') && (typeof inst.settings.timepicker !== 'undefined'))
{
d.setHours(inst.settings.timepicker.hour);
d.setMinutes(inst.settings.timepicker.minute);