FIX: Detalle movimiento->id
This commit is contained in:
@ -73,4 +73,16 @@ class Detalle extends Ideal\Repository
|
|||||||
{
|
{
|
||||||
return 'movimiento_id';
|
return 'movimiento_id';
|
||||||
}
|
}
|
||||||
|
protected function setIndex(Define\Model &$model, mixed $value): Ideal\Repository
|
||||||
|
{
|
||||||
|
if (!isset($model->movimiento)) {
|
||||||
|
$model->movimiento = $this->movimientoRepository->fetchById($value);
|
||||||
|
}
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
protected function getIndex(Define\Model $model): string
|
||||||
|
{
|
||||||
|
return $model->movimiento->id;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user