Fix minore registrazione contabile

This commit is contained in:
valentina 2024-09-27 09:37:59 +02:00
parent 37c6cd28c5
commit d35f534b49
1 changed files with 1 additions and 1 deletions

View File

@ -197,7 +197,7 @@ class Mastrino extends Model
}
foreach ($scadenze as $scadenza) {
$totale_da_distribuire += ($movimento['totale'] != 0 ? Movimento::where('id_scadenza', '=', $scadenza->id)
$totale_da_distribuire = ($movimento['totale'] != 0 ? Movimento::where('id_scadenza', '=', $scadenza)
->where('totale', '>', 0)
->sum('totale') : 0);
}