From c9a72b79e4ca3594f20689ccb3099c6c7143d3c9 Mon Sep 17 00:00:00 2001 From: Denis Ledoux Date: Wed, 4 Mar 2015 17:51:24 +0100 Subject: [PATCH] [FIX] web: size of text fields textarea when invisible by default Text fields, or char fields having widget="text", were not sized correctly when the field was not visible by default, ans was set visible thanks to attrs and other fields values. opw-629394 --- addons/web/static/src/js/view_form.js | 1 + 1 file changed, 1 insertion(+) diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index b7e6d9225c8..1eef15a051b 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -2647,6 +2647,7 @@ instance.web.form.FieldText = instance.web.form.AbstractField.extend(instance.we this.$textarea = this.$el.find('textarea'); this.auto_sized = false; this.default_height = this.$textarea.css('height'); + if (this.default_height === '0px') this.default_height = '90px'; if (this.get("effective_readonly")) { this.$textarea.attr('disabled', 'disabled'); }