From 16fb8f0a7500218b7d53e89dcaaec3c5fb7d7eb5 Mon Sep 17 00:00:00 2001 From: Goffin Simon Date: Thu, 21 Jun 2018 13:21:37 +0200 Subject: [PATCH] [FIX] web_calendar: Calendar date format incorrect Steps to reproduce the bug: - Set a language on your user - Change the date format in this language and set '%d/%m/%y' (two digit year) - Open the calendar and select day or week view Bug: - The date displayed on the column headings has 'y' where it should have the year. To check the right date format: http://fullcalendar.io/docs1/utilities/formatDate/ opw:185924 --- addons/web_calendar/static/src/js/web_calendar.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/web_calendar/static/src/js/web_calendar.js b/addons/web_calendar/static/src/js/web_calendar.js index 529727cbd2f..aca9204b3fe 100644 --- a/addons/web_calendar/static/src/js/web_calendar.js +++ b/addons/web_calendar/static/src/js/web_calendar.js @@ -33,7 +33,7 @@ function get_fc_defaultOptions() { // adapt format for fullcalendar v1. // see http://fullcalendar.io/docs1/utilities/formatDate/ - var conversions = [['YYYY', 'yyyy'], ['YY', 'y'], ['DDDD', 'dddd'], ['DD', 'dd']]; + var conversions = [['YYYY', 'yyyy'], ['YY', 'yy'], ['DDDD', 'dddd'], ['DD', 'dd']]; _.each(conversions, function(conv) { dateFormat = dateFormat.replace(conv[0], conv[1]); });