Search and Top Navigation
#9923 open bug ()
Opened March 21, 2014 02:40PM UTC
Last modified November 23, 2015 08:11PM UTC
Datepicker: changeMonth combined with showCurrentAtPos
Reported by: | Mamen | Owned by: | |
---|---|---|---|
Priority: | minor | Milestone: | none |
Component: | ui.datepicker | Version: | 1.10.4 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
The options changeMonth and changeYear is visible on the first visible month. However they change the month selected in showCurrentAtPos. This seems very strange. I believe the position of the selects should be in the month selected in showCurrentAtPos.
Attachments (0)
Change History (4)
Changed March 21, 2014 04:19PM UTC by comment:1
status: | new → open |
---|
Changed July 14, 2014 07:03PM UTC by comment:2
I think a better change is making the selects behave as expected in their current position. Especially if we're considering #7580,
Are there examples of software or sites that display multiple months to compare this to?
Changed July 14, 2014 07:33PM UTC by comment:3
Just to note, the rewrite removes the select elements, but provides extension APIs for adding your own.
Changed November 23, 2015 08:11PM UTC by comment:4
I found a solution for the showCurrentAtPos bug issue:
--- jquery-ui.orig.js 2015-11-23 20:04:52.000000000 +0100 +++ jquery-ui.js 2015-11-23 17:56:37.987111191 +0100 @@ -8815,6 +8815,8 @@ origyearshtml = inst.yearshtml = null; }, 0); } + // FIX BUG http://bugs.jqueryui.com/ticket/7288 + inst.drawMonth += this._get(inst, "showCurrentAtPos"); }, // #6694 - don't focus the input if it's already focused @@ -8940,9 +8942,14 @@ if (this._isDisabledDatepicker(target[0])) { return; } + // FIX BUG http://bugs.jqueryui.com/ticket/7288 + /* this._adjustInstDate(inst, offset + (period === "M" ? this._get(inst, "showCurrentAtPos") : 0), // undo positioning period); + */ + this._adjustInstDate(inst, offset, period); + this._updateDatepicker(inst); },
I agree that this makes sense. We can take this approach on the rewrite.