Skip to content

v5.8.0

Choose a tag to compare

@github-actions github-actions released this 18 Oct 09:29
· 100 commits to main since this release
c291108

Added

  • $repository->with('assignee.company') names the relations find(), findOneBy(), findBy() and findAll() load,
    as with() of the query builder: it gives a copy of the repository, which is left as it is.
  • graphqlorm:query --hydrate=Task hydrates the response as the entity and prints the entities as graphqlorm:find,
    as a table or JSON (--format=json).
  • The profiler tells the relations a query loads: those named by with(), or up to max_depth.
  • The schema validation reports a property typed with a value object that no type converter converts, and checks the
    fields a converter converts use one of the scalars of its #[AsTypeConverter(..., scalars: ['Int'])].
  • graphqlorm:make:entity --from-schema types a custom scalar of the API with the value object of the type converter
    telling it (scalars: ['Siret']).
  • Value objects spread over several fields, as the embeddables of Doctrine: a class marked #[Embeddable], its fields
    mapped with #[Field], held by a property mapped with #[Embedded], a GraphQL object (price { amount currency })
    or fields of the entity with #[Embedded(prefix: 'total_')]. Created through its constructor, selected, filtered
    and ordered by the path of its fields (total.amount), kept in the second-level cache, hydrated for the DTOs, checked
    by the schema validation and the PHPStan rules, listed by the profiler.