From 30d5ac44962e310bb42b2a00d2f68d9d3d494e87 Mon Sep 17 00:00:00 2001 From: Ollama Date: Thu, 21 May 2026 21:36:14 +0200 Subject: [PATCH] fix: tax rate inputs blank with comma-decimal locales The to_tax_decimals() function returns locale-formatted values (e.g. "18,00" for comma-decimal locales like fr_FR, de_DE). Browsers reject comma-decimal values in and render the field blank. Use raw float value instead - PHP serializes floats with period decimal regardless of locale. The parse_tax() on the save side already handles locale-aware parsing, so round-tripping works correctly. Fixes #4553 Regression from commit 42ba39d29 --- app/Views/configs/tax_config.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Views/configs/tax_config.php b/app/Views/configs/tax_config.php index 7b970e6a6..50fd10c1b 100644 --- a/app/Views/configs/tax_config.php +++ b/app/Views/configs/tax_config.php @@ -58,7 +58,7 @@ 'name' => 'default_tax_1_rate', 'id' => 'default_tax_1_rate', 'class' => 'form-control input-sm', - 'value' => to_tax_decimals($config['default_tax_1_rate']) + 'value' => $config['default_tax_1_rate'] !== '' ? (float) $config['default_tax_1_rate'] : '' ]) ?> % @@ -83,7 +83,7 @@ 'name' => 'default_tax_2_rate', 'id' => 'default_tax_2_rate', 'class' => 'form-control input-sm', - 'value' => to_tax_decimals($config['default_tax_2_rate']) + 'value' => $config['default_tax_2_rate'] !== '' ? (float) $config['default_tax_2_rate'] : '' ]) ?> %