[FIX] view form: Use digits to round float values on client side
This commit is contained in:
committed by
Géry Debongnie
parent
124e476943
commit
37e85a1e35
@@ -2536,6 +2536,9 @@ instance.web.form.FieldFloat = instance.web.form.FieldChar.extend({
|
||||
// As in GTK client, floats default to 0
|
||||
value_ = 0;
|
||||
}
|
||||
if (this.digits !== undefined && this.digits.length === 2) {
|
||||
value_ = instance.web.round_precision(value_, this.digits[1]);
|
||||
}
|
||||
this._super.apply(this, [value_]);
|
||||
},
|
||||
focus: function () {
|
||||
|
||||
Reference in New Issue
Block a user