You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
publicfunctioncreatePost(array$attributes): array
{
// Get author relation?
}
From what I can tell, models as a concept don't exist in the service and only attributes are available. If that's the case, what is the point of setting relations? Hope I'm missing something.
The text was updated successfully, but these errors were encountered:
If I define an Eloquent relationship on an API model am I able to get that relation in the API service?
Somewhere in app (ie, controller):
API service:
From what I can tell, models as a concept don't exist in the service and only attributes are available. If that's the case, what is the point of setting relations? Hope I'm missing something.
The text was updated successfully, but these errors were encountered: