FIX: Cartolas with empty values
This commit is contained in:
@ -28,6 +28,9 @@ class Detalle extends Ideal\Repository
|
||||
->register('centro_costo_id', (new Implement\Repository\Mapper())
|
||||
->setProperty('centroCosto')
|
||||
->setFunction(function(array $data) {
|
||||
if (empty($data['centro_costo_id'])) {
|
||||
return null;
|
||||
}
|
||||
return $this->centroCostoRepository->fetchById($data['centro_costo_id']);
|
||||
})
|
||||
->setDefault(null));
|
||||
|
||||
Reference in New Issue
Block a user