diff --git a/openerp/addons/base/ir/ir_ui_view.py b/openerp/addons/base/ir/ir_ui_view.py index 5876d211380..ea031710ced 100644 --- a/openerp/addons/base/ir/ir_ui_view.py +++ b/openerp/addons/base/ir/ir_ui_view.py @@ -680,6 +680,7 @@ class view(osv.osv): arch = self.read_combined(cr, uid, id_, fields=['arch'], context=context)['arch'] arch_tree = etree.fromstring(arch) + if 'lang' in context: arch_tree = self.translate_qweb(cr, uid, id_, arch_tree, context['lang'], context) self.distribute_branding(arch_tree) diff --git a/openerp/http.py b/openerp/http.py index 9c7fa276c0b..80c6095d498 100644 --- a/openerp/http.py +++ b/openerp/http.py @@ -219,7 +219,7 @@ def route(route, type="http", auth="user"): configuration indicating the current database nor the current user. """ assert type in ["http", "json"] - assert auth in auth_methods.keys() + assert auth in auth_methods def decorator(f): if isinstance(route, list): f.routes = route @@ -1025,7 +1025,7 @@ class Root(object): url = url[: -1] routing_map.add(routing.Rule(url, endpoint=mv)) - modules_set = set(controllers_per_module.keys()) - set(['', 'web']) + modules_set = set(controllers_per_module) - set(['', 'web']) # building all none methods gen(['', "web"] + sorted(modules_set), True) if not db: