From 1893e91988208efadb4b72bc5e38dd7546a6677a Mon Sep 17 00:00:00 2001 From: Sergio Teruel Date: Wed, 4 Mar 2020 01:18:38 +0100 Subject: [PATCH] [FIX] web_widget_numeric_step: Fix _onChange input fields methods disabled by the widget --- web_widget_numeric_step/static/src/js/numeric_step.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/web_widget_numeric_step/static/src/js/numeric_step.js b/web_widget_numeric_step/static/src/js/numeric_step.js index d2621d5ef..b49b3a3ab 100644 --- a/web_widget_numeric_step/static/src/js/numeric_step.js +++ b/web_widget_numeric_step/static/src/js/numeric_step.js @@ -135,6 +135,9 @@ odoo.define('web_widget_numeric_step.field', function (require) { this.$input.val(this._sanitizeNumberValue(cval)); this.isDirty = true; this._doDebouncedAction(); + // Every time that user update the value we must trigger an + // onchange method. + this.$input.trigger("change"); }, // Handle Events @@ -202,6 +205,8 @@ odoo.define('web_widget_numeric_step.field', function (require) { */ _onChange: function (ev) { ev.target.value = this._sanitizeNumberValue(ev.target.value); + // Call _onChange of input widget + this._super.apply(this, arguments); }, // Helper Functions