Merge lp:~openerp-dev/openerp-web/7.0-opw-585320-msh into lp:openerp-web/7.0

Proposed by Mohammed Shekha(Open ERP) on 2013-02-07
Status: Merged
Approved by: Naresh(OpenERP) on 2013-04-11
Approved revision: 3746
Merged at revision: 3857
Proposed branch: lp:~openerp-dev/openerp-web/7.0-opw-585320-msh
Merge into: lp:openerp-web/7.0
Diff against target: 47 lines (+37/-0)
1 file modified
addons/web/static/src/js/view_form.js (+37/-0)
To merge this branch: bzr merge lp:~openerp-dev/openerp-web/7.0-opw-585320-msh
Reviewer Review Type Date Requested Status
Naresh(OpenERP) (community) 2013-02-07 Approve on 2013-04-11
Review via email: mp+147026@code.launchpad.net

Description of the change

Hello,

Fixed the issue of translation for jquery datetime picker.

Demo :- Open jQuery Datetime picker in any other language you will see terms Months, Done, Today etc not going to translated.

This branch will set regional information jQuery datetime picker.

Thanks.

To post a comment you must log in.
review: Approve
Olivier Dony (Odoo) (odo-openerp) wrote :

The same patch was already merged at revision 3857 for fixing bug 1101072. Thanks!

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'addons/web/static/src/js/view_form.js'
2--- addons/web/static/src/js/view_form.js 2013-02-05 17:05:56 +0000
3+++ addons/web/static/src/js/view_form.js 2013-02-07 06:58:21 +0000
4@@ -2384,6 +2384,43 @@
5 this.$input = this.$el.find('input.oe_datepicker_master');
6 this.$input_picker = this.$el.find('input.oe_datepicker_container');
7
8+ $.datepicker.setDefaults({
9+ clearText: _t("Clear"),
10+ clearStatus: _t("Erase the current date"),
11+ closeText: _t("Done"),
12+ closeStatus: _t("Close without change"),
13+ prevText: _t("<Prev"),
14+ prevStatus: _t("Show the previous month"),
15+ nextText: _t("Next>"),
16+ nextStatus: _t("Show the next month"),
17+ currentText: _t("Today"),
18+ currentStatus: _t("Show the current month"),
19+ monthNames: Date.CultureInfo.monthNames,
20+ monthNamesShort: Date.CultureInfo.abbreviatedMonthNames,
21+ monthStatus: _t("Show a different month"),
22+ yearStatus: _t("Show a different year"),
23+ weekHeader: _t("Wk"),
24+ weekStatus: _t("Week of the year"),
25+ dayNames: Date.CultureInfo.dayNames,
26+ dayNamesShort: Date.CultureInfo.abbreviatedDayNames,
27+ dayNamesMin: Date.CultureInfo.shortestDayNames,
28+ dayStatus: _t("Set DD as first week day"),
29+ dateStatus: _t("Select D, M d"),
30+ firstDay: Date.CultureInfo.firstDayOfWeek,
31+ initStatus: _t("Select a date"),
32+ isRTL: false
33+ });
34+
35+ $.timepicker.setDefaults({
36+ timeOnlyTitle: _t("Choose Time"),
37+ timeText: _t("Time"),
38+ hourText: _t("Hour"),
39+ minuteText: _t("Minute"),
40+ secondText: _t("Second"),
41+ currentText: _t("Now"),
42+ closeText: _t("Done")
43+ });
44+
45 this.picker({
46 onClose: this.on_picker_select,
47 onSelect: this.on_picker_select,