[FIX] Button widget does not honnor readonly property

bzr revid: fme@openerp.com-20111017153326-77z2xmtqcnfpadom
This commit is contained in:
Fabien Meghazi 2011-10-17 17:33:26 +02:00
parent a789d421cb
commit 1eee4a0833
1 changed files with 1 additions and 1 deletions

View File

@ -1014,7 +1014,7 @@ openerp.web.form.WidgetButton = openerp.web.form.Widget.extend({
this.check_disable();
},
check_disable: function() {
if (this.force_disabled || !this.view.is_interactible_record()) {
if (this.readonly || this.force_disabled || !this.view.is_interactible_record()) {
this.$element.find("button").attr("disabled", "disabled");
this.$element.find("button").css("color", "grey");
} else {