chandrajavin / jquery-datepicker

Automatically exported from code.google.com/p/jquery-datepicker
0 stars 0 forks source link

can't select a previous date #374

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
If user select some date, for example, 10/07/2013 and then entered an invalid 
date(before startDate or after endDate, for example, 00/00/0000) into an input 
field and after that tried to select previous date(10/07/2013), then input 
field value will not change(00/00/0000), but in calendar will be selected 
10/07/2013.

Please provide a URL to a page displaying the problem.
http://www.kelvinluck.com/assets/jquery/datePicker/v2/demo/datePicker.html

What version of the datepicker are you using? On what operating system? And 
Which Browser?
the last one. Ubuntu 13.04. All browsers.

Please provide any additional information below.
I think that bug is here:
setSelected : function(d, v, moveToMonth, dispatchEvents)
{
    if (d < this.startDate || d.zeroTime() > this.endDate.zeroTime()) {
        // Don't allow people to select dates outside range...
        return;
}

if we will change "return;" to "this.clearSelected();", script will work 
without this bug.

P.S. Sorry for my bad English :))

Original issue reported on code.google.com by berliet...@gmail.com on 10 Jul 2013 at 7:54

GoogleCodeExporter commented 8 years ago
The date picker code is now on github:
https://github.com/vitch/jQuery-datepicker

If you can provide a pull request there I will be happy to merge it.

Thanks!

Original comment by kelvin.l...@gmail.com on 15 Jul 2013 at 4:37