Asegurarse que el valor entregado a Pago es en pesos.

This commit is contained in:
Juan Pablo Vial
2025-04-29 11:29:23 -04:00
parent c3b7427f60
commit 53115b085f

View File

@ -51,7 +51,7 @@ class Credito extends Ideal\Service
$valor = $this->valorService->clean($data['valor']); $valor = $this->valorService->clean($data['valor']);
$pago = $this->pagoService->add([ $pago = $this->pagoService->add([
'fecha' => $fecha->format('Y-m-d'), 'fecha' => $fecha->format('Y-m-d'),
'valor' => $valor * $uf, 'valor' => round($valor * $uf),
'uf' => $uf, 'uf' => $uf,
'tipo' => $tipoPago->id 'tipo' => $tipoPago->id
]); ]);