summaryrefslogtreecommitdiff
path: root/addons/website_event/controllers/main.py
diff options
context:
space:
mode:
authorChristophe Simonis <chs@odoo.com>2016-08-03 16:16:30 +0200
committerChristophe Simonis <chs@odoo.com>2016-08-03 16:16:30 +0200
commit53015e11a939cf147d35b15cbef7e463eca741d3 (patch)
tree5c6a96b91df63f4869e7dc7c37cf36ac3a53fa1e /addons/website_event/controllers/main.py
parente7e7b9beb0e46734e5df3d6a98527782ef837ddd (diff)
parenteb83ab236fa7d867b9e68b137d48be916b712e01 (diff)
[MERGE] forward port branch saas-11 up to eb83ab2
Diffstat (limited to 'addons/website_event/controllers/main.py')
-rw-r--r--addons/website_event/controllers/main.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/addons/website_event/controllers/main.py b/addons/website_event/controllers/main.py
index b4d428e4b18..5c6e0114650 100644
--- a/addons/website_event/controllers/main.py
+++ b/addons/website_event/controllers/main.py
@@ -194,8 +194,8 @@ class WebsiteEventController(http.Controller):
def get_formated_date(self, event):
start_date = fields.Datetime.from_string(event.date_begin).date()
end_date = fields.Datetime.from_string(event.date_end).date()
- month = babel.dates.get_month_names('abbreviated', locale=self.env.context.get('lang', 'en_US'))[start_date.month]
- return ('%s %s%s') % (month, start_date.strftime("%e"), (end_date != start_date and ("-"+end_date.strftime("%e")) or ""))
+ month = babel.dates.get_month_names('abbreviated', locale=event.env.context.get('lang', 'en_US'))[start_date.month]
+ return ('%s %s%s') % (month, start_date.strftime("%e"), (end_date != start_date and ("-" + end_date.strftime("%e")) or ""))
@http.route('/event/get_country_event_list', type='http', auth='public', website=True)
def get_country_events(self, **post):