From c8d77f93e5a857acd22025f4a8d4d42d674479d1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=A9ry=20Debongnie?= Date: Mon, 8 May 2017 10:55:46 +0200 Subject: [FIX] web: display empty input fields properly Before this commit, it was not possible to see the difference between an unset float field (with a 'false' value) and a set field (for ex, with value 0) This was due to the fact that the formatFloat/formatMonetary functions format false values as the number 0, unlike many other formatting functions. --- addons/web/static/src/js/fields/basic_fields.js | 3 --- 1 file changed, 3 deletions(-) (limited to 'addons/web/static/src/js/fields/basic_fields.js') diff --git a/addons/web/static/src/js/fields/basic_fields.js b/addons/web/static/src/js/fields/basic_fields.js index 9df9a49fac2..3e9ea89be31 100644 --- a/addons/web/static/src/js/fields/basic_fields.js +++ b/addons/web/static/src/js/fields/basic_fields.js @@ -93,9 +93,6 @@ var DebouncedField = AbstractField.extend({ // _debouncedStarted is used to detect that the user interacted at least // once with the widget, so that we can prevent it from triggering a // field_changed in commitChanges if the user didn't change anything - // (this is required as sometimes it is hard to detect that an unset - // value is still unset, e.g. if a numerical field contains the value 0, - // is it because it is still unset or because the user set it to 0? this._debouncedStarted = false; if (this.mode === 'edit') { if (this.DEBOUNCE) { -- cgit v1.2.3