api-platform / api-platform/create-client

Missing entity in entrypoint with only custom operations defined

Offen
#273 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
enhancement
Vorherrschende Sprache
TypeScript
Sterne
376
Forks
132
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beschreibung

Today I've tried the client generator for vue:

`generate-api-platform-client --generator vue http://domain.tld/api src/`

But I've always got the error

Unable to find the URL for "http://domain.tld/api/docs.jsonld#Entrypoint/MyEntity"

The entity definition is inside a yaml file:

resources:

App\Entity\MyEntity:

collectionOperations:

indexAction: ...

createAction: ...

itemOperations:

getAction: ...

updateAction: ...

destroyAction: ...

The generator was working when I add `get: ~` to the collectionOperations.

Generally I think the client generator should also work with (only) custom operations defined.

If this behaviour is volitional maybe it could be mentioned at https://api-platform.com/docs/client-generator/troubleshooting/#troubleshooting

Environment:
* Symfony 4.3.0
* Api platform core 2.4.3
* php v7.3.6

Thanks for this great project!

Beitragsleitfaden

Beitragsleitfaden öffnen

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.