Fix banca controparte

This commit is contained in:
Pek5892 2024-05-03 15:28:18 +02:00
parent 432d781ce2
commit d2bdd6cc19
1 changed files with 1 additions and 3 deletions

View File

@ -799,9 +799,7 @@ class Fattura extends Document
$pagamento = $this->pagamento;
if ($pagamento->isRiBa()) {
$banca = Banca::where('id_anagrafica', $this->idanagrafica)
->where('predefined', 1)
->first();
$banca = Banca::find($this->id_banca_controparte);
} else {
$banca = Banca::find($this->id_banca_azienda);
}