Ticket #6659 (closed bug: fixed)

Opened 4 years ago

Last modified 22 months ago

Datepicker: Date format ymmdd not parsed correctly

Reported by: pheiberg Owned by:
Priority: minor Milestone: 1.8.7
Component: ui.datepicker Version: 1.8.6
Keywords: Cc:
Blocking: Blocked by:

Description

When using a date format containing y (two digit year), the date is not parsed correctly. This also results in that setting the dateFormat option on datepicker to such a date format causes the calender to not select the selected date in the calendar.

Failing test to reproduce error:

equalsDate($.datepicker.parseDate('ymmdd', '010203'), 	
 new Date(2001, 2 - 1, 3), 'Parse date ymmdd - default cutoff');

The error was reproduced in both Chrome and IE8 in jQuery UI versions 1.8.6 and the most recent clone of master.

Change History

comment:1 Changed 4 years ago by pheiberg

Proposed fix  commited and pull request made.

comment:2 Changed 4 years ago by scott.gonzalez

  • Status changed from new to open
  • Summary changed from Date format ymmdd not parsed correctly to Datepicker: Date format ymmdd not parsed correctly
  • Milestone changed from TBD to 1.9

comment:3 Changed 4 years ago by pheiberg

  • Status changed from open to closed
  • Resolution set to fixed

Datepicker: Fixed parsing of single y character for date formats. Fixes #6659 - Datepicker: Date format ymmdd not parsed correctly.

Changeset: a2e0eb920aaa41e6248e1a2f7d013997ba4f421f

comment:4 Changed 4 years ago by scott.gonzalez

#5285 is a duplicate of this ticket.

comment:5 Changed 4 years ago by scott.gonzalez

#6731 is a duplicate of this ticket.

comment:6 Changed 4 years ago by scott.gonzalez

  • Milestone changed from 1.9 to 1.8.7

comment:7 Changed 22 months ago by mikesherov

#5632 is a duplicate of this ticket.

Note: See TracTickets for help on using tickets.