[IMP] Only displat 'Outline Form Layout' button in debug mode

bzr revid: fme@openerp.com-20120326171351-an7fzv7pi13419dt
This commit is contained in:
Fabien Meghazi 2012-03-26 19:13:51 +02:00
parent 5f091f67e3
commit 70d32a7942
1 changed files with 3 additions and 1 deletions

View File

@ -772,7 +772,9 @@ openerp.web.FormRenderingEngine = openerp.web.Class.extend({
w.replace($elem);
}
});
$('<button>Debug layout</button>').appendTo(this.$element).click($.proxy(this.toggle_layout_debugging, this));
if (openerp.connection.debug) {
$('<button>Outline Form Layout</button>').appendTo(this.$element).click($.proxy(this.toggle_layout_debugging, this));
}
},
render_element: function(template, dict) {
dict = dict || {};