[FIX] web_widget_x2many_2d_matrix: Use widget for formatting aggregates

pull/1259/head
tarteo 2019-04-23 11:54:33 +02:00
parent 50c069e393
commit 270f4c6fb6
2 changed files with 3 additions and 2 deletions

View File

@ -4,7 +4,7 @@
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
{
"name": "2D matrix for x2many fields",
"version": "11.0.1.1.1",
"version": "11.0.1.1.2",
"author": "Therp BV, "
"Tecnativa, "
"Camptocamp, "

View File

@ -480,7 +480,8 @@ odoo.define('web_widget_x2many_2d_matrix.X2Many2dMatrixRenderer', function (requ
*/
_apply_aggregate_value: function ($cell, aggregate) {
var field = this.state.fields[aggregate.fname],
formatter = field_utils.format[field.type];
fieldInfo = this.state.fieldsInfo.list[aggregate.fname],
formatter = field_utils.format[fieldInfo.widget ? fieldInfo.widget : field.type];
var formattedValue = formatter(
aggregate.value, field, {escape: true}
);