TransformsToResource
trait TransformsToResource (View source)
Methods
toResource(string|null $resourceClass = null)
Create a new resource object for the given resource.
guessResource()
Guess the resource class for the model.
static array
guessResourceName()
Guess the resource class name for the model.
Details
JsonResource
toResource(string|null $resourceClass = null)
Create a new resource object for the given resource.
protected JsonResource
guessResource()
Guess the resource class for the model.
static array
guessResourceName()
Guess the resource class name for the model.