From 4b2cd22a2e70fe43a0692efcbda07b67390a8a7f Mon Sep 17 00:00:00 2001 From: boudet jean pascal <68547382+atm-jpb@users.noreply.github.com> Date: Fri, 31 May 2024 15:29:59 +0200 Subject: [PATCH] FIX : Extrafield intshowzero in list (#29789) * add test * x --------- Co-authored-by: jpb --- htdocs/core/tpl/extrafields_list_print_fields.tpl.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/htdocs/core/tpl/extrafields_list_print_fields.tpl.php b/htdocs/core/tpl/extrafields_list_print_fields.tpl.php index d9b01c57bab..38c40a48920 100644 --- a/htdocs/core/tpl/extrafields_list_print_fields.tpl.php +++ b/htdocs/core/tpl/extrafields_list_print_fields.tpl.php @@ -29,6 +29,8 @@ if (!empty($extrafieldsobjectkey) && !empty($extrafields->attributes[$extrafield $datenotinstring = $db->jdate($datenotinstring); } $value = $datenotinstring; + } elseif (in_array($extrafields->attributes[$extrafieldsobjectkey]['type'][$key], array('int'))) { + $value = (!empty($obj->$tmpkey) || $obj->$tmpkey === '0' ? $obj->$tmpkey : ''); } else { $value = (!empty($obj->$tmpkey) ? $obj->$tmpkey : ''); }