Closed stevenberg closed 5 years ago
Describe the bug When a model class uses the $visible property to hide attributes, attributes that are not included in the $visible array are not shown in Prequel.
$visible
To Reproduce Use the $visible property instead of $hidden:
$hidden
protected $visible = [ 'created_at', 'email', 'id', 'name', 'updated_at', ];
Screenshots Expected view:
Actual view:
Fix I think this can be fixed by changing line 76 of DatabaseController.php from
$paginated->setCollection($paginated->getCollection()->makeVisible($hidden));
to
$paginated->getCollection()->each->setHidden([])->each->setVisible([]);
Which removes both the $hidden and $visible properties from the objects in the collection.
Thanks for including a fix! Included in next release.
Describe the bug When a model class uses the
$visible
property to hide attributes, attributes that are not included in the$visible
array are not shown in Prequel.To Reproduce Use the
$visible
property instead of$hidden
:Screenshots Expected view:
Actual view:
Fix I think this can be fixed by changing line 76 of DatabaseController.php from
to
Which removes both the
$hidden
and$visible
properties from the objects in the collection.