Skip to content

Commit 66e2cae

Browse files
committed
fix: calcolo scadenze
1 parent afbf06c commit 66e2cae

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

modules/pagamenti/src/Pagamento.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ public function calcola($importo, $data, $id_anagrafica)
8080
if ($rata->num_giorni % 30 == 0) {
8181
$date->addMonthsNoOverflow(round($rata->num_giorni / 30));
8282
} else {
83-
$date->addDay();
83+
$date->addDays($rata->num_giorni);
8484
}
8585

8686
$date->modify('last day of this month');
@@ -100,7 +100,7 @@ public function calcola($importo, $data, $id_anagrafica)
100100
if ($rata->num_giorni % 30 == 0) {
101101
$date->addMonthsNoOverflow(round($rata->num_giorni / 30));
102102
} else {
103-
$date->addDay();
103+
$date->addDays($rata->num_giorni);
104104
}
105105

106106
// Individuazione giorno effettivo (se il giorno indicato è eccessivamente grande, viene preso il massimo possibile)

0 commit comments

Comments
 (0)