Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 999fedbd

Von Udo Spallek vor mehr als 19 Jahren hinzugefügt

  • ID 999fedbd9ddf7f73d468776559edfcc34f7aafdf
  • Vorgänger 1084d82b
  • Nachfolger 7e5216e8

sub round_amount schnedet nun anhängende Nullen automatisch ab.

Unterschiede anzeigen:

SL/Form.pm
# Udo Spallek
$amount = $amount * (10 ** ($places));
$round_amount = int($amount + .5 * ($amount <=> 0))/(10**($places));
do {
$round_amount =~ s/(0|\.)$//g;
$places--;
} while ($places > 0);
$main::lxdebug->leave_sub();

Auch abrufbar als: Unified diff