diff --git a/src/Productos/Oficina.php b/src/Productos/Oficina.php index e9cc539..dedec60 100644 --- a/src/Productos/Oficina.php +++ b/src/Productos/Oficina.php @@ -2,6 +2,7 @@ namespace ProVM\KI\Productos; use ProVM\KI\Producto; +use ProVM\Common\Implementation\Model; class Oficina extends Producto { protected $properties = [ @@ -21,6 +22,13 @@ class Oficina extends Producto { } return 'privados ' . $this->privados; } + public function map($data): Model { + parent::map($data); + if (strpos($this->gastos, '.') === false) { + $this->gastos = number_format($data->gastos, 0, ',', '.'); + } + return $this; + } public function getFicha(): array { $properties = [ [