Allow to load specific relation attributes in Eloquent-type relationships #621
charlie87041
started this conversation in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Tested with https://github.com/BinarCode/restify-demo.
Consulted doc: https://restify.binarcode.com/api/relations#frontend-request
If I just want to retrieve the organization id it works like a charm
and it works because organizations is declared as a
use Binaryk\LaravelRestify\Fields\BelongsTo
.But, if I declare organization as a direct relationship in the model
then it no longer works
In short, is there a way of retrieving specific fields from any relationship that is not declared in the repository as one specialization of Binaryk\LaravelRestify\Fields\EagerField ?
Beta Was this translation helpful? Give feedback.
All reactions