Roo/bootstrap/MonthField.js
authorEdward <edward@roojs.com>
Mon, 31 Aug 2015 06:04:39 +0000 (14:04 +0800)
committerEdward <edward@roojs.com>
Mon, 31 Aug 2015 06:04:39 +0000 (14:04 +0800)
Roo/bootstrap/MonthField.js

index fa0dd68..6dd55bc 100644 (file)
@@ -264,7 +264,7 @@ Roo.extend(Roo.bootstrap.MonthField, Roo.bootstrap.Input,  {
                 dir = e.keyCode == 37 ? -1 : 1;
                 
                 if(typeof(this.vIndex) == 'undefined'){
-                    return;
+                    this.vIndex = 0;
                 }
                 
                 this.vIndex = this.vIndex + dir;
@@ -285,6 +285,10 @@ Roo.extend(Roo.bootstrap.MonthField, Roo.bootstrap.Input,  {
                 
                 dir = e.keyCode == 38 ? -1 : 1;
                 
+                if(typeof(this.vIndex) == 'undefined'){
+                    this.vIndex = 0;
+                }
+                
                 this.vIndex = this.vIndex + dir * 4;
                 
                 if(this.vIndex < 0){