Fixes for invoice rounding, where invoice total was different from reporting

This commit is contained in:
2025-05-17 22:19:31 +10:00
parent 622147d584
commit ac702397a6
4 changed files with 38 additions and 21 deletions

View File

@@ -422,7 +422,7 @@ class Invoice extends Model implements IDs
*/
public function getDueAttribute(): float
{
return sprintf('%3.2f',$this->getTotalAttribute()-$this->getPaidAttribute());
return round($this->getTotalAttribute()-$this->getPaidAttribute(),2);
}
/**