Search and Top Navigation
#3080 closed bug (fixed)
Opened July 10, 2008 01:12AM UTC
Closed July 18, 2008 03:53PM UTC
Datepicker calls _setDateFromField on a div when inline
Reported by: | anonymous | Owned by: | grabanski |
---|---|---|---|
Priority: | major | Milestone: | |
Component: | ui.datepicker | Version: | 1.5.1 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
When you have an inline datepicker and set it's date from .datepicker('setDate') immediately after instantiating it, the datepicker('getDate') function will return null until a date is manually selected. I think I tracked this down to line 275-276 where the _getDatePicker function calls _setDateFromField. By adding an extra check to see if the datepicker is a div before trying to call _setDateFromField I fixed it for my needs, but it might be a bit hackish...
Revised it looks like this
ui.datepicker.js lines 275 and 276
if (inst && ($(target).get(0).tagName != 'DIV')) inst._setDateFromField($(target));
Attachments (0)
Change History (1)
Changed July 18, 2008 03:53PM UTC by comment:1
resolution: | → fixed |
---|---|
status: | new → closed |
Fixed - _setDateFromField is not called if the datepicker is inline.