FIX: gastos en blanco
This commit is contained in:
@ -24,7 +24,7 @@ class Oficina extends Producto {
|
|||||||
}
|
}
|
||||||
public function map($data): Model {
|
public function map($data): Model {
|
||||||
parent::map($data);
|
parent::map($data);
|
||||||
if (strpos($this->gastos, '.') === false) {
|
if (strpos($this->gastos, '.') === false and $data->gastos != '') {
|
||||||
$this->gastos = number_format($data->gastos, 0, ',', '.');
|
$this->gastos = number_format($data->gastos, 0, ',', '.');
|
||||||
}
|
}
|
||||||
return $this;
|
return $this;
|
||||||
|
Reference in New Issue
Block a user