summaryrefslogtreecommitdiff
path: root/addons/web/static/src/js/widgets
diff options
context:
space:
mode:
authorChristophe Simonis <chs@odoo.com>2015-04-17 17:08:17 +0200
committerChristophe Simonis <chs@odoo.com>2015-04-17 17:08:17 +0200
commit107b589a11dfa6a81d97d081d8b2bcb60f05b4e9 (patch)
tree7ece7add3b1ecf71be6e110827554751c4fc93a8 /addons/web/static/src/js/widgets
parenta9471c43b952a1b3ecd92dcbcc0719723336acf1 (diff)
[FIX] *: correct previous forward port
Due to files renaming, some patched should be applied manually to the correct files. Forgot to `git add` these files when committing the forward port...
Diffstat (limited to 'addons/web/static/src/js/widgets')
-rw-r--r--addons/web/static/src/js/widgets/debug_manager.js20
1 files changed, 11 insertions, 9 deletions
diff --git a/addons/web/static/src/js/widgets/debug_manager.js b/addons/web/static/src/js/widgets/debug_manager.js
index 0bd7a772425..01db3ff71ef 100644
--- a/addons/web/static/src/js/widgets/debug_manager.js
+++ b/addons/web/static/src/js/widgets/debug_manager.js
@@ -53,16 +53,18 @@ if (core.debug) {
return;
}
- // Render the dropdown and append it
- var dropdown_content = QWeb.render('WebClient.DebugDropdown', {
- widget: self,
- active_view: self.active_view,
- view: self.view,
- action: self.view_manager.action,
- searchview: self.view_manager.searchview,
- uid: session.uid,
+ this.session.user_has_group('base.group_system').then(function(is_admin) {
+ // Render the dropdown and append it
+ var dropdown_content = QWeb.render('WebClient.DebugDropdown', {
+ widget: self,
+ active_view: self.active_view,
+ view: self.view,
+ action: self.view_manager.action,
+ searchview: self.view_manager.searchview,
+ is_admin: is_admin,
+ });
+ $(dropdown_content).appendTo(self.$dropdown);
});
- $(dropdown_content).appendTo(self.$dropdown);
},
/**
* Calls the appropriate callback when clicking on a Debug option