details: https://code.tryton.org/tryton/commit/29ba0e98838f
branch: 7.8
user: Cédric Krier <[email protected]>
date: Wed Feb 04 15:29:51 2026 +0100
description:
Test if width is set before testing if it ends width '%'
Closes #14578
(grafted from 889e1cf303cfddeace6c3de7f4e164bd20b1703b)
diffstat:
sao/src/view/tree.js | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diffs (12 lines):
diff -r 2d241c37d3c4 -r 29ba0e98838f sao/src/view/tree.js
--- a/sao/src/view/tree.js Fri Feb 06 15:32:39 2026 +0100
+++ b/sao/src/view/tree.js Wed Feb 04 15:29:51 2026 +0100
@@ -1070,7 +1070,7 @@
} else {
width = column.col.data('default-width');
}
- if (width.endsWith('%')) {
+ if (width && width.endsWith('%')) {
width = parseInt(width.slice(0, -1), 10) / 100;
if (column.attributes.expand) {
width /= parseInt(column.attributes.expand, 10);