[datetime] locale/arabic fixes

This commit is contained in:
Rushabh Mehta 2015-06-02 11:07:37 +05:30
parent f2ba70bb2c
commit 3a2ffd4976

View file

@ -39,7 +39,7 @@ $.extend(frappe.datetime, {
},
obj_to_str: function(d) {
return moment(d).format();
return moment(d).locale("en").format();
},
obj_to_user: function(d) {
@ -106,7 +106,8 @@ $.extend(frappe.datetime, {
}
// user_fmt.replace("YYYY", "YY")? user might only input 2 digits of the year, which should also be parsed
return moment(val, [user_fmt.replace("YYYY", "YY"), user_fmt]).format(system_fmt);
return moment(val, [user_fmt.replace("YYYY", "YY"),
user_fmt]).locale("en").format(system_fmt);
},
user_to_obj: function(d) {