]> lifelog.hopto.org Git - LifeLog.git/commitdiff
Money amount formatting.
authorwbudic <redacted>
Wed, 7 Nov 2018 05:56:56 +0000 (16:56 +1100)
committerwbudic <redacted>
Wed, 7 Nov 2018 05:56:56 +0000 (16:56 +1100)
htdocs/cgi-bin/main.cgi

index 043ae4485c1fc44655624bcfeea5ea098674bba3..f94decca5014d9f8d5961e0e086722c025442d87 100755 (executable)
@@ -117,7 +117,7 @@ if($tbl_start>0){
         my $ct = $hshCats{$row[1]};
         my $dt = DateTime::Format::SQLite->parse_datetime( $row[2] );
         my $log = $row[3]; 
-        my $amm = $row[4];
+        my $amm = sprintf "%.2f", $row[4];
 
         #Apostrophe in the log value is doubled to avoid SQL errors.
                    $log =~ s/''/'/g;