From: Nik Okuntseff Date: Wed, 6 Apr 2016 17:04:08 +0000 (+0000) Subject: Fix report exports to honor user decimal mark designation. X-Git-Tag: timetracker_1.19-1~1719 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=e20813a282b957d4b9112b825f87502c3525a780;p=timetracker.git Fix report exports to honor user decimal mark designation. --- diff --git a/WEB-INF/config.php.dist b/WEB-INF/config.php.dist index bca0da0e..b52e0d80 100644 --- a/WEB-INF/config.php.dist +++ b/WEB-INF/config.php.dist @@ -174,7 +174,7 @@ define('LANG_DEFAULT', ''); define('CURRENCY_DEFAULT', '$'); -// EXPORT_DECIMAL_DURATION - defines whether time duration values are decimal in CSV and XML data exports (1.25 vs 1:15). +// EXPORT_DECIMAL_DURATION - defines whether time duration values are decimal in CSV and XML data exports (1.25 or 1,25 vs 1:15). // define('EXPORT_DECIMAL_DURATION', true); diff --git a/WEB-INF/lib/common.lib.php b/WEB-INF/lib/common.lib.php index 124b78f5..d98e8889 100644 --- a/WEB-INF/lib/common.lib.php +++ b/WEB-INF/lib/common.lib.php @@ -144,13 +144,14 @@ } function time_to_decimal($a) { + global $user; $tmp = explode(":", $a); if($tmp[1]{0}=="0") $tmp[1] = $tmp[1]{1}; $m = round($tmp[1]*100/60); if($m<10) $m = "0".$m; - $time = $tmp[0].".".$m; + $time = $tmp[0].$user->decimal_mark.$m; return $time; } diff --git a/WEB-INF/templates/footer.tpl b/WEB-INF/templates/footer.tpl index 40a17ec2..f15d95d6 100644 --- a/WEB-INF/templates/footer.tpl +++ b/WEB-INF/templates/footer.tpl @@ -12,7 +12,7 @@
-
 Anuko Time Tracker 1.9.24.3495 | Copyright © Anuko | +  Anuko Time Tracker 1.9.25.3496 | Copyright © Anuko | {$i18n.footer.credits} | {$i18n.footer.license} | {$i18n.footer.improve}