api-platform / api-platform/api-doc-parser

All fields are merged in case of related entity with the same iri

Open
#47 1 comment 2 reactions 0 assignees View on GitHub
Hacktoberfest
Dominant language
TypeScript
Stars
113
Forks
80
PR merge metrics
No merged PRs in 30d

Description

In case of subresources using the same "iri" of the parent, all fields are merged into the same resource.

Test case, two entities with the same iri:

```
// entities
User:
id
username
password
userProfile (OneToOne)

UserProfile:
id
photo
firstname
...
```

```yaml
// resources file
App\Entity\User:
iri: 'http://schema.org/Person'

App\Entity\UserProfile:
iri: 'http://schema.org/Person'
```

Result is all the fields **of the latest entity (with the same iri) parsed** by the `parseHydraDocumentation()`, in my case the fields are from "UserProfile" entity.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.