Skip to content

4.4.0

Compare
Choose a tag to compare
@binaryk binaryk released this 18 Dec 11:57
· 95 commits to 4.x since this release
6907c1e

Added

  • Support for integer column type for the artisan restify:stub command.

  • Support for managing related entities via Eager fields. For example, if you want to have in relationships an BelongsTo field:

//PostRepository.php

public static function getRelated()
     {
         return [
             'owner' => BelongsTo::make('owner', 'owner', UserRepository::class),
         ];
    }

Then you can get it via related as usual:

/api/restify/posts?related=owner

And the returned object in the relationships will be formatted using UserRepository fields, so you can attach policies and permissions for specific fields in the repository itself.