aboutsummaryrefslogtreecommitdiffstats
path: root/ui/widgets/datepicker.js
diff options
context:
space:
mode:
Diffstat (limited to 'ui/widgets/datepicker.js')
-rw-r--r--ui/widgets/datepicker.js6
1 files changed, 5 insertions, 1 deletions
diff --git a/ui/widgets/datepicker.js b/ui/widgets/datepicker.js
index e2e9037e8..6e1f5be73 100644
--- a/ui/widgets/datepicker.js
+++ b/ui/widgets/datepicker.js
@@ -81,7 +81,11 @@ var widget = $.widget( "ui.datepicker", {
_getCreateOptions: function() {
var max = this.element.attr( "max" ),
min = this.element.attr( "min" ),
- parser = new Globalize( "en" ).dateParser( { raw: "yyyy-MM-dd" } ),
+ parser = function( value ) {
+ var exploded = value.split( "-" );
+
+ return new Date( exploded[ 0 ], exploded[ 1 ] - 1, exploded[ 2 ] );
+ },
options = {};
if ( max !== undefined ) {