[FIX] web: display 0 for FieldFloatToggle
The field was hidden in UI when its value was not set or equal to 0. Display the field if its value is set to 0. [IMP] web: clean code
This commit is contained in:
@@ -1287,7 +1287,14 @@ var FieldFloatToggle = AbstractField.extend({
|
||||
this._setValue(next_val); // will be parsed in _setValue
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* For float toggle fields, 0 is a valid value.
|
||||
*
|
||||
* @override
|
||||
*/
|
||||
isSet: function () {
|
||||
return this.value === 0 || this._super(...arguments);
|
||||
},
|
||||
});
|
||||
|
||||
var FieldPercentage = FieldFloat.extend({
|
||||
|
||||
Reference in New Issue
Block a user