This commit is contained in:
Juan Pablo Vial
2023-09-28 21:05:16 -03:00
parent 2e2d0f07b4
commit 3141f1e7c4
16 changed files with 556 additions and 19 deletions

View File

@ -52,10 +52,10 @@ class Propietario extends Ideal\Repository
}))
->register('otro', (new Implement\Repository\Mapper())
->setFunction(function($data) {
if ($data['otro'] === null or $data['otro'] === 0) {
if ($data['otro'] === null) {
return null;
}
return $this->fetchById($data['otro']);
return $data['otro'] !== 0;
})
->setDefault(null));
return $this->parseData(new Model\Venta\Propietario(), $data, $map);