mirror of https://github.com/OCA/web.git
[FIX] web_pivot_computed_measure: Error when computed measure takes Infinity value
parent
87346ebe1c
commit
d41d38702b
|
@ -0,0 +1,15 @@
|
|||
/** @odoo-module **/
|
||||
/* Copyright 2022 Tecnativa - Carlos Roca
|
||||
* License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) */
|
||||
|
||||
import {PivotRenderer} from "@web/views/pivot/pivot_renderer";
|
||||
import {patch} from "web.utils";
|
||||
|
||||
patch(PivotRenderer.prototype, "web_pivot_computed_measure.PivotRenderer", {
|
||||
getFormattedValue(cell) {
|
||||
if (cell.value === Infinity) {
|
||||
return "-";
|
||||
}
|
||||
return this._super(...arguments);
|
||||
},
|
||||
});
|
Loading…
Reference in New Issue